summaryrefslogtreecommitdiffstats
path: root/tapsets.cxx
Commit message (Collapse)AuthorAgeFilesLines
...
* 2006-04-08 Frank Ch. Eigler <fche@elastic.org>fche2006-04-081-127/+109
| | | | | | | | * tapsets.cxx (resolve_prologue_endings): Rewrote. (resolve_prologue_endings2): Removed. * gen-stapmark.h: Emit a 0-arity marker. * stapmark.h: Regenerated for arities 0..6.
* 2006-03-30 Martin Hunt <hunt@redhat.com>hunt2006-03-301-1/+1
| | | | | | * tapsets.cxx (dwarf_derived_probe::emit_registrations): Change maxactive so single-processor kernels using kretprobes don't get lots of dropped probes.
* 2006-03-30 Frank Ch. Eigler <fche@elastic.org>fche2006-03-301-4/+295
| | | | | | | | | PR 953, part 1 * tapsets.cxx: (mark_derived_probe*): New classes. (register_standard_tapsets): Register kernel/module.mark() family. * stapmark.h: New header for static instrumentation markers. * gen-stapmark.h: New perl script to generate it. * elaborate.cxx (derived_probe ctor): Ignore null location*.
* 2006-03-29 Josh Stone <joshua.i.stone@intel.com>jistone2006-03-301-0/+242
| | | | | | | | | | | * 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.
* 2006-03-03 Josh Stone <joshua.i.stone@intel.com>jistone2006-03-031-4/+4
| | | | | | | | | * main.cxx (main): search forward for dashes in the kernel release, to work properly with release names with more than one dash. * parse.cxx (eval_pp_conditional): ditto * tapsets.cxx (profile_derived_probe::profile_derived_probe): ditto * safety/safety.py (StaticSafety::__build_search_suffixes): ditto, and add copyright & GPL tag
* 2006-02-23 Frank Ch. Eigler <fche@elastic.org>fche2006-02-231-1/+1
| | | | | | | | | | | | | | | 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.
* 2006-02-22 Frank Ch. Eigler <fche@elastic.org>fche2006-02-221-3/+5
| | | | | | | | | PR 2293. * tapsets.cxx (emit_probe_epilogue): Emit early local_irq_save(). (emit_probe_epilogue): ... and matching _restore(). * main.cxx (main): Emit a "hello, I'm starting" message before pass 5 in verbose mode.
* 2006-02-07 Frank Ch. Eigler <fche@elastic.org>fche2006-02-081-0/+6
| | | | | | * src/testsuite/buildok/syscalls.stp: Build with "-u" to build-test all auxiliary functions. * tapsets.cxx (dwarf_query::add_probe_point): Add some "-vv" output.
* 2006-02-07 Josh Stone <joshua.i.stone@intel.com>jistone2006-02-081-0/+1
| | | | | | PR 2068 * tapsets.cxx (dwarf_query::blacklisted_p): add __switch_to to the blacklist for x86_64 architecture only.
* 2006-01-27 Frank Ch. Eigler <fche@elastic.org>fche2006-01-281-34/+23
| | | | | | | | * 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.
* 2006-01-26 Frank Ch. Eigler <fche@elastic.org>fche2006-01-261-2/+4
| | | | | | | | | | | | | | | | | | | | | 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.
* Took sys_execve off the blacklist for return probes, now that RHEL4 U3kenistoj2006-01-241-2/+1
| | | | includes the fix for PR #1345.
* 2006-01-24 Frank Ch. Eigler <fche@elastic.org>fche2006-01-241-39/+44
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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.
* 2006-01-18 Josh Stone <joshua.i.stone@intel.com>jistone2006-01-181-0/+1
| | | | | * tapsets.cxx (profile_derived_probe::emit_probe_entries): Setup c->regs properly in light of the emit_probe_prologue change.
* 2006-01-10 Frank Ch. Eigler <fche@redhat.com>fche2006-01-101-1/+4
| | | | | | | PR 1972. * tapsets.cxx (var_expanding_copy_visitor::visit_target_symbol): Produce error message for $var access within .return probes. * testsuite/semko/thirtyfour.stp: New test.
* 2006-01-10 Frank Ch. Eigler <fche@redhat.com>fche2006-01-101-33/+33
| | | | | | | | | | | | | 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.
* 2006-01-03 Frank Ch. Eigler <fche@redhat.com>fche2006-01-031-4/+4
| | | | * tapsets.cxx (emit_deregistration): Fix bad thinko on loop nesting.
* 2006-01-03 Frank Ch. Eigler <fche@redhat.com>fche2006-01-031-112/+88
| | | | | | | | | | | | | | | | | | | | | | | | | | | 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.
* Anil S Keshavamurthy - Blacklist'ing notifier_call_chain() function, as thisaskeshav2005-12-161-0/+1
| | | | | function is on kprobes critical path, having probes on this will damage the system.
* 2005-12-13 Frank Ch. Eigler <fche@redhat.com>fche2005-12-131-0/+1
| | | | | * tapsets.cxx (var_expanding_copy_visitor::visit_target): Transcribe token pointer to synthesized functiondecl.
* 2005-12-12 Josh Stone <joshua.i.stone@intel.com>jistone2005-12-121-37/+48
| | | | | | * tapsets.cxx (profile_derived_probe::*,profile_builder::build): Do kernel version checks at translation time, using the same internal mechanisms as the preprocessor - a la %( kernel_v < "2.6.10" %? ... %: ... %)
* 2005-12-09 Graydon Hoare <graydon@redhat.com>graydon2005-12-101-20/+212
| | | | | | | | | | | | | | | | * elaborate.cxx (alias_expansion_builder::build): Fix comment typo. * tapsets.cxx (symbol_cache): New class. (dwflpp::cache): Add cache. (dwflpp::pattern_limited_cus): New member. (dwflpp::pattern_limited_funcs): New member. (dwflpp::limit_search_to_function_pattern): New method. (dwflpp::iterate_over_cus): Modify to use cached, limited sets. (dwflpp::iterate_over_functions): Likewise. (dwarf_builder::user_dw): New member. (dwarf_builder::kern_dw): New member. (dwarf_builder::~dwarf_builder): Add dtor. (query_module): Call dwflpp::limit_search_to_function_pattern. (dwarf_builder::build): Initialize persistent dwflpp members on demand.
* 2005-12-06 Frank Ch. Eigler <fche@elastic.org>fche2005-12-071-23/+58
| | | | | | | PR 1934. * tapsets.cxx (resolve_prologue_endings2): Add new heuristic for tail-call optimized functions. (query_func_info): Make somewhat less verbose.
* 2005-12-05 Frank Ch. Eigler <fche@elastic.org>fche2005-12-051-0/+1
| | | | * *.cxx: Add <cassert> #include as needed.
* 2005-11-30 Frank Ch. Eigler <fche@redhat.com>fche2005-11-301-6/+126
| | | | | | | | | PR 1276 From Josh Stone <joshua.i.stone@intel.com>: * tapsets.cxx (profile_derived_probe, profile_builder, register_standard_tapsets): Support timer.profile variety. * stapprobes.5.in: Document it. * testsuite/builok/fourteen.stp: Test its buildability.
* 2005-11-25 Frank Ch. Eigler <fche@elastic.org>fche2005-11-251-3/+0
| | | | | | | PR 1336. * tapsets.cxx (translate_final_fetch_or_store): Remove apparently unnecessary check. * testsuite/transok/ten.stp: New test for void* integerification.
* 2005-11-24 Frank Ch. Eigler <fche@redhat.com>fche2005-11-241-4/+4
| | | | | | | PR 1917 * translate.cxx (emit_common_header, emit_module_init, emit_module_exit): Switch context array to per-cpu kmalloc variant. * tapsets (*::emit_probe_entires): Use per_cpu_ptr() for my context.
* 2005-11-21 Roland McGrath <roland@redhat.com>roland2005-11-221-8/+34
| | | | | | | | | | * loc2c.c (c_translate_location): Take Dwarf_Op vector as argument directly, not Dwarf_Attribute.p * loc2c.h: Update decl. * loc2c-test.c (get_location): New function. (handle_variable): Use it. * tapsets.cxx (dwflpp::translate_location): New method. (dwflpp::translate_components, dwflpp::literal_stmt_for_local): Use it.
* 2005-11-21 Frank Ch. Eigler <fche@elastic.org>fche2005-11-211-9/+26
| | | | | | | | | PR 1276 From Josh Stone <joshua.i.stone@intel.com>: * tapsets.cxx (timer_derived_probe, timer_builder, register_standard_tapsets): Support timer.ms() variety. * stapprobes.5.in: Document it. * testsuite/builok/fourteen.stp: Test its buildability.
* 2005-11-18 Martin Hunt <hunt@redhat.com>hunt2005-11-181-5/+5
| | | | | | | | | | | | | | | | | | | | | | | PR 1837 * testsuite/buildko/one.stp: Replace printk. * testsuite/buildok/one.stp: Ditto. * testsuite/buildok/two.stp: Ditto. * testsuite/semko/fifteen.stp: Ditto. * testsuite/semko/fourteen.stp: Ditto. * testsuite/semko/thirteen.stp: Ditto. * testsuite/transok/eight.stp: Ditto. * testsuite/transok/seven.stp: Ditto. * testsuite/transok/six.stp: Ditto. * tapsets.cxx (*::emit_probe_entries): Replace printk() calls with _stp_warn(). * stap.1.in: Replace printk with printf in example. * stapfuncs.5.in: Remove docs for printk and add for print and printf. * tapset/logging.stp (printk): Deleted.
* 2005-11-08 Frank Ch. Eigler <fche@redhat.com>fche2005-11-081-1/+2
| | | | | | * tapsets.cxx (blacklisted_p): Tolerate NULL filename parameter. * src/testsuite/semok/twenty.stp: New test to enumerate everything dwarfly probeable.
* 2005-11-08 Frank Ch. Eigler <fche@redhat.com>fche2005-11-081-1/+4
| | | | | | | * tapsets.cxx (blacklisted_p): Add blacklist for some .return probes to kludge around bug #1345. * tapset/system_calls.stp: Add some %( %? %) conditionals to get closer to using tapset on 2.6.9 kernel.
* 2005-11-07 Frank Ch. Eigler <fche@redhat.com>fche2005-11-071-10/+47
| | | | | | | PR 1828. * tapsets.cxx (blacklisted_p): New function. Add a few blacklist entries. * testsuite/semko/thirtythree.stp: New test.
* 2005-11-04 Frank Ch. Eigler <fche@redhat.com>fche2005-11-041-3/+14
| | | | | | | | | * tapsets.cxx (dwarf_derived_probe::emit_registrations): Add possible kprobe address prechecking logic. Set kretprobes maxactive to zero. * translate.cxx (emit_module_init): Set a more helpful default probe_point value for use in registration errors. Exit properly after registration failure of probe #0.
* 2005-11-04 Roland McGrath <roland@redhat.com>roland2005-11-041-32/+50
| | | | | * tapsets.cxx (add_probe_point): Use dwfl_module_relocation_info to get symbol name when dwfl_module_relocations has the info.
* 2005-11-03 Roland McGrath <roland@redhat.com>roland2005-11-031-2/+2
| | | | | * tapsets.cxx (add_probe_point): Use explicit test with assignment in while condition.
* 2005-11-03 Frank Ch. Eigler <fche@elastic.org>fche2005-11-031-0/+39
| | | | | | | PR 1329. * tapsets.cxx (dwarf_query::add_probe_point): Look up section name containing given address. Skip request if it came from .init.*. * testsuite/semko/thirtytwo.stp: New test.
* 2005-10-31 Roland McGrath <roland@redhat.com>roland2005-10-311-138/+138
| | | | | | | | | | | | | | * configure.ac: Update libdw test to require 0.116 with dwarf_diecu. * configure: Regenerated. * systemtap.spec.in: Update elfutils requirement to 0.116. * loc2c.c: Dwarf_Loc -> Dwarf_Op. (location_from_address): dwarf_addrloclists -> dwarf_getlocation_addr. (c_translate_location): Likewise. (max_fetch_size): Remove fakeo dwarf_diecu macro. * tapsets.cxx (dwflpp): Dwarf_Func -> Dwarf_Die; dwarf_func_name -> dwarf_diename; dwarf_func_entrypc -> dwarf_entrypc; dwarf_func_file, dwarf_func_line -> dwarf_decl_file, dwarf_decl_line.
* IA64 Runtime support patches. With this in placeaskeshav2005-10-281-0/+12
| | | | | | | Systemtap should now be able to build on Ia64. Includes supports for - function probes, return probes, function parameter access and dumping stack backtrace. Added by Anil S Keshavamurthy <Anil.s.keshavamurthy@intel.com>
* 2005-10-18 Frank Ch. Eigler <fche@elastic.org>fche2005-10-181-2/+5
| | | | | | | | PR 1482 cont'd. * translator.cxx (emit_module_init): Set aside a variable for detailed probe point id. * tapsets.cxx (emit_registrations): Use it. (add_probe_point): Correct synthesized probe-point typo.
* 2005-10-17 Martin Hunt <hunt@redhat.com>hunt2005-10-181-1/+1
| | | | | | PR 1482 * tapsets.cxx (emit_registrations): On failure, don't forget to unregister probe 0;
* 2005-10-17 Frank Ch. Eigler <fche@elastic.org>fche2005-10-181-6/+5
| | | | | | | | | | | | | | | | | | | | PR 1338. * parse.cx (parse_probe): Unconditionally visit parse_probe_point. (parse_probe_point): Accept "*" as component name. * stapprobes.5.in: Document this. * elaborate.cxx (derive_probes): Rewrite. Make top-level function. (match_node::find_and_build): New function to replace (find_builder): Removed. (match_key operator <): Correct one nasty typo. (match_node::bind): Refuse to bind "*" component names. (derived_probe_builder::build): Remove recursion output param. (alias_expandion_builder::build): Recurse to derive_probes instead. * elaborate.h: Corresponding changes. * tapsets.cxx: Ditto. (query_cu): Elide prologue finding for uninteresting CUs. * testsuite/semok/nineteen.stp: New test. * testsuite/semko/twentythree.stp: New test. * testsuite/semko/twentyone/two.stp: Fix -p2.
* 2005-10-17 Graydon Hoare <graydon@redhat.com>graydon2005-10-171-27/+79
| | | | | | | | | | | | | | | | | | | | | | | | | | | * testsuite/semko/twentyone.stp: Check function doesn't match inline. * testsuite/semko/twentytwo.stp: Check inline doesn't match function. * testsuite/buildok/six.stp: Change "function" to "inline". * stapprobes.5.in: Describe "inline" probes. * tapsets.cxx (TOK_INLINE): New token "inline". (dwarf_query::has_inline_str) (dwarf_query::has_inline_num) (dwarf_query::inline_str_val) (dwarf_query::inline_num_val): New members. (dwarf_query::dwarf_query): Load new members. (query_dwarf_inline_instance) (query_dwarf_func) (query_cu) (query_module) (dwarf_derived_probe::add_probe_point) (dwarf_builder::build): Use inline-related members where appropriate. (dwarf_derived_probe::register_inline_variants): New method. (dwarf_derived_probe::register_function_and_statement_variants): Call it.
* 2005-10-10 Frank Ch. Eigler <fche@elastic.org>fche2005-10-101-0/+2
| | | | | | * elaborate.cxx (match_node::bind): Improve error message. (register_library_aliases): Catch and verbosify error message. (semantic_pass): Provide a back-up exception catcher.
* 2005-10-04 Graydon Hoare <graydon@redhat.com>graydon2005-10-051-0/+7
| | | | | | | | | PR 1131. * tapsets.cxx (target_variable_flavour_calculating_visitor::visit_target_symbol) (var_expanding_copy_visitor::visit_target_symbol): Require guru mode for writing to target vars. * testsuite/buildok/twenty.stp: Test writing to target vars.
* 2005-10-01 Frank Ch. Eigler <fche@elastic.org>fche2005-10-011-18/+56
| | | | | | | | | * tapsets.cxx (get_module_dwarf): Add "required" parameter, which throws an exception if debuginfo is not found. (focus_on_module_containing_global_address): Tolerate miss. (query_kernel_exists): New function to test for "kernel" module in dwfl_getmodules() result set. (dwarf_builder::build): Call it if appropriate.
* [ChangeLog]graydon2005-10-011-120/+260
| | | | | | | | | | | | | | | | | | | | | | | 2005-09-30 Graydon Hoare <graydon@redhat.com> PR 1131. * tapsets.cxx (dwflpp::find_variable_and_frame_base) (dwflpp::translate_components) (dwflpp::resolve_unqualified_inner_typedie) (dwflpp::translate_final_fetch_or_store): New functions. (dwflpp::literal_stmt_for_local): Factor a bit. (variable_flavour_calculating_visitor::visit_target_symbol): Don't fault on lvalue, just collect an extra char. (var_expanding_copy_visitor::target_symbol_setter_functioncalls): New member. (var_expanding_copy_visitor::visit_assignment): New method. (var_expanding_copy_visitor::visit_target_symbol): Permit lvalues. [runtime/ChangeLog] 2005-09-30 Graydon Hoare <graydon@redhat.com> * loc2c-runtime.h (_put_user_asm): Fix bracket-matching.
* 2005-09-27 Frank Ch. Eigler <fche@elastic.org>fche2005-09-281-3/+4
| | | | | * tapsets.cxx (query_cu_containing_global_address): Tolerate way out of range addresses that result in null cudie pointers.
* 2005-09-27 Frank Ch. Eigler <fche@elastic.org>fche2005-09-271-2/+28
| | | | | | | | PR 1368. * translate.cxx (emit_common_header): Move some MAX* definitions out ... (translate_pass): ... to here. Fix probe_start API impedance mismatch. (emit_module_init, exit): Tolerate registration errors, such as absence of kretprobes support.
* 2005-09-27 Frank Ch. Eigler <fche@elastic.org>fche2005-09-271-8/+10
| | | | | | | | PR 1311. * tapsets.cxx (target_variable_flavour_calculating_visitor:: visit_target_symbol): Print verbose error. (var_expanding_copy_visitor::visit_target_symbol): Throw simple error.