| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
| |
The location already has a pointer to a stapfile with the filename, so
there's no need to keep an extra copy.
|
|
|
|
|
|
|
|
|
|
| |
When an instance of an alias has a condition, that condition gets
propagated to each of the locations that the alias defines. However,
the copy of the location list was not a deep copy, and so all other
instances of the alias would also incorrectly receive the condition.
This patch makes the location list copy a little deeper, and adds a
test case which demonstrates the issue.
|
|
|
|
|
|
| |
We have the saved_conversion_error field, but I wasn't using it. Now
@cast errors are saved in that field, so they're only seen if the
optimizer doesn't remove the @cast.
|
|
|
|
|
|
|
|
|
| |
This patch will make stap silently accept the
failure related to optional probe. It puts try/catch
around find_and_build which can cover most probe types.
The specific treatment for dwarf_derived_probe in
commit ed82b7c902d6a2e26452ec51c9cdb9665dbf9e97 is
reverted.
|
|
|
|
|
|
| |
* elaborate.cxx: Early return for mismatched optional probe.
* testsuite/systemtap.base/optionalprobe.exp: New test case.
* testsuite/systemtap.base/optionalprobe.stp: Ditto.
|
| |
|
|
|
|
| |
* elaborate.cxx (semantic_pass_opt4): Filter warning on s.timing.
|
|
|
|
|
|
|
|
|
|
| |
We already stash the context variables for markers and tracepoints into
the locals for the probe body, but then we were using separate functions
to read those locals for each particular probe body.
This patch instead teaches the unparser how to emit the local name
directly for those context variables. The resulting code from the
translator is much simpler now.
|
|
|
|
| |
avoid SEGV
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
This will be used to hook to dwarf_builder to all functions and probes
so it can attempt @cast expansion.
* session.h (systemtap_session): Add a vector of update_visitors
that will act as filters for all probes and functions.
* elaborate.cxx (semantic_pass_symbols): Run probes and functions
through each registered code filter.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This handles all of the parsing, traversal, and optimization. It
doesn't actually resolve the cast yet though.
* staptree.h (struct cast_op, visitor::visit_cast_op): New.
* staptree.cxx (cast_op::print/visit, various visitor::visit_cast_op's):
Incorporate cast_op into the basic tree operations.
* parse.cxx (parser::parse_symbol): Parse @cast operator with an
expression operand, type string, and optional module string.
* translate.cxx (c_unparser::visit_cast_op): Error out if a @cast
survives to translation.
* elaborate.cxx (typeresolution_info::visit_cast_op): Error out if a
@cast survives to type resolution.
(symbol_fetcher::visit_cast_op): treat @casts as a symbol target
(void_statement_reducer::visit_cast_op): unused @casts can be discarded,
but the operand should still be evaluated.
|
|
|
|
| |
* elaborate.cxx (void_statement_reducer): Convert to an update_visitor.
|
|
|
|
|
|
| |
* staptree.h (update_visitor::require): Add a clearok parameter for
optimizing traversers to signal that they're ready for NULL back.
* elaborate.cxx (dead_stmtexpr_remover): Convert to an update_visitor.
|
|
|
|
|
|
|
|
| |
By converting to an update_visitor, we now get full statement coverage
in this optimizer for free.
* elaborate.cxx (dead_assignment_remover): Convert into an
update_visitor and remove its now-redundant traversal methods.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
(plus emacs' automagic whitespace fixes)
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
group.
elaborate.cxx (systemtap_session::systemtap_session): Added
initialization of itrace_derived_probes.
tapsets.cxx (struct itrace_derived_probe): Add derived_probe
struct for holding info needed by itrace probes.
(struct itrace_derived_probe_group): New derived_probe_group
to handle itrace probes.
(itrace_derived_probe::itrace_derived_probe): Needed for use with
task_finder.
(itrace_derived_probe_group::join_group): Ditto.
(itrace_derived_probe_group::enroll): Ditto.
(itrace_derived_probe_group::emit_probe_decl): Ditto.
(itrace_derived_probe_group::emit_module_decls): Ditto.
(itrace_derived_probe_group::emit_module_init): Ditto.
(itrace_derived_probe_group::emit_module_exit): Ditto.
stapprobes.5.in : Added documentation of itrace probe.
|
| |
|
|
|
|
|
|
|
|
| |
Instead, visit_expr_statement can explicitly load a pointer to use for
back-references.
I also decided to be less-clever about reusing expr_statements. It's a
little leakier as a result, but I like having less magic in the air.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
PR 6644
* elaborate.cxx (dead_stmtexpr_remover::visit_block): Flatten nested
block statements into a single block.
(dead_stmtexpr_remover::visit_if_statement): Remove the possibility
of if_statements with a null thenblock. When an if lacks both then
and else, either remove it completely or reduce it to a simple
statment evaluating the condition. With an else and no then, invert
the condition and else becomes then.
(void_statement_reducer): New optimization visitor that breaks
statements in void context into smaller pieces, to expose more
optimization opportunities.
(semantic_pass_opt5, semantic_pass_opt6): Bump opt5 to opt6, and
create a new opt5 that runs through void_statement_reducer.
|
|\
| |
| |
| |
| |
| | |
* 'master' of ssh://sources.redhat.com/git/systemtap:
Improved callback handling.
Create alternative list only as needed.
|
| | |
|
|/ |
|
| |
|
| |
|