* Makefile.am (dist): Package up the source tree, including
testsuite and runtime.
* main.cxx: Use clog instead of cerr for logging messages.
* buildrun.cxx: Ditto.
(compile_pass): Add -Iruntime/user for test mode.
* translate.cxx (*): Commonalize test/real mode output.
* Makefile.in: Regenerated.
* elaborate.{h,cxx}: Revert previous changes.
* tapsets.{h,cxx}: Adapt to verbose as a member of session.
* elaborate.cxx (alias_expansion_builder::build): Avoid copying
locals between alias definition and use.
* testsuite/semok/{twelve,thirteen,fourteen}.stp: New tests.
* staptree.cxx (probe_alias::printsig): Print equals sign.
* elaborate.h (systemtap_session): Add more command-line arguments.
* staptree.h (verbose): Bad global, no donut.
* elaborate.cxx: Temporarily disable verbose variable access.
* main.cxx: Support more arguments, build/run passes. Revamp
temporary file generation and partial-pass output generation.
* tapsets.cxx, translate.cxx: Emit just enough extra punctuation
and fluff to make generated probe pass -Werror.
* buildrun.cxx, buildrun.h: New files for passes 4/5. Partial
support for build pass, nothing on probe execution yet.
* testsuite/transok/*.stp: Force just -p3, now that -p4/5 exist.
* Makefile.am, Makefile.in: Corresponding changes.
* elaborate.h (systemtap_session): Add more command-line arguments.
* staptree.h (verbose): Bad global, no donut.
* elaborate.cxx: Temporarily disable verbose variable access.
* main.cxx: Support more arguments, build/run passes. Revamp
temporary file generation and partial-pass output generation.
* tapsets.cxx, translate.cxx: Emit just enough extra punctuation
and fluff to make generated probe pass -Werror.
* buildrun.cxx, buildrun.h: New files for passes 4/5. Partial
support for build pass, nothing on probe execution yet.
* testsuite/transok/*.stp: Force just -p3, now that -p4/5 exist.
* Makefile.am, Makefile.in: Corresponding changes.
* elaborate.h (symresolution_info::current_derived_probe): New field.
(symresolution_info::current_probe): Change type.
* elaborate.cxx (semantic_pass_symbols): Add passes for resolving
locals in pre-derivation base probes and pre-expansion aliases.
(symresolution_info::visit_symbol):
(symresolution_info::find_scalar): Update to match new field.
fche [Thu, 16 Jun 2005 14:59:17 +0000 (14:59 +0000)]
2005-06-14 Graydon Hoare <graydon@redhat.com>
* tapsets.h: New file.
(derived_probe_builder): Callback for making derived probes.
(match_key): Component of pattern-matching tree.
(match_node): Other component of pattern-matching tree.
* tapsets.cxx: Add pattern-matching system for probes.
(alias_derived_probe): Skeleton for alias probes.
(dwarf_derived_probe): Skeleton for dwarf probes.
(register_standard_tapsets): Registry for standard tapsets.
fche [Mon, 13 Jun 2005 14:27:49 +0000 (14:27 +0000)]
2005-06-13 Frank Ch. Eigler <fche@redhat.com>
Start separating out translator-side probe point recognition.
* tapsets.cxx: New file.
(be_derived_probe): Support for begin/end probes.
(derive_probe): Ditto. Reject anything unrecognized.
* translator.cxx: Move out old code.
* Makefile.am: Add new source file.
* testsuite/semok/*: Switch to begin/end probes only.
fche [Wed, 8 Jun 2005 22:02:09 +0000 (22:02 +0000)]
2005-06-08 Frank Ch. Eigler <fche@redhat.com>
systemtap/916
Implement all basic scalar operators, including modify-assignment.
* parse.cxx (lexer): Allow multi-character lookahead in order to
scan 1/2/3-character operators.
(parse_boolean_or/and/xor/shift): New routines.
* translate.cxx (visit_assignment, visit_binary_expression,
visit_*_crement): Generally rewrote.
(visit_*): Added more parentheses in output.
(emit_module_init): Initialize globals.
* staptree.h, elaborate.cxx, elaborate.h: Remove exponentiation.
* main.cxx (main): Add an end-of-line to output file.
* testsuite/*: Several new tests.
fche [Sat, 4 Jun 2005 02:35:18 +0000 (02:35 +0000)]
2005-06-03 Frank Ch. Eigler <fche@elastic.org>
* elaborate.cxx (find_*): Remove arity checks from here ...
* staptree.cxx (set_arity): Put arity match assertion here.
* testsuite/semko/{six,nine}.stp: Confirm logic.
* testsuite/transko/one.stp: First translation-time ko test.
fche [Fri, 3 Jun 2005 21:01:35 +0000 (21:01 +0000)]
2005-06-03 Frank Ch. Eigler <fche@redhat.com>
* TODO: Removed entries already represented in bugzilla.
* elaborate.cxx: Rewrite type inference for several operators.
* main.cxx (main): For -p2 runs, print types of function/probe locals.
* parse.cxx (scan): Identify more two-character operators.
(parse_comparison): Support the whole suite.
* translate.cxx (visit_unary_expression, logical_or_expr,
logical_and_expr, comparison,ternary_expression): New support.
* testsuite/parseok/semok.stp: Clever new test.
* testsuite/transok/four.stp: New test.
* testsuite/*: Some tweaked tests for syntax changes.
fche [Fri, 3 Jun 2005 15:54:47 +0000 (15:54 +0000)]
2005-06-03 Frank Ch. Eigler <fche@redhat.com>
* parse.cxx (scan): Support C and C++ comment styles.
* testsuite/parseok/four.stp: Test them some ...
* testsuite/parseko/nine.stp: ... and some more.
fche [Thu, 2 Jun 2005 19:43:55 +0000 (19:43 +0000)]
2005-06-02 Frank Ch. Eigler <fche@redhat.com>
Parse foreach construct. Added fuller copyright notices throughout.
* staptree.h (foreach_loop): New tree node type.
* staptree.cxx: Print it, visit it, love it, leave it.
* parse.cxx: Parse it.
(parse_stmt_block): Don't require ";" separators between statements.
(parse_array_in): Use [] as index group operator instead of ().
* elaborate.cxx (visit_foreach_loop): New code.
* translate.cxx: Slightly tighten errorcount/actioncount handling.
* main.cxx: Accept "-" as script file name standing for stdin.
(visit_arrayindex): Switch to simpler set_arity call.
* configure.ac: Generate DATE macro.
* Makefile.in, configure, config.in: Regenerated.
* testsuite/*: New/updated tests for syntax changes, foreach ().
fche [Mon, 30 May 2005 21:28:44 +0000 (21:28 +0000)]
2005-05-30 Frank Ch. Eigler <fche@redhat.com>
More fully parse & elaborate "expr in array" construct.
* staptree.h (array_in): Make this unary. Update .cxx to match.
* parse.cxx (parse_array_in): Rewrite.
(parse_symbol_plain): Removed. Update .h to match.
* elaborate.cxx (typeresolution_info::visit_array_in): New function.
(find_array): Tentatively, accept arity=0.
* translate.cxx (c_unparser::c_assign): New functions to eliminate
much ugly duplication. Use throughout.
(visit_symbol): Correct function formal argument search.
(c_tmpcounter*::visit): Add missing recursion in several functions.
* testsuite/*: Add new tests for array-in construct. Add the
first "transok" test.
* Makefile.am: Add transok tests.
* Makefile.in: Regenerated.
fche [Thu, 26 May 2005 23:57:04 +0000 (23:57 +0000)]
2005-05-26 Frank Ch. Eigler <fche@redhat.com>
* translate.cxx: Traverse trees just for common-header generation,
to emit explicit temp variables into context. Switch to explicit
"frame" pointer in generated function/probe bodies. Initialize
locals in function bodies. Rename "test_unparser" to "c_unparser"
throughout.
fche [Tue, 24 May 2005 15:03:16 +0000 (15:03 +0000)]
2005-05-24 Frank Ch. Eigler <fche@redhat.com>
* elaborate.cxx (find_array): Support automagic tapset globals.
* testsuite/semok/nine.stp: Test it ...
* testsuite/semlib/g2.stp: ... using this global array.
* staptree.cxx (stapfile print): List globals.
hunt [Tue, 17 May 2005 06:32:23 +0000 (06:32 +0000)]
2005-05-16 Martin Hunt <hunt@redhat.com>
* transport.c (_stp_cmd_handler): For STP_EXIT, schedule a
work queue to do the exit functions.
(_stp_transport_close): Call work queue for STP_EXIT.
(_stp_transport_send): Call _stp_ctrl_send() like before, except
when in probe_exit(). In that case, keep retrying on send errors
until we succeed.
* transport.h (_stp_transport_write): Change to call
_stp_transport_send() for NETLINK_ONLY.
* Makefile (KDIR): set to /lib/modules/... instead of
/usr/local/src/...