| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
|
| |
* tapsets.cxx, translator.cxx (*): Designate more emitted
functions as static.
* translator.cxx (visit_print_format): Correct regression
regression from two weeks ago.
* stapfuncs.5.in: Tweak wording. Deprecate returnval() in favour
of retval().
|
|
|
|
| |
in script associated with timing information.
|
|
|
|
|
| |
* translate.cxx (mapvar::exists): Added code for string array
handling. Otherwise, string array elements always exist.
|
| |
|
|
|
|
| |
the average amount of time spent in the probe.
|
|
|
|
|
| |
* translate.cxx (visit_print_format): Fix regression in
"printf" pseudo-result initialization.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
PR 2610.
* translate.cxx (c_unparser::visit_arrayindex, visit_stat_op):
Detect empty aggregates consistently.
(visit_print_format): Ditto. Also detect errors due to
argument evaluation.
(translator_output::*): Add a flush before a failing assert,
to produce more context when debugging.
2006-05-01 Frank Ch. Eigler <fche@elastic.org>
* systemtap.maps/absentstats.*: Rewrite.
* systemtap.maps/ix_clear*.exp: Update error message.
|
|
|
|
|
|
| |
PR 2149
* translate.cxx (mapvar::set): Test _stp_map_set_xx() for
array overflows.
|
|
|
|
|
|
| |
PR 1326
* translate.cxx (c_unparser::visit_binary_expression): Handle
negative left and right shift count.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
PR 953
* elaborate.h (derived_probe): Add field "name". Stop passing
"probe index" to other emit_* calls.
(emit_probe_context_vars): New member function.
* elaborate.cxx (derived_probe ctor): Generate unique name.
* translate.cxx (*): Adapt to index->name.
(emit_probe): Realize that probe locals only occur at nesting=0.
* tapsets.cxx (*derived_probe::emit_*): Adapt to index->name.
(mark_var_expanding_copy_visitor): New class to process $argN.
(mark_derived_probe ctor): Call it.
(mark_derived_probe::emit_probe_context_vars): Do it.
* buildrun.cxx (compile_pass): Add more optional gcc verbosity.
Add CFLAGS += -freorder-blocks.
* testsuite/buildok/marker.stp: New test.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
PR 2220
* translate.cxx (visit_statement): Tolerate 0 first argument.
(visit_for_loop, visit_foreach_loop): Call it thusly for condition
expression.
(visit_embededcode, visit_block, visit_null_statement): Don't
call visit_statement() at all.
2006-04-18 Frank Ch. Eigler <fche@elastic.org>
* conversions.stp (string, hex_string): Use snprintf for safety.
2006-04-18 Frank Ch. Eigler <fche@elastic.org>
* systemtap.samples/control_limits.stp: Adapt to new action counting.
|
|
|
|
|
|
|
| |
PR 2497
* translate.cxx (translate_pass): Don't
reset STP_STRING_SIZE if it was already defined.
Set it to 1024 by default.
|
|
|
|
|
| |
* translate.cxx (visit_print_format): Call
_stp_snprintf() instead of snprintf().
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add binary printf support.
* elaborate.cxx (visit_print_format): Don't include
conv_literal or conv_size in components vector.
Add conv_binary to switch statement.
* translate.cxx (visit_print_format): Eliminate
special cast to (long long) for pe_long because new
vsnprintf uses int64_t.
* staptree.h (struct print_format): Add conv_binary and conv_size.
* staptree.cxx (components_to_string): Add conv_binary case.
Add conv_size case.
(string_to_components): Add cases for 'b' and 'n'
|
|
|
|
|
|
|
|
|
|
|
| |
* tapsets.cxx (hrtimer_derived_probe::*): creates a probe point
based on the hrtimer APIs.
* tapsets.cxx (hrtimer_builder::*): parses the user's time-spec
into a 64-bit nanosecond value, and calls the appropriate
derived_probe.
* tapsets.cxx (register_standard_tapsets): add hrtimer bindings
* translate.cxx (translate_pass): add linux/random.h include,
used for generating 64-bit random numbers for hrtimers.
|
|
|
|
|
| |
* translate.cxx (emit_globals): Tag globals, especially the locks,
as __cacheline_aligned.
|
|
|
|
|
| |
* translate.cxx (emit_locks): Emit dummy references to unlock_ ...
(emit_module_init): ... and probe_point.
|
|
|
|
|
|
|
| |
* translate.cxx (var::init): Don't crush string module_params.
(emit_global_param): New function, forked out of emit_global,
to put module_param calls at the bottom of C file.
* translate.h: Corresponding changes.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
PR 1304
* parse.cxx (lexer): Take systemtap_session argument.
(lexer::scan): Support $1..$NNNN and @1...@NNNN expansion.
* stap.1.in: Document this.
* testsuite/semok/args.stp: New test.
* translate.cxx (var::init, emit_global): Emit code to allow
named module parameters to initialize global string/number scalars.
* stap.1.in: Don't document this yet.
PR 2334
* main.cxx (main): Clarify "-v" option repeatibility.
* stap.1.in: Ditto.
|
|
|
|
|
| |
* translate.cxx (varlock*): Removed now unnecessary class.
(aggregation_locks): Renamed field to aggregations_active.
|
|
|
|
|
|
| |
PR 2252
* translate.cxx (translate_pass): Fix legacy definition of
read_trylock.
|
|
|
|
|
|
|
|
| |
* main.cxx: Make "-v" (verbose) flag a counter.
* stap.1.in: Document this.
* session.h: Corresponding changes.
* {elaborate,buildrun,tapsets,translate}.cxx: Update all uses of
verbose flag to compare it to sensible level for value of message.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
PR 2060: lock elevation, mop-up
* staptree.cxx (functioncall_traversing_visitor): Store a
current_function pointer during traversal.
(visit_embeddedcode): Use it to handle $target-synthesized functions.
(varuse_collecting_visitor::visit_assignment): Correct l-lr typo.
(visit_foreach_loop): Note added write on sorted foreach.
(visit_delete_statement): Note as read+write.
* staptree.h: Corresponding changes.
* elaborate.cxx (dead_assignment_remover::visit_expr_statement):
Correct stmt token after possible expression rewriting.
* tapsets.cxx (visit_target_symbol): Create naming convention
to recognize $target-synthesized functions.
* translate.cxx (emit_locks, emit_unlocks): New functions to
emit lock/unlock sequences at the outermost level of a probe.
(emit_probe): Call them.
(varlock_*): #if-0 out the lock code generation. Later, these
classes should be removed.
(translate_pass): Emit read_trylock() kludge macro for old kernels.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
PR 2060 etc.
* tapsets.cxx (visit_target_symbol): Tolerate failed resolution by
letting target_symbol instance pass through to optimizer and
type checker.
* elaborate.cxx (semantic_pass_optimize): New family of functions and
associated visitor classes.
(visit_for_loop): Tolerate absent init/incr clauses.
(semantic_pass): Invoke unless unoptimized (-u) option given.
* main.cxx, session.h: Add support for flag.
* staptree.cxx (visit_for_loop): Tolerate absent init/incr clauses.
(traversing_visitor::visit_arrayindex): Visit the index expressions.
(functioncall_traversing_visitor): New class.
(varuse_tracking_visitor): New class.
* staptree.h: Corresponding changes.
* parse.cxx (parse_for_loop): Represent absent init/incr expressions
with null statement pointer instead of optimized-out dummy numbers.
* stap.1.in: Document optimization.
* testsuite/{semko,transko}/*.stp: Added "-u" or other code to many
tests to check bad code without optimizer elision.
* testsuite/semok/optimize.stp: New test.
* elaborate.cxx (unresolved, invalid, mismatch): Standardize error
message wording.
* stapfuncs.5.in: Tweak print/printf docs.
* tapset/logging.stp: Remove redundant "print" auxiliary function,
since it's a translator built-in.
* testsuite/transok/five.stp: Extend test.
* translate.cxx (emit_symbol_data): Put symbol table into a separate
temporary header file, to make "-p3" output easier on the eyes.
* buildrun.cxx (compile_pass): Eliminate test-mode support throughout.
* main.cxx, session.h, translate.cxx: Ditto.
* main.cxx (main): For last-pass=2 runs, print post-optimization ASTs.
|
|
|
|
|
| |
* translate.cxx (c_unparser::visit_foreach_loop): improved the error
message when _stp_pmap_agg fails.
|
|
|
|
|
| |
* translate.cxx (c_unparser_assignment::visit_arrayindex):
Eliminate dummy assignments for "<<<" code.
|
|
|
|
|
|
| |
PR 2156
* translate.cxx (c_unparser::visit_foreach_loop): Check the return
value of _stp_pmap_agg() for NULL.
|
|
|
|
|
|
|
|
|
|
|
| |
PR 2142
* translate.cxx (EXTRACTORS_PERMISSIVE): New experimental policy
parameter.
(c_unparser::visit_arrayindex, visit_print_format, visit_stat_op):
Tolerate absent index (= NULL runtime return) in pmap.
(*): Make semantic_error messages consistently lower case.
* testsuite/buildok/iterate_histogram_buckets.stp: Note some missing
functionality.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
PR 2140
* translate.cxx (mapvar::del): Add ability to delete an indexed stat
from (p)maps.
(delete_statement_operand_visitor::visit_symbol): Add ability to
delete entire pmaps and scalars.
(delete_statement_operand_tmp_visitor): Add a special tmpvar visitor
to parallel delete_statement_operand_visitor.
(c_tmpcounter::visit_delete_statement): Invoke the new visitor.
* testsuite/buildok/delete.stp: Also test scalar deletes.
* vim/syntax/stap.vim: Recognize 'delete' operator.
2006-01-16 Josh Stone <joshua.i.stone@intel.com>
* stat.c (_stp_stat_clear): add a function that just
clears a Stat, so we can use delete in the translator.
|
|
|
|
|
|
|
|
| |
PR 2148
* translate.cxx (MAXERRORS): Actually the max should be 0, so first
error aborts session.
* Revert last stp_exit change.
|
|
|
|
| |
* translate.cxx (c_unparser:getmap): Correct exception throwing typo.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
PR 2056
* translate.cxx (c_unparser::aggregation_locks): Keeps track of
foreach's locks on pmaps to avoid extra aggregation.
(c_unparser::visit_foreach_loop): Set aggregation_locks appropriately.
(c_unparser::load_aggregate, mapvar::call_prefix, mapvar::get):
Use a new parameter to indicate that we should read from the
already-aggregated map rather than the full pmap..
(c_unparser::visit_arrayindex c_unparser::visit_print_format,
c_unparser::visit_stat_op): Use aggregation_locks to avoid taking a
lock and aggregating the pmap.
(c_unparser::emit_map_type_instantiations): To read from a pmap's
aggregated map, we need to include map-gen.c for the _stp_map_*
functions.
(c_unparser::obtained_locks, varlock::varlock, varlock::~varlock):
Add simple static checking to detect incompatible nested locks during
translation, and flag it as an error.
|
|
|
|
| |
* translate.cxx (MAXERRORS): Oops, set back to intended default of 1.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
PR 2060.
* buildrun.cxx (compile_pass): Add "V=1" to kbuild if verbose.
* translate.cxx (translator_output): For output-file constructor,
set an explicit output buffer.
(emit_module_init, emit_module_exit): Reorganize output, to spit
each individual probe registration/deregistration blurb into a
separate function.
* translate.h: Corresponding changes; set default buffer size to 8K.
* translate.cxx, tapsets.cxx: Replace "endl" by buffer-friendly "\n"
throughout code generation routines.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
PR 2056
* translate.cxx (var::~var, var::hist, var::buckets): make these
methods virtual, so we can use polymorphism.
(mapvar::hist, mapvar::buckets): Override the corresponding var
methods to handle pmaps correctly.
(c_unparser::visit_arrayindex, c_unparser::visit_print_format): Make
use of the new polymorphic behavior of var & mapvar when dealing with
histogram data.
* testsuite/buildok/pmap_foreach.stp: Add tests to check histogram
accesses with for/foreach.
|
|
|
|
|
|
| |
PR 2057.
* translate.cxx (c_unparser_assignment::visit_arrayindex): Don't take
write lock around pmap accumulation.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
PR 1144, 1379
* tapsets.cxx (emit_probe_prologue, _epilogue): New routines.
Call from existing derived_probe spots. Implement soft errors in
epilogue code. Implement reentrancy detection in prologue code.
(dwarf_derived_probe::emit_deregistration): Add kprobes layer
"nmissed" to skipped_count.
* translate.cxx (varlock): Use nsleep(TRYLOCKDELAY) in lock
contention loop.
(emit_module_exit): Report number of soft errors and skipped probes.
(emit_function, _probe): Add __restrict__ marker to context pointer.
(translate_pass): Define new MAXTRYLOCK, TRYLOCKDELAY, MAXERRORS,
MAXSKIPPED parameters.
* tapset/logging.stp (error): Don't stp_error, just set context state.
* stap.1.in, stapfuncs.5.in: Document soft errors.
* elaborate.h: Corresponding changes.
2006-01-03 Frank Ch. Eigler <fche@redhat.com>
* io.c (_stp_softerror): New function.
2006-01-03 Frank Ch. Eigler <fche@redhat.com>
* systemtap.base/timers.exp: Extend the test run duration.
Accept skipped probe warnings at shutdown.
|
|
|
|
| |
* translate.cxx (itervar::next): emit different code for pmaps
|
|
|
|
| |
* translate.cxx (translate_pass): Emit #include <linux/profile.h>.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fix parse tree pretty-printer.
* staptree.h (print_format): Add raw_components field.
* parse.cxx (parse_symbol): Set it.
* staptree.cxx (lex_cast_qstring): Copy it here too.
(binary_expression::print): Add a space around operator, due to
lexical ambiguity (expr % paren-expr) vs %( preprocessor op.
(array_in:: foreach_loop:: arrayindex::print): Print base as indexable.
(print_format::string_to_components): Use parse_error, not semantic.
(print_format::print): Properly quote formatting string. Print
histogram argument.
* translate.cxx (visit_print_format): Properly quote formatting string.
(varlock): Reword lock timeout error message.
* testsuite/buildok/printf.stp: Add some quoting troublemakers.
* testsuite/parseok/unparser.stp: New file.
|
|
|
|
|
|
|
|
|
| |
* translate.cxx (delete_statement_operand_visitor::visit_arrayindex):
Prohibit deleting histogram buckets.
(c_tmpcounter::visit_array_in): Direct to visit_arrayindex.
(c_unparser::visit_array_in): Likewise.
* testsuite/buildok/histogram_operator_in.stp: New test.
|
|
|
|
|
|
|
|
|
|
|
|
| |
* staptree.cxx (traversing_visitor::visit_foreach_loop): Visit
the base indexable of the foreach loop.
* translate.cxx (c_tmpcounter::visit_foreach_loop): Implement
histogram bucket iteration arm.
(c_unparser::visit_foreach_loop): Likewise.
(c_tmpcounter::visit_arrayindex): Fix typo.
* testsuite/buildok/iterate_histogram_buckets.stp: New test.
|
|
|
|
|
| |
* translate.cxx (mapvar::fini): Use _stp_pmap_del() on pmaps.
(emit_global): For pmaps, use "PMAP" instead of "MAP".
|
|
|
|
|
| |
* translate.cxx (visit_print_format): Explicitly Cast int64_t
(pe_long) args to (long long) in generated code, for portability.
|
|
|
|
| |
* *.cxx: Add <cassert> #include as needed.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* elaborate.cxx (mutated_var_collector): Forward
traversal portion of calls to base class.
(mutated_var_collector::visit_arrayindex): Resolve
arrayindex-into-histogram expression as pe_long.
(typeresolution_info::visit_print_format): Traverse
into histogram if present.
* parse.cxx (parse_symbol): Handle parse ambiguity surrounding
print(@hist_op(...)[...]).
* staptree.cxx (traversing_visitor::visit_arrayindex): Visit
base member of arrayindex.
* translate.cxx (c_unparser::histogram_index_check): New method.
(var::hist): Fix bug.
(var::buckets): New method.
(stmt_expr::stmt_expr): Print with newline.
(c_unparser::load_map_indices): Handle indexing-histogram case.
(c_tmpcounter::visit_arrayindex): Likewise.
(c_unparser::visit_arrayindex): Likewise.
(c_tmpcounter_assignment::visit_arrayindex): Throw error when
user attempts to write to histogram bucket.
(c_unparser_assignment::visit_arrayindex): Likewise.
* testsuite/buildok/print_histogram_entry.stp: New test.
|
|
|
|
|
|
| |
PR 1944 improved hack.
* translator.cxx (c_tmpcounter::visit_block): New routine, allows
overlay of sequential statements' temporaries within context.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
PR 1944 quick hack.
* translator.cxx (translate_pass): Reduce default MAXNESTING to 10.
(emit_module_init): Add a paranoid check against oversize contexts.
* stap.1.in: Document MAXNESTING change.
2005-12-01 Frank Ch. Eigler <fche@redhat.com>
PR 1944 quick hack.
* testsuite/systemtap.sample/control_limits.*: Adapt to new
MAXNESTING default.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
2005-11-28 Graydon Hoare <graydon@redhat.com>
* translate.cxx (var::assert_hist_compatible): New method.
(var::hist): New method.
(c_unparser::load_aggregate): New method.
(hist_op_downcaster): Remove, it was a mistake.
(expression_is_hist_op): Likewise.
(c_tmpcounter::visit_print_format): Implement print(@hist(...)).
(c_unparser::visit_print_format): Likewise.
* staptree.h (struct print_format): Add optional hist_op* member.
* staptree.cxx (traversing_visitor::visit_functioncall): Visit
hist_op if present in print_format.
(deep_copy_visitor::visit_print_format): Likewise.
* parse.cxx (parse_symbol): Special case to consume print(@hist(...)).
* elaborate.cxx (typeresolution_info::visit_arrayindex): Fix type inference bug.
(typeresolution_info::visit_foreach_loop): Likewise.
* testsuite/buildok/print_histograms.stp: New test.
[runtime/ChangeLog]
2005-11-28 Graydon Hoare <graydon@redhat.com>
* stat-common.c (_stp_stat_print_histogram): Various formatting
corrections and aesthetic tweaks.
(__stp_stat_add): Correction to linear bucket underflow cases.
|
|
|
|
|
| |
* translate.cxx (c_tmpcounter_assignment::visit_symbol): Don't
emit unused temporary into context. Saves mucho space with strings.
|