2006-10-24  David Smith  <dsmith@redhat.com>

	* tapsets.cxx (build_blacklist): Added
	"atomic_notifier_call_chain" to the blacklist (Bugzilla #3379).

2006-10-23  David Smith  <dsmith@redhat.com>

	* main.cxx (printscript): New function containing code moved from
	main().
	(main): Added code to create cache directory, call function to
	generate hash, and see if we can use cached source/module.  If
	pass 4 is actually run to produce a new module, we call
	add_to_cache() to cache the result.
	* session.h (struct systemtap_session): Added hash/cache session
	data.
	* cache.cxx: New file handling adding/getting files from the
	cache.
	* cache.h: New header file for cache.cxx.
	* hash.cxx: New file containing C++ wrapper for routines in
	mdfour.c and the find_hash function which computes the hash file
	name for an input script.
	* hash.h: New header file for hash.cxx.
	* mdfour.c: New file containing MD4 hash code.
	* mdfour.h: New header file for mdfour.c.
	* util.cxx: New file containing several utility functions used by
	the caching code.
	* util.h: New header file for util.cxx.
	* Makefile.am: Added new C/C++ files.
	* Makefile.in: Regenerated.

2006-10-23  Li Guanglei <guanglei@cn.ibm.com>
	* configure.ac, Makefile.am: add lket-b2a.1.in
	* Makefile.in, configure: regenreated
	* ket-b2a.1.in: new man page for lket-b2a
	* lket.5.in: document signal trace hooks

2006-10-18  Roland McGrath  <roland@redhat.com>

	PR 2727
	* configure.ac (elfutils build): Pass --prefix and --exec-prefix
	options to elfutils configure.
	(elfutils_abs_srcdir): New substituted variable.
	* Makefile.am (DISTCHECK_CONFIGURE_FLAGS): New variable.
	* configure, config.in, Makefile.in: Regenerated.

2006-10-16  Li Guanglei <guanglei@cn.ibm.com>

	* configure.ac: add the checking for mysql_config,
	mysqlclient library and header files
	* runtime/lket/b2a/Makefile.am: set compile flags
	according to the existance of mysql_config
	* Makefile.in, configure, testsuite/Makefile.in,
	runtime/lket/b2a/Makefile.in: regenerated

2006-10-12  Martin Hunt  <hunt@redhat.com>

	* translate.cxx (emit_common_header): Add a
	kretprobe_instance pointer to struct context.
	(emit_symbol_data): Include absolute symbols.

	* tapsets.cxx (emit_common_header): Initialize
	the kprobe instance pointer to 0;
	(emit_probe_entries): Set kretprobe instance
	pointer if appropriate.


2006-10-11  David Smith  <dsmith@redhat.com>

	* tapsets.cxx (in_kprobes_function): New function that looks up
	the values of '__kprobes_text_start' and '__kprobes_text_end' in
	the kernel to be able to automatically exclude functions marked as
	'__kprobes' (BZ# 2639).
	(blacklisted_p): Calls in_kprobes_function().
	(query_kernel_module): Utility function that finds the kernel module.
	* session.h (struct systemtap_session): Added kprobes_text
	variables - kprobes_text_initialized, kprobes_text_start, and
	kprobes_text_end.
	* elaborate.cxx (systemtap_session::systemtap_session):
	kprobes_text variables get initialized.

2006-10-10  Roland McGrath  <roland@redhat.com>

	* systemtap.spec.in (elfutils_version): Require 0.124 now.

2006-10-10  Frank Ch. Eigler  <fche@elastic.org>

	* configure.ac: Override incomplete mysql checking for now.
	* configure: Regenerated.

2006-10-10  Li Guanglei <guanglei@cn.ibm.com>

	* configure.ac: add the checking of mysql client library
	* Makefile.in, configure: regenerated

2006-09-29  Li Guanglei <guanglei@cn.ibm.com>

	* man: newly created dir for stapprobes
	* man/stapprobes.iosched.5, man/stapprobes.netdev.5, man/stapprobes.nfs.5,
	man/stapprobes.nfsd.5, man/stapprobes.pagefault.5, man/stapprobes.process.5,
	man/stapprobes.rpc.5, man/stapprobes.scsi.5, man/stapprobes.signal.5,
	man/stapprobes.tcp.5, man/stapprobes.udp.5: Some of these man pages are from
	the old stapprobes.5.in. Some are newly created(rpc, nfs, nfsd)
	* man/.cvsignore: ignore the generated man page files

2006-09-29  Li Guanglei <guanglei@cn.ibm.com>

	PR 3282
	* Makefile.am: add -DPKGLIBDIR='"$(pkglibexecdir)"' to AM_CPPFLAGS

2006-09-28  Josh Stone  <joshua.i.stone@intel.com>

	PR 3278
	* tapsets.cxx (hrtimer_derived_probe::emit_probe_entries): Only
	restart timers when the session is still active and we updated the
	expire time.

2006-09-27  Josh Stone  <joshua.i.stone@intel.com>

	* session.h (struct systemtap_session): Add kernel_base_release
	to store the kernel version without the -NNN suffix.
	* main.cxx (main): Generate and use kernel_base_release.
	* parse.cxx (eval_pp_conditional): Use kernel_base_release.
	* tapsets.cxx (profile_derived_probe::profile_derived_probe):
	Use kernel_base_release.

	* tapsets.cxx (timer_builder::build): Support a wide variety of
	timer varients -- jiffies, s/sec, ms/msec, us/usec, ns/nsec, and
	hz.  Use hrtimers automatically on kernels that have it.
	(timer_builder::register_patterns): Bind all of the new timer
	varients in one easy place.
	(register_standard_tapsets): Call timer_builder::register_patterns.
	(struct hrtimer_builder): Removed since timer_builder is generic.
	* stapprobes.5.in: Document new timer.* functionality.

	* tapsets.cxx (hrtimer_derived_probe_group::emit_probes): Add a
	shared global for the actual hrtimer resolution, _stp_hrtimer_res.
	(hrtimer_derived_probe_group::emit_module): Init _stp_hrtimer_res.
	(hrtimer_derived_probe::emit_interval): Limit intervals at a
	minimum to the hrtimer's actual resolution.
	(hrtimer_derived_probe::emit_probe_entries): Forward timers
	based on previous expiration instead of restarting relative.

2006-09-26  David Smith  <dsmith@redhat.com>

	* .cvsignore: Changed 'stpd' reference to 'staprun'.
	* INTERNALS: Ditto.
	* buildrun.cxx (run_pass): Ditto.
	* lket.5.in: Ditto.
	* stap.1.in: Ditto.
	* stapruncs.5.in: Ditto.
	* examples/small_demos/demo_script.txt: Ditto.
	* examples/small_demos/sys.stp: Ditto.

	* systemtap.spec.in: Created a new subpackage,
	"systemtap-runtime", that contains staprun.

	* Makefile.am: Renamed 'stpd' to 'staprun' and moved it to
	$(bindir).
	* Makefile.in: Regenerated from Makefile.am.

	* configure.ac: Incremented version number.
	* configure: Regenerated from configure.ac.

2006-09-22  Tom Zanussi  <zanussi@us.ibm.com>

	* stp_check.in: Add debugfs mounting.

2006-09-22  Li Guanglei <guanglei@cn.ibm.com>

	From Gui Jian <guijian@cn.ibm.com>
	* lket.5.in: document RPC trace hooks


2006-09-20  Josh Stone  <joshua.i.stone@intel.com>

	PR 3233
	* stapfuncs.5.in: Document new gettimeofday_ns.

2006-09-19  Tom Zanussi  <zanussi@us.ibm.com>

	* README: Add CONFIG_DEBUG_FS to config options.

2006-09-18  Josh Stone  <joshua.i.stone@intel.com>

	PR 3219
	From Eugeniy Meshcheryakov <eugen@debian.org>:
	* stapprobes.5.in: Correct misuse of '-' -> '\-' in manpage

2006-09-18  Martin Hunt  <hunt@redhat.com>

	* buildrun.cxx (run_pass): Remove "-m" option to stpd.
	* translate.cxx (translate_pass): #define STP_RELAYFS_MERGE
	if appropriate.

2006-09-13  Martin Hunt  <hunt@redhat.com>

	* buildrun.cxx (run_pass): Remove "-r" option to stpd.

2006-09-13  Will Cohen  <wcohen@redhat.com>

	* tapsets.cxx (perfmon_derived_probe_group::emit_module_init):
	Do not throw sematic error unless probes actually used.

2006-09-12  Will Cohen  <wcohen@redhat.com>

	PR 909
	* configure.ac: Add perfmon support options.
	* configure: Regenerated.

	* stapfuncs.5.in:
	* stapprobes.5.in: Document the perfmon support.

	* session.h, main.cxx: Track number of perfmon probes.
	* translate.cxx: Gen STP_PERFMON when perfmon probes.

	* elaborate.h:
	* elaborate.cxx (derived_probe_group):  Add register_probe() for
		perfmon probe.

	* tapsets.cxx (derived_probe::emit_common_header): Gen perfmon data.
	(perfmon_var_expanding_copy_visitor): New struct.
	(struct perfmon_derived_probe):
	(struct perfmon_derived_probe_group):
	(struct perfmon_builder):  New Perfmon probe handling structures.
	(register_standard_tapsets): Add perfmon tapset binding.
	(derived_probe_group_container):
	(~derived_probe_group_container):
	(derived_probe_group_container::register_probe):
	(derived_probe_group_container::emit_probes):
	(derived_probe_group_container::emit_module_init):
	(derived_probe_group_container::emit_module_init_call):
	(derived_probe_group_container::emit_module_exit): Add perfmon tapset.

	* tapset/perfmon.stp: New.
	* runtime/perf.c: New.
	* runtime/perf.h: New.
	* runtime/runtime.h: Include perf.c.

	* testsuite/buildok/perfmon01.stp: Test to exercise perfmon
		probes.
	* testsuite/systemtap.pass1-4/buildok.exp:

2006-09-12  Li Guanglei <guanglei@cn.ibm.com>

	From Li Xuepeng <xuepengl@cn.ibm.com>
	* lket.5.in: document nfs trace hooks

2006-09-08  David Smith  <dsmith@redhat.com>

	* elaborate.h (struct derived_probe): Replace emit_registrations()
	function with emit_registrations_start() and
	emit_registrations_end().
	(struct derived_probe_group): Added emit_module_init().
	(struct derived_probe_group_container): Added emit_module_init(),
	emit_module_init_call(), and emit_module_exit().
	* elaborate.cxx (struct alias_derived_probe): Updated
	emit_regitrations calls.
	* translate.cxx (emit_module_init): Instead of actually emitting
	per-probe-point registrations/unregistrations, let the session's
	derived_probe_group_container do it.
	* tapsets.cxx (emit_probe_timing): New function that handles
	probe timing code.
	(be_derived_probe::emit_registrations_start): Renamed from
	emit_registrations.
	(be_derived_probe_group::emit_module_init): New function that
	outputs probes create and destroy functions.
	(dwarf_derived_probe::emit_registrations): Removed, but most code
	moved to emit_registrations_start().
	(dwarf_derived_probe::emit_registrations_start): Handles details
	of multiple dwarf probe registrations.
	(dwarf_derived_probe::emit_registrations_end): Handles cleanup
	details of multiple dwarf probe registrations.
	(dwarf_derived_probe_group::emit_module_init): New function that
	outputs probes create and destroy functions.
	(timer_derived_probe::emit_registrations_start): Renamed from
	emit_registrations.  Added mutiple probe handling.
	(timer_derived_probe::emit_registrations_end): Handles cleanup
	details of multiple probe registrations.
	(timer_derived_probe_group::emit_module_init): New function that
	outputs probes create and destroy functions.
	(profile_derived_probe::emit_registrations_start): Renamed from
	emit_registrations.  Added mutiple probe handling.
	(profile_derived_probe::emit_registrations_end): Handles cleanup
	details of multiple probe registrations.
	(profile_derived_probe_group::emit_module_init): New function that
	outputs probes create and destroy functions.
	(mark_derived_probe::emit_registrations_start): Renamed from
	emit_registrations.  Added mutiple probe handling.
	(mark_derived_probe::emit_registrations_end): Handles cleanup
	details of multiple probe registrations.
	(mark_derived_probe_group::emit_module_init): New function that
	outputs probes create and destroy functions.
	(hrtimer_derived_probe::emit_registrations_start): Renamed from
	emit_registrations.  Added mutiple probe handling.
	(hrtimer_derived_probe::emit_registrations_end): Dummy function.
	(hrtimer_derived_probe_group::emit_module_init): New function that
	outputs probes create and destroy functions.
	(derived_probe_group_container::emit_module_init): Added function
	to call all probe group's emit_module_int functions.
	(derived_probe_group_container::emit_module_init_call): Added
	function to handle probe group initialization cleanup.
	(derived_probe_group_container::emit_module_exit): Added
	function to handle probe group cleanup.


2006-09-06  Frank Ch. Eigler  <fche@elastic.org>

	Add basic support for initialized globals.
	* parse.cxx (parse_global): Parse initialization clause, implement
	by rewriting to "probe begin { var = value }".
	* parse.h: Corresponding changes.
	* stap.1.in: Document optional initialization.

2006-09-04  Frank Ch. Eigler  <fche@elastic.org>

	Improve unresolved target-symbol error messages.
	* staptree.h (target_symbol): Add new field saved_conversion_error.
	* elaborate.cxx (typeresolution_info::visit_target_symbol): Throw
	that if found instead of generic error.
	* tapsets.cxx (t_v_f_c_v::visit_target_symbol): Set it.

2006-08-30  Li Guanglei <guanglei@cn.ibm.com>

	* stapprobes.5.in: document signal.*

2006-08-28  David Smith  <dsmith@redhat.com>

	* translate.cxx: Added inclusion of session.h.
	(translate_pass): Instead of asking each probe to emit itself, we
	ask the session's probes member variable to emit all the probes.
	* tapsets.cxx: Added inclusion of session.h.  Added a
	register_probe member function to all derived_probe based
	classes.  Added a derived_probe_group derived class for all probe
	types:
	(be_derived_probe_group): New class.
	(never_derived_probe_group): New class.
	(dwarf_derived_probe_group): New class.
	(timer_derived_probe_group): New class.
	(profile_derived_probe_group): New class.
	(mark_derived_probe_group): New class.
	(hrtimer_derived_probe_group): New class
	(derived_probe_group_container): New class.
	* elaborate.h: Removed inclusion of session.h since session.h now
	includes elaborate.h.
	(derived_probe): Added register_probe member function.
	(derived_probe_group): Added class definition.  This is the base
	class of all of the derived probe groups - dwarf, timer, etc.
	(derived_probe_group_container): Added class definition.  An
	instance of this class will be stored in the session and contain
	all the other probe groups.
	* elaborate.cxx (derived_probe_group::register_probe): Added
	derived_probe_group::register_probe stubs.
	(alias_derived_probe::register_probe): Added register_probe member
	function.
	(semantic_pass_symbols): After deriving a probe, the probes now
	register themselves with the session.
	* session.h: Includes elaborate.h to get
	derived_probe_group_container definition. systemtap_session class
	'probes' member variable switched from a vector of derived probes
	to a derived_probe_group_container.
	* buildrun.cxx: Added inclusion of session.h since it was removed
	from elaborate.h.
	* main.cxx: Added inclusion of session.h since it was removed
	from elaborate.h.
	* parse.h: Added forward struct declarations.
	* staptree.h: Removed inclusion of session.h.

2006-08-23  Josh Stone  <joshua.i.stone@intel.com>

	PR 3093
	From Eugeniy Meshcheryakov <eugen@debian.org>:
	* main.cxx (main): Use setenv instead of putenv, since gcc 4.2
	doesn't like assigning string constants to char*.  Also use
	const char* for result from getenv.
	* tapsets.cxx (dwflpp::setup): Copy string constant into a
	local array, to fix gcc 4.2 warning.

2006-08-22  Josh Stone  <joshua.i.stone@intel.com>

	PR 3094
	From Eugeniy Meshcheryakov <eugen@debian.org>:
	* stap.1.in: In groff, '-' produces a Unicode hyphen.  Use '\-'
	where a plain-old minus sign is desired, e.g., code examples.
	* lket.5.in, stapex.5.in, stapfuncs.5.in, stapprobes.5.in: ditto

2006-08-15  Roland McGrath  <roland@redhat.com>

	* systemtap.spec.in (elfutils_version): Require 0.123 now.

2006-08-14  David Smith  <dsmith@redhat.com>

	* elaborate.cxx (semantic_pass): Calls semantic_pass_optimize1()
	and semantic_pass_optimize2().
	(visit_functioncall): Removed setting relaxed_p since
	semantic_pass_opt5 does it.
	(semantic_pass_opt5): Goes ahead and removes duplicate functions
	since semantic_pass_opt1() won't be run again.
	(semantic_pass_optimize1): Renamed from semantic_pass_optimize().
	Moved semantic_pass_opt5() to semantic_pass_optimize2().
	(semantic_pass_optimize2): New function that contains optimization
	passes that need to be done after type inference.

2006-08-12  Frank Ch. Eigler  <fche@elastic.org>

	* Makefile.am (dist-hook): Make "make dist" dist.
	* Makefile.in: Regenerated.

2006-08-12  Frank Ch. Eigler  <fche@elastic.org>

	* configure.ac, Makefile.am: Descend into testsuite/
	directory.  Remove local test logic.
	* configure, Makefile.in: Regenerated.
	* runtest.sh: Not yet removed.
	* HACKING: Update for new testsuite layout.

2006-08-10  David Smith  <dsmith@redhat.com>

	* elaborate.cxx (duplicate_function_remover): Added class.
	(get_functionsig): Added function.
	(semantic_pass_opt5): New function merges duplicate identical
	functions into one function.
	(semantic_pass_optimize): Calls semantic_pass_opt5.

	* translate.cxx (c_unparser::emit_probe): Changed to merge
	duplicate probes bodies by making the duplicate probe just call
	the original probe (BZ# 2421).

2006-08-08  Li Guanglei <guanglei@cn.ibm.com>

	* stapprobes.5.in: document process.*, tcp.*, udp.*

2006-08-09  Thang Nguyen  <thang.p.nguyen@intel.com>

	* testsuite/buildok/iolock_test.stp: Updated for new ioblock.stp

2006-08-09  Josh Stone  <joshua.i.stone@intel.com>

	* examples/small_demos/proc_snoop.stp,
	testsuite/buildok/process_test.stp: Rename process.signal_* to
	new signal.* tapset.
	* stapprobes.5.in, testsuite/buildok/memory.stp: move pagefault
	to vm.* namespace

2006-08-08  Eugene Teo  <eteo@redhat.com>

	* tapset/context.stp (probemod): New function.
	* stapfuncs.5.in: Document it.
	* testsuite/buildok/probemod.stp: Test it.

2006-08-08  Li Guanglei <guanglei@cn.ibm.com>
	* stapprobes.5.in: document scsi.*, ioscheduler.*, netdev.* and
	pagefault.

2006-08-01  Li Guanglei <guanglei@cn.ibm.com>
	PR 2422
	* tapsets.cxx: calling get_module_dwarf(false) to give a
	warning to those modules without debuginfo and skip them

2006-07-19  Roland McGrath  <roland@redhat.com>

	* configure.ac, systemtap.spec.in: Bump version to 0.5.9.
	* configure: Regenerated.

	* systemtap.spec.in: Fix syntax in last change.

2006-07-19  David Smith  <dsmith@redhat.com>

	* testsuite/buildok/scsi.stp: Only run the scsi test if the scsi
	kernel subsystem is running.

2006-07-17  David Smith  <dsmith@redhat.com>

	* stapfuncs.5.in: Removed retval function description, since it
	has been removed.

2006-07-17  Roland McGrath  <roland@redhat.com>

	* configure.ac, systemtap.spec.in: Require elfutils-0.122.
	* configure: Regenerated.

	* systemtap.spec.in (Release): Use %{?dist}.

2006-07-17  Li Guanglei <guanglei@cn.ibm.com>

	* main.cxx: add LKET's tapsets into stap's default tapsets
	search path

2006-07-13  Frank Ch. Eigler  <fche@elastic.org>

	* systemtap.spec.in: Add formerly missing admonitional verb.

2006-07-13  David Smith  <dsmith@redhat.com>

	* parse.cxx (parser::expect_unknown2): New function that looks for
	2 possible token types.
	* parse.cxx (parser::expect_ident_or_keyword): New function that
	calls parser::expect_unknown2.
	* parse.cxx (parser::parse_symbol): Calls
	parser::expect_ident_or_keyword to allow keywords to appear when
	expanding target symbols (Bugzilla #2913).
	* parse.h: Added prototypes for parser::expect_unknown2 and
	parser::expect_ident_or_keyword.
	* testsuite/parseok/seventeen.stp: New test to check for allowing
	keywords when expanding target symbols.

2006-06-30  Josh Stone  <joshua.i.stone@intel.com>

	* tapsets.cxx (hrtimer_builder::build): Enable hrtimers on >=2.6.17.
	* tapsets.cxx (hrtimer_derived_probe::emit_probe_entries): Correct
	compilation errors, fix return value.

2006-06-30  David Smith  <dsmith@redhat.com>

	* tapsets.cxx (dwflpp::dwfl_assert): Added optional extra_msg
	parameter to be able to print out extra error message.
	(dwflpp::setup): Uses new 'extra_msg' parameter to dwfl_assert()
	to ask user to install kernel-debuginfo when
	dwfl_linux_kernel_report_kernel() or
	dwfl_linux_kernel_report_modules() fails (Bugzilla #2669).

	* buildrun.cxx (compile_pass): Checks to make sure module build
	directory exists before trying to run make there (Bugzilla #2669).

2006-06-27  Roland McGrath  <roland@redhat.com>

	* runtest.sh: Don't use eval, use proper quoting.

	* tapsets.cxx (dwflpp::emit_address): New instance method.  Get
	relocation details from Dwfl to emit in comment after address constant.
	(dwflpp::loc2c_emit_address): Just call that.

2006-06-26  Li Guanglei <guanglei@cn.ibm.com>

	* lket.in.5: update to AIO event hooks

2006-06-23  Thang P Nguyen  <thang.p.nguyen@intel.com>

	* testsuite/buildok/tcp_test.stp: updated inet calls
	* testsuite/buildok/udp_test.stp: test udp tapset

2006-06-22  Thang P Nguyen  <thang.p.nguyen@intel.com>

	* testsuite/buildok/tcp_test.stp: test tcp tapset

2006-06-16  Roland McGrath  <roland@redhat.com>

	* configure.ac, systemtap.spec.in: Bump version to 0.5.8.
	* configure: Regenerated.

	* systemtap.spec.in: Fix bundled_elfutils setting so builds can
	possibly work.  Add comment admonishing losers not to touch it.

	* aclocal.m4, Makefile.in: Regenerated with automake-1.9.6-2.

2006-06-16  Li Guanglei <guanglei@cn.ibm.com>

	* lket.in.5: update to reflect the latest changes
	to LKET

2006-06-15  Roland McGrath  <roland@redhat.com>

	* systemtap.spec.in: Require elfutils-0.121.

2006-06-14  Frank Ch. Eigler  <fche@elastic.org>

	* README: Add kernel.org blurb based on text from
	Chuck Ebbert <76306.1226@compuserve.com>.

2006-06-09  Li Guanglei <guanglei@cn.ibm.com>

	* parse.cxx, staptree.cxx, staptree.h, translate.cxx:
	delete lket_trace_extra
	* lket.5.in: delete the description of backtrace in
	LKET

2006-06-08  Thang P Nguyen  <thang.p.nguyen@intel.com>

	* testsuite/buildok/ioblock_test.stp: test ioblock

2006-06-05  David Smith  <dsmith@redhat.com>

	* tapsets.cxx (dwflpp::express_as_string): New function.
	Extracted from dwflpp::literal_stmt_for_local() so that
	dwflpp::literal_stmt_for_return() could also call it.
	(dwflpp::literal_stmt_for_local): Portion extracted to create
	dwflpp::express_as_string().
	(dwflpp::literal_stmt_for_return): New function.  Adds support for
	new symbolic access ("$return") to return value in .return
	probes.  Fixes PR 1132.
	(target_variable_flavour_calculating_visitor::visit_target_symbol):
	Calls dwflpp::literal_stmt_for_return() when in a return probe and
	the variable name is "$return".
	(dwarf_var_expanding_copy_visitor::visit_target_symbol): Ditto.
	* stapfuncs.5.in: Noted that the retval() function is deprecated.
	* stapprobes.5.in: Corrected the name of the return value
	variable.
	* tapset/return.stp: Marked the retval() function as deprecated.
	* testsuite/semko/return01.stp: Added new test.
	* testsuite/semko/return02.stp: Ditto.

2006-06-05  Frank Ch. Eigler  <fche@elastic.org>

	PR 2645 cont'd.
	* elaborate.cxx (derive_probes): Pass down optional flag
	from alias reference to expansion.
	* testsuite/semok/twentytwo.stp: Test passing-down.
	* stapprobes.5.in: Specify passing-down property of optional flag.

2006-06-02  Frank Ch. Eigler  <fche@elastic.org>

	PR 2645 cont'd.
	* elaborate.cxx (find_and_build): Support optional wildcards too.
	(derive_probes): Change last argument to indicate optionalness of
	parent probe point (alias reference).
	(alias_expansion_builder): Shrink epilogue-mode alias body copying.
	Pass along alias reference optionality.
	* elaborate.h: Corresponding changes.
	* testsuite/semko/thirtyfive.stp, semok/twentytwo.stp: New tests.

2006-06-02  Josh Stone  <joshua.i.stone@intel.com>

	* testsuite/buildok/process_test.stp: add signal_handle test
	* examples/small_demos/proc_snoop.stp: log signal_handle

2006-06-02  Frank Ch. Eigler  <fche@elastic.org>

	PR 2645.
	* stapprobes.5.in: Document "?" probe point suffix.
	* parse.cxx (parse_probe_point): Recognize "?" optional suffix.
	* elaborate.cxx (derive_probes): Observe probe_point->optional.
	* staptree.h, staptree.cxx: Corresponding changes.
	* tapsets.cxx (never_derived_probe, never_builder): New classes.
	(register_standard_tapsets): Support "never" probe point.
	* testsuite/buildok/six.stp, parseok/five.stp: Modifed tests.

	* translate.cxx (emit_module_init): Format "-t" (benchmarking)
	cycle-time reports similarly to "-v" (verbose) times.

2006-06-02  David Smith  <dsmith@redhat.com>

	* .cvsignore: Added more files to ignore.

	* main.cxx (usage): Added exitcode parameter.
	(main): Improved a few error messages.  Also, when an error is
	given, stap now always exits with a status of 1.

	* testsuite/buildok/cmdline01.stp: New test.
	* testsuite/parseko/cmdline01.stp: Ditto.
	* testsuite/parseko/cmdline02.stp: Ditto.
	* testsuite/parseko/cmdline03.stp: Ditto.
	* testsuite/parseko/cmdline04.stp: Ditto.
	* testsuite/parseko/cmdline05.stp: Ditto.
	* testsuite/parseko/cmdline06.stp: Ditto.
	* testsuite/parseok/cmdline01.stp: Ditto.
	* testsuite/parseok/cmdline02.stp: Ditto.

2006-06-01  Josh Stone  <joshua.i.stone@intel.com>

	* tapsets.cxx (hrtimer_derived_probe::emit_interval): update
	API usage of hrtimers in preparation of getting exports from
	the kernel.
	(hrtimer_derived_probe::emit_probe_entries): ditto

2006-06-01  Li Guanglei <guanglei@cn.ibm.com>

	* parse.cxx, staptree.cxx, staptree.h, translate.cxx:
	add new function lket_trace_extra at script level
	* lket.5.in: Modified the description of backtrace in
	LKET

2006-05-29  Li Guanglei <guanglei@cn.ibm.com>

	* systemtap.spec.in: include lket-b2a in the rpm package

2006-05-27  Li Guanglei <guanglei@cn.ibm.com>

	* configure.ac: add conditional build of lket-b2a
	if glib2-devel is not found, just skips and gives
	a warning
	* Makefile.am:  add conditional build of lket-b2a
	* Makefile.in, configure: regenerated
	* runtime/lket/b2a/Makefile: deleted. Should be
	generated by configure

2006-05-26  Josh Stone  <joshua.i.stone@intel.com>

	* tapsets.cxx (build_blacklist): build the sets of blacklisted
	functions and function returns.  Manually added many __kprobes
	functions that should not be probed.
	(dwarf_query::dwarf_query): Call build_blacklist.
	(dwarf_query::blacklisted_p): Use blacklist sets.

2006-05-25  Josh Stone  <joshua.i.stone@intel.com>

	* parse.cxx (parser::scan_pp): Free memory for tokens that are
	thrown away in the preprocessing stage.
	* tapsets.cxx
	(dwarf_var_expanding_copy_visitor::visit_target_symbol):
	Free allocated memory when supressing target-variable errors

2006-05-25  David Smith  <dsmith@redhat.com>

	* testsuite/semok/twentyone.stp: New file.

2006-05-24  Frank Ch. Eigler  <fche@elastic.org>

	Pass 4 speedup.
	* tapsets.cxx (derived_probe::emit_common_header): New
	function, to emit code formerly inlined by
	emit_probe_prologue/epilogue.
	* translate.cxx (emit_common_header): Call it.
	* elaborate.h: Corresponding changes.

2006-05-24  David Smith  <dsmith@redhat.com>

	* elaborate.cxx (isglob): New function.
	(match_key::globmatch): New function.
	(match_node::find_and_build): Uses isglob() and
	match_key::globmatch() to provide support for wildcards such as
	"kernel.syscall.*read*" (Bugzilla #1928).
	* elaborate.h (match_key::globmatch): Added function declaration.
	* parse.cxx (parser::parse_probe_point): Collects one or more
	tokens into a single probe-point functor string.

	* testsuite/parseko/twentytwo.stp: New file.
	* testsuite/parseok/sixteen.stp: New file.

2006-05-24  David Smith  <dsmith@redhat.com>

	* testsuite/parseko/cmdlinearg01.stp: New file.
	* testsuite/parseko/cmdlinearg02.stp: New file.
	* testsuite/parseko/eighteen.stp: New file.
	* testsuite/parseko/foreachstmt01.stp: New file.
	* testsuite/parseko/foreachstmt02.stp: New file.
	* testsuite/parseko/foreachstmt03.stp: New file.
	* testsuite/parseko/foreachstmt04.stp: New file.
	* testsuite/parseko/foreachstmt05.stp: New file.
	* testsuite/parseko/forstmt01.stp: New file.
	* testsuite/parseko/forstmt02.stp: New file.
	* testsuite/parseko/forstmt03.stp: New file.
	* testsuite/parseko/forstmt04.stp: New file.
	* testsuite/parseko/functiondecl01.stp: New file.
	* testsuite/parseko/functiondecl02.stp: New file.
	* testsuite/parseko/functiondecl03.stp: New file.
	* testsuite/parseko/functiondecl04.stp: New file.
	* testsuite/parseko/functiondecl05.stp: New file.
	* testsuite/parseko/functiondecl06.stp: New file.
	* testsuite/parseko/functiondecl07.stp: New file.
	* testsuite/parseko/ifstmt01.stp: New file.
	* testsuite/parseko/ifstmt02.stp: New file.
	* testsuite/parseko/nineteen.stp: New file.
	* testsuite/parseko/preprocess01.stp: New file.
	* testsuite/parseko/preprocess02.stp: New file.
	* testsuite/parseko/preprocess03.stp: New file.
	* testsuite/parseko/preprocess04.stp: New file.
	* testsuite/parseko/preprocess05.stp: New file.
	* testsuite/parseko/preprocess06.stp: New file.
	* testsuite/parseko/preprocess07.stp: New file.
	* testsuite/parseko/preprocess08.stp: New file.
	* testsuite/parseko/preprocess09.stp: New file.
	* testsuite/parseko/probepoint01.stp: New file.
	* testsuite/parseko/probepoint02.stp: New file.
	* testsuite/parseko/probepoint03.stp: New file.
	* testsuite/parseko/seventeen.stp: New file.
	* testsuite/parseko/ternarystmt01.stp: New file.
	* testsuite/parseko/twenty.stp: New file.
	* testsuite/parseko/twentyone.stp: New file.
	* testsuite/parseko/whilestmt01.stp: New file.
	* testsuite/parseko/whilestmt02.stp: New file.

2006-05-24  Li Guanglei <guanglei@cn.ibm.com>

	* configure.ac: add lket.5 & runtime/lket/b2a
	* Makefile.am:  add lket & runtime/lket/b2a
	* aclocal.m4, Makefile.in, configure: regenerated
	* runtime/lket/b2a/*: a binary to ascii converter used
	to convert LKET's default binary trace data.
	* lket.5.in: add intro of lket-b2a converter.

2006-05-23  David Smith  <dsmith@redhat.com>

	* parse.cxx (parse_for_loop): Corrected error message.

2006-05-22  David Smith  <dsmith@redhat.com>

	* elaborate.cxx (find_and_build): Fixed issue #2643.  Wildcard
	code was being too optimistic.

2006-05-22  Li Guanglei <guanglei@cn.ibm.com>

	* lket.in.5: draft version of manpage for LKET
	* Makefile.in, configure, stap.1.in: add lket.in.5

2006-05-18  Frank Ch. Eigler  <fche@elastic.org>

	Organize "-t" output by script/parse level probes rather than
	derived-probes.
	* elaborate.cxx (derived_probe ctor): Remove name field setting.
	(alias_derived_probe): New class.
	(alias_expandion_builder::build): Create an instance of the above
	instead of parse-tree-level plain probe.
	* elaborate.h: Corresponding changes.
	(derived_probe::basest): Define.
	* staptree.cxx (probe ctor): Set new name field.
	* staptree.h (probe): Corresponding changes.
	(probe::basest): New field.
	* tapsets.cxx (emit_probe_prologue, emit_probe_entries):
	Switch to basest() probe name for Stat instance.
	(dwarf_derived_probe ctor): Stash away base probe.
	* translate.cxx (unparser::emit_probe): Remove index
	operand, just use probe name to generate symbols.
	(emit_module_init): Reorganize -t output in unregister functions.
	(translate_pass): Remove unparser::current_probenum field and all
	uses.
	* translate.h: Corresponding changes.

2006-05-18  Li Guanglei <guanglei@cn.ibm.com>

	* tapset/LKET/*: tracing tapsets of LKET
	* tapset/context.stp: add stp_pid() func
	* tapset/ppc64/syscalls.stp: add conditional preprocessing
	since sys64_time is removed from kernel >= 2.6.16

2006-05-18  Li Guanglei <guanglei@cn.ibm.com>

	* tapset/tskschedule.stp: deleted, merge into scheduler.stp
	* tapset/scheduler.stp:   incorporate tskschedule.stp
	* testsuite/buildok/tskschedule.stp: deleted, merge into
	  sched_test.stp
	* testsuite/buildok/sched_test.stp: incorporate tskschedule.stp

2006-05-17  Josh Stone  <joshua.i.stone@intel.com>

	* testsuite/buildok/sched_test.stp: test scheduler tapset
	* examples/small_demos/sched_snoop.stp: demo scheduler tapset

2006-05-18  Li Guanglei <guanglei@cn.ibm.com>

	* testsuite/buildok/ioscheduler.stp: testcase for ioscheduler.stp
	* testsuite/buildok/memory.stp:      testcase for memory.stp
	* testsuite/buildok/networking.stp:  testcase for networking.stp
	* testsuite/buildok/scsi.stp:        testcase for scsi.stp
	* testsuite/buildok/tskschedule.stp: testcase for tskschedule.stp

2006-05-18  Li Guanglei <guanglei@cn.ibm.com>

	* tapset/ioscheduler.stp: generic IO scheduler tapsets from LKET
	* tapset/memory.stp:      generic pagefault tapsets from LKET
	* tapset/networking.stp:  generic networking tapsets from LKET
	* tapset/scsi.stp:        generic scsi tapsets from LKET
	* tapset/tskschedule.stp: generic task scheduler tapsets from LKET
	* tapset/process.stp:     changes to process.exec alias

2006-05-16  David Smith  <dsmith@redhat.com>

	* parse.cxx (parser::parser): Added initializer for 'context'
	member variable.
	(tt2str): Added support for new tok_keyword type.
	(operator <<): Ignores keyword content when outputting error
	message.
	(lexer::scan): Recognizes keywords, such as 'probe', 'global',
	'function', etc. and classifies them as type 'tok_keyword'.  This
	causes keywords to become reserved so they cannot be used for
	function names, variable names, etc.
	(parser::parse): Changed tok_identifier to tok_keyword when looking
	for "probe", "global", or "function".  Also sets context member
	variable which remembers if we're in probe, global, function, or
	embedded context.
	(parser::parse_probe, parser::parse_statement)
	(parser::parse_global, parser::parse_functiondecl)
	(parser::parse_if_statement, parser::parse_delete_statement)
	(parser::parse_break_statement, parser::parse_continue_statement)
	(parser::parse_for_loop, parser::parse_while_loop)
	(parser::parse_foreach_loop, parser::parse_array_in): Looks for
	tok_keyword instead of tok_identifier.
	(parser::parse_probe_point): Allows keywords as part of a probe
	name, since "return" and "function" are keywords.
	(parser::parse_return_statement): Looks for tok_keyword instead of
	tok_identifier.  Make sure we're in function context.
	(parser::parse_next_statement): Looks for tok_keyword instead of
	tok_identifier.  Make sure we're in probe context.
	* parse.h: Added parse_context enum.  Added 'tok_keyword' to
	token_type enum.  Added parse_context 'context' member variable to
	parser class.
	* stap.1.in: Because the string() function has been removed,
	the 'string()' function reference has been changed to a 'sprint()'
	function reference.
	* stapex.5.in: Ditto.
	* stapfuncs.5.in: The description of the string() and hexstring()
	functions has been removed.
	* testsuite/buildok/context_test.stp: Calls to the string()
	function were converted to sprint() function calls.
	* testsuite/buildok/fifteen.stp: Ditto.
	* testsuite/buildok/nineteen.stp: Ditto.
	* testsuite/buildok/process_test.stp: Ditto.
	* testsuite/buildok/task_test.stp: Ditto.
	* testsuite/buildok/timestamp.stp: Ditto.
	* testsuite/buildok/twentyone.stp: Ditto.
	* testsuite/semok/args.stp: Ditto.
	* testsuite/semok/seven.stp: Ditto.
	* testsuite/buildok/fourteen.stp: Calls to log()/string() were
	converted to a call to printf().
	* testsuite/buildok/sixteen.stp: Ditto.
	* testsuite/buildok/thirteen.stp: Ditto.
	* testsuite/buildok/twentythree.stp: Ditto.
	* testsuite/buildok/twentytwo.stp: Ditto.
	* testsuite/buildok/seven.stp: Calls to the string()
	function were converted to sprint() calls.  Calls to the
	hexstring() function were converted to sprintf() calls.
	* testsuite/semok/eleven.stp: Ditto.
	* testsuite/buildok/seventeen.stp: Calls to log()/hexstring() were
	converted to a call to printf().
	* testsuite/semko/nineteen.stp: Ditto.
	* testsuite/parseok/three.stp: Because keywords are reserved, a
	variable named 'string' was renamed to 'str'.
	* testsuite/parseok/two.stp: Because keywords are reserved, a
	variable named 'global' was renamed to 'gbl'.
	* testsuite/transko/two.stp: Because the parser now checks for
	'next' and 'return' statement context, a 'next' statement was
	removed from a function and a 'return' statement was removed from
	a probe.

2006-05-15  Frank Ch. Eigler  <fche@elastic.org>

	* 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().

2006-05-12  Thang P Nguyen  <thang.p.nguyen@intel.com>

	* testsuite/buildok/probefunc.stp: test probefunc()

2006-05-12  Frank Ch. Eigler  <fche@elastic.org>

	* stapfuncs.5.in: Clarify backtrace-related functions.

2006-05-11  David Smith  <dsmith@redhat.com>

	* tapset/ctime.stp: New file.

2006-05-09  Josh Stone  <joshua.i.stone@intel.com>

	* examples/small_demos/proc_snoop.stp: monitor all process events.
	* testsuite/buildok/task_test.stp: test compilation of all task
	functions.
	* testsuite/buildok/process_test.stp: test all process events and
	associated variables.

2006-05-09  Will Cohen  <wcohen@redhat.com>

	PR 2228
	* parse.h:
	* parse.cxx: Add << operator for struct source_loc.
	* translate.cxx (emit_module_init): Print location of probe in script.

2006-05-09  Li Guanglei <guanglei@cn.ibm.com>

	PR 2520
	* main.cxx: add -M option to stop merge per-cpu files in bulk mode
	* session.h: add merge member into systemtap_session
	* buildrun.cxx: generate stpd_cmd to stop merge per-cpu files if -M
	option is turned on by stap.

2006-05-08  Li Guanglei <guanglei@cn.ibm.com>

	PR 2627
	* elaborate.cxx: epilogue style alias expansion
	* parse.cxx: parse += alias definition
	* staptree.h: add epilogue_style member to probe_alias
	* stap.1.in: add the description of epilogue style alias
	* testsuite/parseok/fifteen.stp: testcase for epilogue style alias

2006-05-05  Roland McGrath  <roland@redhat.com>

	* configure.ac (build_elfutils): Pass CFLAGS to elfutils configure,
	editting out -Wall.
	* configure: Regenerated.

2006-05-05  Frank Ch. Eigler  <fche@elastic.org>

	PR 2643
	* testsuite/buildok/syscalls.stp: Take "-u" away again.
	* configure.ac, systemtap.spec.in: Bump version to 0.5.7.
	* configure: Regenerated.

2006-05-05  Frank Ch. Eigler  <fche@elastic.org>

	* configure.ac, systemtap.spec.in: Bump version to 0.5.6.
	* configure: Regenerated.

2006-05-05  Will Cohen  <wcohen@redhat.com>

	* small_demos/fileopen.stp: Shows use of target() to look at pid.
	* small_demos/rwtiming.stp: Shows per executable histograms of time
	spent in read and write system calls.

2006-05-05  Eugene Teo  <eteo@redhat.com>

	PR 2433
	* tapsets.cxx (dwarf_query::blacklisted_p): Extend the list of
	blacklisted .return probes to include "do_exit". Correct funcname
	typo for "sys_groupexit".
	* tapset/syscalls.stp: Remove .return probe aliases of never-
	returning syscall.exit and syscall.exit_group calls.

2006-05-05  David Smith  <dsmith@redhat.com>

	* translate.cxx (mapvar::exists): Added code for string array
	handling.  Otherwise, string array elements always exist.

2006-05-03  Josh Stone  <joshua.i.stone@intel.com>

	PR 2506
	* tapsets.cxx (dwarf_query::blacklisted_p): skip probes in .exit.*

2006-05-02  Will Cohen  <wcohen@redhat.com>

	* translate.cxx (emit_module_init): Move closing '}' inside #ifdef.

2006-05-02  Will Cohen  <wcohen@redhat.com>

	PR 2228
	* stap.1.in: Document "-t" option.
	* main.cxx (main): Add "-t" option for collecting timing information.
	* session.h (systemtap_session): Corresponding changes.
	* tapsets.cxx (emit_probe_prologue, emit_probe_epilogue,
	emit_probe_entries):
	* translate.cxx: (emit_common_header, emit_module_init,
	translate_pass): Add time collection of timing information.


2006-05-01  Frank Ch. Eigler  <fche@elastic.org>

	* translate.cxx (visit_print_format): Fix regression in
	"printf" pseudo-result initialization.

2006-04-30  Frank Ch. Eigler  <fche@elastic.org>

	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-04-25  Frank Ch. Eigler  <fche@elastic.org>

	* Makefile.am: Removed "rpm" target.
	* Makefile.in, aclocal.m4: Regenerated.

2006-04-25  Frank Ch. Eigler  <fche@elastic.org>

	* elaborate.cxx (typeresolution_info::unresolved,invalid,
	mismatch): Print current function/probe name in error message.
	(semantic_pass_types): Pass sufficient information.
	* elaborate.h: Corresponding changes.

2006-04-25  Frank Ch. Eigler  <fche@elastic.org>

	PR 2427.
	* staptree.cxx (varuse_collecting_visitor::visit_embeddedcode):
	Support /* pure */ declaration.  Stop using __tvar_ naming hack.
	(v_c_u::visit_print_format): Mark sprint and sprintf as
	side-effect-free.
	(deep_copy_visitor::visit_print_format): Propagate raw_components.
	* stap.1.in: Document declaration.
	* elaborate.cxx (semantic_pass_opt2): Verbose message tweak.
	(dead_stmtexpr_remover): Extend for more aggressive optimization.
	* tapsets.cxx (dwarf,mark_var_expanding_copy_visotor): Add
	/* pure */ declaration to rvalue expansions.
	* tapset/*.stp: Added /* pure */ declarations to many functions.
	* testsuite/parseok/unparsers.stp: Propagate guru mode flag.
	* testsuite/buildok/twentyfour.stp: New test.

2006-04-24  Frank Ch. Eigler  <fche@elastic.org>

	PR 2599.
	* elaborate.cxx (visit_assignment): Tolerate null current_expr.
	* testsuite/semok/optimize.stp: Add relevant tests.

2006-04-23  Eugene Teo  <eteo@redhat.com>

	PR 2149
	* translate.cxx (mapvar::set): Test _stp_map_set_xx() for
	array overflows.

2006-04-23  Eugene Teo  <eteo@redhat.com>

	* small_demos/ansi_colors.stp: Add an example of using octal
	escape sequences to display all possible ansi colors.

2006-04-21  Eugene Teo  <eteo@redhat.com>

	PR 1326
	* translate.cxx (c_unparser::visit_binary_expression): Handle
	negative left and right shift count.

2006-04-21  Frank Ch. Eigler  <fche@elastic.org>

	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.

2006-04-19  Eugene Teo  <eteo@redhat.com>

	PR 2014
	* parse.cxx (lexer::scan): Added \[0-7]* case to preserve
	octal escape sequences.

2006-04-18  Martin Hunt  <hunt@redhat.com>

	* Makefile.am (install-data-local): Another try.

2006-04-18  Frank Ch. Eigler  <fche@elastic.org>

	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  Martin Hunt  <hunt@redhat.com>

	* Makefile.am (install-data-local): Tweak previous fix.
	(install-data-local):

2006-04-18  Martin Hunt  <hunt@redhat.com>

	* Makefile.am (install-data-local): Rewrite. Set
	ownership and permissions for all files and directories
	under runtime and tapset. Restrict files to source code.

	* Makefile.in: Rebuilt.

2006-04-18  Eugene Teo  <eteo@redhat.com>

	PR 1341
	* main.cxx (main): Use TMPDIR instead of hard-coded /tmp.

2006-04-17  Frank Ch. Eigler  <fche@elastic.org>

	* tapsets.cxx (mark_derived_probe::emit_{de}registrations):
	Use cmpxchg to synchronize.

2006-04-12  Tom Zanussi  <zanussi@us.ibm.com>

	PR 2538
	* buildrun.cxx (compile_pass): Remove space
	between -I and runtime path.

2006-04-12  Martin Hunt  <hunt@redhat.com>

	PR 2497
	* translate.cxx (translate_pass): Don't
	reset STP_STRING_SIZE if it was already defined.
	Set it to 1024 by default.

2006-04-10  Martin Hunt  <hunt@redhat.com>

	* translate.cxx (visit_print_format): Call
	_stp_snprintf() instead of snprintf().

2006-04-09  Martin Hunt  <hunt@redhat.com>

	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'

2006-04-08  Frank Ch. Eigler  <fche@elastic.org>

	* 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-04-04  Roland McGrath  <roland@redhat.com>

	* configure.ac: Bump version to 0.5.5.
	Require elfutils-0.120.
	* configure: Regenerated.
	* systemtap.spec.in: Likewise.

	* main.cxx (version): Use dwfl_version.

	* loc2c.c (array_stride): stride_size -> byte_stride

2006-04-04 Tom Zanussi  <zanussi@us.ibm.com>

	* stp_check: Change test for relay vs relayfs

2006-03-30  Martin Hunt  <hunt@redhat.com>

	* 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>

	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>

	* 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-28  Martin Hunt  <hunt@redhat.com>

	* testsuite/buildok/syscall.stp: Update so
	it works again.

2006-03-16 Tom Zanussi  <zanussi@us.ibm.com>

	* configure.ac: Revert relayfs version check.
	* configure: Reverted.
	* translate.cxx (compile_pass): Remove relayfs include path.

2006-03-15 Tom Zanussi  <zanussi@us.ibm.com>

	* configure.ac: Add check for relayfs version.
	* configure: Regenerated.
	* stp_check.in: Remove bundled relayfs loading/compilation, add
	check for relay (vs relayfs).

2006-03-13  Josh Stone  <joshua.i.stone@intel.com>

	* safety/safety.py: Support IA64 disassembly matching.
	* safety/data/opcodes-ia64: new opcode rules for IA64.
	* safety/data/references: Add references used by example scripts
	when compiled for IA64.

2006-03-13  Frank Ch. Eigler  <fche@elastic.org>

	* translate.cxx (emit_globals): Tag globals, especially the locks,
	as __cacheline_aligned.

2006-03-09  Frank Ch. Eigler  <fche@elastic.org>

	* translate.cxx (emit_locks): Emit dummy references to unlock_ ...
	(emit_module_init): ... and probe_point.

2006-03-06  Frank Ch. Eigler  <fche@elastic.org>

	PR 2425
	* staptree.cxx (varuse_collecting_visitor::visit_embeddedcode):
	Realize that $var-setter functions have side-effects.
	* testsuite/transok/tval-opt.stp: New test.

2006-03-06  Martin Hunt  <hunt@redhat.com>

	* buildrun.cxx (run_pass): Add "-u username".
	* stapfuncs.5.in: Document system().

2006-03-06  Frank Ch. Eigler  <fche@elastic.org>

	* stapex.5.in: Use \[aq] for plain single quotes for encoding
	variation tolerance.

2006-03-03  Josh Stone  <joshua.i.stone@intel.com>

	* main.cxx (main): search forward for dashes in the kernel release,
	to work properly with release names with more than one dash.  Also
	* 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

	PR 2390
	* main.cxx (main): expand search path so that revision w.x.y.z
	searches w.x.y.z, w.x.y, and w.x.

2006-03-03  Frank Ch. Eigler  <fche@elastic.org>

	* tapset/indent.stp, indent-default.stp: New little tapset.
	* stapfuncs.5.in: Document it.
	* testsuite/buildok/indent.stp: Build it.

2006-02-27  Josh Stone  <joshua.i.stone@intel.com>

	* safety/*: Add a static safety checker.

2006-02-25  Frank Ch. Eigler  <fche@elastic.org>

	* 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.

2006-02-23  Frank Ch. Eigler  <fche@elastic.org>

	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-23  Roland McGrath  <roland@redhat.com>

	* Makefile.am (AUTOMAKE_OPTIONS): New variable, set dist-bzip2.
	* Makefile.in: Regenerated.

2006-02-23  Martin Hunt  <hunt@redhat.com>

	PR 1989. Adds support for %p in printf
	* staptree.h (struct print_format): Add conv_unsigned_ptr.
	* staptree.cxx (components_to_string): Output 'p'
	for conv_unsigned_ptr.
	* elaborate.cxx (visit_print_format): Add case for
	conv_unsigned_ptr.

2006-02-23  Martin Hunt  <hunt@redhat.com>

	* Makefile.am (install-data-local): Create tapset/i686 and
	tapset/x86_64 directories. This fixes a problem where they
	were included, but had bad permissions.
	* Makefile.in: Rebuilt.

2006-02-22  Frank Ch. Eigler  <fche@elastic.org>

	* stapfuncs.5.in: Document get_cycles().
	* testsuite/buildok/timestamp.stp: Build it and its friends.

2006-02-22  Frank Ch. Eigler  <fche@elastic.org>

	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-17  Frank Ch. Eigler  <fche@elastic.org>

	* stapfuncs.5.in (cpu): Document contextinfo function.

2006-02-15  Frank Ch. Eigler  <fche@elastic.org>

	* translate.cxx (varlock*): Removed now unnecessary class.
	(aggregation_locks): Renamed field to aggregations_active.

2006-02-14  Frank Ch. Eigler  <fche@elastic.org>

	* stapfuncs.5.in: Document new queue_stats tapset.
	* elaborate.cxx (*): Put "while:" clarification messages before a
	thrown semantic error.
	* staptree.cxx (print_format::string_to_components): Correct
	parse of "%%" formatting element.

2006-02-07  Frank Ch. Eigler  <fche@elastic.org>

	* 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>

	PR 2068
	* tapsets.cxx (dwarf_query::blacklisted_p): add __switch_to
	to the blacklist for x86_64 architecture only.

2006-02-06  Will Cohen  <wcohen@redhat.com>

	* tapset/syscall2.stp: Correct opening comment typo.

2006-02-06  Will Cohen  <wcohen@redhat.com>

	* tapset/syscall2.stp: Correct closing comment typos.

2006-02-01  Frank Ch. Eigler  <fche@elastic.org>

	* testsuite/semko/one.stp: Make sure test case stays broken.

2006-02-01  Martin Hunt  <hunt@redhat.com>

	* stapfuncs.5.in: Document is_return(), returnval() and
	probefunc().
	* testsuite/buildok/syscall.stp: Basic syscall test.

2006-02-01  Frank Ch. Eigler  <fche@elastic.org>

	* configure.ac, systemtap.spec.in: Version 0.5.4.
	* configure: Regenerated.

2006-01-31  Josh Stone  <joshua.i.stone@intel.com>

	PR 2252
	* translate.cxx (translate_pass): Fix legacy definition of
	read_trylock.

2006-01-30  Frank Ch. Eigler  <fche@elastic.org>

	* main.cxx (main): Also print elapsed real time for each pass.

2006-01-27  Frank Ch. Eigler  <fche@elastic.org>

	* 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-27  Frank Ch. Eigler  <fche@elastic.org>

	* main.cxx (main): In verbose mode, print user+sys times after
	each pass.
	* buildrun.cxx (compile_pass): Move success message back to main().

2006-01-26  Frank Ch. Eigler  <fche@elastic.org>

	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.

2006-01-25  Frank Ch. Eigler  <fche@elastic.org>

	PR 2205, patch from <hiramatu@sdl.hitachi.co.jp>:
	* parse.cxx (scan): Correct EOF detection for %{ %} case.

2006-01-24  Frank Ch. Eigler  <fche@elastic.org>

	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>

	* tapsets.cxx (profile_derived_probe::emit_probe_entries): Setup
	c->regs properly in light of the emit_probe_prologue change.

2006-01-18  Josh Stone  <joshua.i.stone@intel.com>

	* translate.cxx (c_unparser::visit_foreach_loop): improved the error
	message when _stp_pmap_agg fails.

2006-01-18  Frank Ch. Eigler  <fche@elastic.org>

	* translate.cxx (c_unparser_assignment::visit_arrayindex):
	Eliminate dummy assignments for "<<<" code.

2006-01-17  Josh Stone  <joshua.i.stone@intel.com>

	PR 2156
	* testsuite/buildok/pmap_foreach.stp: Add test with sorting

2006-01-17  Josh Stone  <joshua.i.stone@intel.com>

	PR 2156
	* translate.cxx (c_unparser::visit_foreach_loop): Check the return
	value of _stp_pmap_agg() for NULL.

2006-01-17  Frank Ch. Eigler  <fche@elastic.org>

	* systemtap.spec.in: Remove explicit kernel-devel dependency,
	since some old kernel rpm builds don't virtual-provide it for
	e.g. smp, hugemem.

2006-01-17  Frank Ch. Eigler  <fche@elastic.org>

	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.

2006-01-17  Josh Stone  <joshua.i.stone@intel.com>

	* stap.1.in: Document the 'delete' operator.

2006-01-16  Roland McGrath  <roland@redhat.com>

	* systemtap.spec.in (elfutils_version): Require 0.119 now.
	* configure.ac, systemtap.spec.in: Version 0.5.3.
	* configure: Regenerated.

2006-01-16  Josh Stone  <joshua.i.stone@intel.com>

	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-15  Frank Ch. Eigler  <fche@elastic.org>

	PR 2148
	* translate.cxx (MAXERRORS): Actually the max should be 0, so first
	error aborts session.

2006-01-13  Frank Ch. Eigler  <fche@elastic.org>

	* main.cxx (main): Suppress "Try again with -v" message if already
	verbose.

2006-01-13  Frank Ch. Eigler  <fche@elastic.org>

	* translate.cxx (c_unparser:getmap): Correct exception throwing typo.

2006-01-12  Josh Stone  <joshua.i.stone@intel.com>

	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.

2006-01-11  Josh Stone  <joshua.i.stone@intel.com>

	PR 2140
	* testsuite/buildok/delete.stp: Test correct compilation of the
	'delete' operator for all "legal" variations.

2006-01-11  Frank Ch. Eigler  <fche@elastic.org>

	* translate.cxx (MAXERRORS): Oops, set back to intended default of 1.

2006-01-10  Frank Ch. Eigler  <fche@redhat.com>

	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>

	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-09  Frank Ch. Eigler  <fche@redhat.com>

	* HACKING: Extend guidelines for tapset testing.

2006-01-06  Will Cohen  <wcohen@redhat.com>

	* Makefile.am (gcov,lcov): Don't remove .gcno .gcda files.
	* Makefile.am (gcov): Fix to report data when tests fail.
	* Makefile.am (lcov): New rule to generate html coverage data.
	* Makefile.in: Regenerated.

2006-01-05  Josh Stone  <joshua.i.stone@intel.com>

	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.

2006-01-04  Frank Ch. Eigler  <fche@elastic.org>

	PR 2057.
	* translate.cxx (c_unparser_assignment::visit_arrayindex): Don't take
	write lock around pmap accumulation.

2006-01-04  Will Cohen  <wcohen@redhat.com>

	* testsuite/buildok/printf.stp: Improve test coverage.

2006-01-03  Frank Ch. Eigler  <fche@redhat.com>

	* tapsets.cxx (emit_deregistration): Fix bad thinko on loop nesting.

2006-01-03  Frank Ch. Eigler  <fche@redhat.com>

	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.

2005-12-23  Kevin Stafford  <krstaffo@us.ibm.com>

	* tapset/2.6.9-20.ELsmp/syscalls.stp: added kernel
	version tapset
	* tapset/2.6.9-20.ELsmp/i686/syscalls.stp: added kernel
	version arch specific tapset
	* tapset/doc/discrepancies.txt: log of kernel version
	discrepancies.

2005-12-22  Roland McGrath  <roland@redhat.com>

	* configure.ac: Pass LDFLAGS to elfutils configure to force DT_RUNPATH.
	* configure: Regeneraed.

2005-12-21  Josh Stone  <joshua.i.stone@intel.com>

	PR 2056
	* translate.cxx (itervar::next): emit different code for pmaps

2005-12-21  Frank Ch. Eigler  <fche@elastic.org>

	* loc2c.h: Add __attribute__ defeating code for g++ 3.3 compatibility.

2005-12-20  Josh Stone  <joshua.i.stone@intel.com>

	* vim/filetype.vim: defines *.stp files as SystemTap scripts
	* vim/ftplugin/stap.vim: sets the comment styles
	* vim/indent/stap.vim: enables simple auto-indenting
	* vim/syntax/stap.vim: defines syntax highlighting

2005-12-19  Roland McGrath  <roland@redhat.com>

	* configure.ac, systemtap.spec.in: Version 0.5.2.
	* configure: Regenerated.

2005-12-17  Roland McGrath  <roland@redhat.com>

	* staptree.h: #include <cassert> here.

2005-12-14  Kevin Stafford  <krstaffo@us.ibm.com>

	* tapset/2.6.14/syscalls.stp: Added 2.6.14 syscalls to tapset.
	* 2.tapset/6.14/i686/syscalls.stp: Added i386 arch specific syscalls
	to tapset for kernel 2.6.14.
	* tapset/2.6.9-24.ELsmp/syscalls.stp: Added 2.6.9-24.ELsmp syscalls.
	* tapset/2.6.9-24.ELsmp/x86_64/syscalls.stp: Added x86_64 arch
	specific syscalls to tapset for kernel 2.6.9-24.ELsmp.
	* tapset/system_calls.stp: File removed.

2005-12-14  Martin Hunt  <hunt@redhat.com>

	* tapset/system_calls.stp (epoll.ctl): Temporarily remove
	references to $op and $event because gcc 4.0.2 can't
	find them.
	(epoll.wait): Ditto for $maxevents.

2005-12-13  Frank Ch. Eigler  <fche@redhat.com>

	* tapsets.cxx (var_expanding_copy_visitor::visit_target):
	Transcribe token pointer to synthesized functiondecl.

2005-12-12  Josh Stone  <joshua.i.stone@intel.com>

	* tapset/context.stp
	(execname,pid,tid,ppid,pexecname,gid,egid,uid,euid): Removed
	in_interrupt checks and other pointer checks.  We now operate on
	the assumption that "current" and its related data are always
	valid.
	* 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-12  Kevin Stafford  <krstaffo@us.ibm.com>

	* main.cxx (main): Added arch directory to the existing
	kernel-version-sensitive search path.

2005-12-12  Frank Ch. Eigler  <fche@redhat.com>

	* translate.cxx (translate_pass): Emit #include <linux/profile.h>.

2005-12-12  Will Cohen  <wcohen@redhat.com>

	* tapset/logging.stp (function_exit): Make sure systemtap probes
	stop collection additional data.

2005-12-12  Frank Ch. Eigler  <fche@redhat.com>

	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.

2005-12-11  Roland McGrath  <roland@redhat.com>

	* configure.ac: Bump version to 0.5.1 for test builds.
	* systemtap.spec.in: Remove ExclusiveArch.
	* configure: Regenerated.

	PR 1916
	* configure.ac: Grok --with-elfutils.
	* Makefile.am [BUILD_ELFUTILS] (install-elfutils, stamp-elfutils):
	New targets.
	[BUILD_ELFUTILS] (stap_LDFLAGS, stap_LDFLAGS): Add flags
	to point at local elfutils build.
	[BUILD_ELFUTILS] (BUILT_SOURCES): Add stamp-elfutils.
	[BUILD_ELFUTILS] (stap_DEPENDENCIES): New variable.
	[BUILD_ELFUTILS] (lib-elfutils/libdw.so): New target.
	[BUILD_ELFUTILS] (install-exec-local): Depend on install-elfutils.
	(loc2c_test_LDADD): Set this to $(stap_LDADD).
	(loc2c_test_CPPFLAGS, loc2c_test_LDFLAGS): New variables.
	* Makefile.in: Regenerated.
	* compile: New file from automakeland.
	* systemtap.spec.in (elfutils_version): Require 0.118 or later.
	[bundled_elfutils]: Remove old hacks for building elfutils, and rely
	on configure --with-elfutils instead.

	* Makefile.am (pkglibexecdir): New variable.
	(AM_CPPFLAGS): Use it.
	(pkglibexec_PROGRAMS): Set this instead of noinst_PROGRAMS with stpd.
	(pkglibexec_SCRIPTS, CLEANFILES): New variables.
	(install-exec-local): Target removed.
	* runtest.sh: Set LD_LIBRARY_PATH when lib-elfutils is in use.

	* loc2c-test.c (get_location): Fix function name in error message.

2005-12-09  Graydon Hoare  <graydon@redhat.com>

	* 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-08  Graydon Hoare  <graydon@redhat.com>

	* 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.

2005-12-08  Frank Ch. Eigler  <fche@elastic.org>

	PR 1937
	* buildrun.cxx (run_pass): Pass new "-d PID" option to stpd.
	Set SIGHUP to SIG_IGN too.

2005-12-07  Graydon Hoare  <graydon@redhat.com>

	* 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.

2005-12-07  Martin Hunt  <hunt@redhat.com>

	* translate.cxx (mapvar::fini): Use _stp_pmap_del() on pmaps.
	(emit_global): For pmaps, use "PMAP" instead of "MAP".

2005-12-06  Frank Ch. Eigler  <fche@elastic.org>

	PR 1934.
	* tapsets.cxx (resolve_prologue_endings2): Add new heuristic for
	tail-call optimized functions.
	(query_func_info): Make somewhat less verbose.

2005-12-06  Graydon Hoare  <graydon@redhat.com>

	* translate.cxx (visit_print_format): Explicitly Cast int64_t
	(pe_long) args to (long long) in generated code, for portability.

2005-12-05  Frank Ch. Eigler  <fche@elastic.org>

	* *.cxx: Add <cassert> #include as needed.

2005-12-02  Graydon Hoare  <graydon@redhat.com>

	* 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.

2005-12-02  Frank Ch. Eigler  <fche@elastic.org>

	* configure.ac: Bump version number.
	* stap.1.in: Document some of the new print/stats stuff.
	* configure: Regenerated.
	* systemtap.spec.in: Enable ia64 and ppc builds.

2005-12-01  Frank Ch. Eigler  <fche@elastic.org>

	PR 1944 improved hack.
	* translator.cxx (c_tmpcounter::visit_block): New routine, allows
	overlay of sequential statements' temporaries within context.

2005-12-01  Frank Ch. Eigler  <fche@redhat.com>

	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-11-30  Frank Ch. Eigler  <fche@redhat.com>

	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-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.

2005-11-28  Frank Ch. Eigler  <fche@redhat.com>

	* translate.cxx (c_tmpcounter_assignment::visit_symbol): Don't
	emit unused temporary into context.  Saves mucho space with strings.

2005-11-27  Roland McGrath  <roland@redhat.com>

	* loc2c.c (location_from_address): Diagnose null FB_ATTR specially.

	* loc2c.c (location_from_address): Fix function name in error message.

2005-11-27  Frank Ch. Eigler  <fche@elastic.org>

	* loc2c.c (location_from_address): Tolerate errors with NULL *input.

2005-11-26  Roland McGrath  <roland@redhat.com>

	PR 1868.
	* loc2c.c (struct location): Move frame_base member out of the union.
	(alloc_location): Initialize it.
	(new_synthetic_loc, translate, location_from_address): Update uses.
	(emit_loc_value): Don't handle frame_base here.
	(c_emit_location): Do it here instead.
	(translate): Track USED_DEREF separately for each piece.
	Use a temporary struct when allocating a new piece, letting
	a pending loc_address piece finish up first.

	* loc2c-test.c (main): Free SCOPES at end.
	(handle_variable): Free POOL at end.

	* loc2c.c (translate): Initialize LOC->address.used_deref at start.

2005-11-25  Frank Ch. Eigler  <fche@elastic.org>

	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>

	PR 1903
	* parse.cxx (eval_pp_conditional): Support %( arch == "i686" %) form.
	* stap.1.in: Document it.
	* testsuite/parseok/fourteen.stp: Test it.
	* session.h (architecture): New field.
	* main.cxx (main): Initialize it.

2005-11-24  Frank Ch. Eigler  <fche@redhat.com>

	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-23  Graydon Hoare  <graydon@redhat.com>

	* elaborate.h (get_symbol_within_expression): Make visible.
	* elaborate.cxx (get_symbol_within_expression): Make non-static.
	(stat_decl_collector): New struct.
	(semantic_pass_stats): New semantic pass.
	(semantic_pass): Call it.
	(semantic_pass_symbols): Remove collection of statistic_decls from files.
	(visit_stat_op): Only fail if inferred type is not pe_long.

	* parse.cxx (parser::parse): Don't pass per-file statistic_decl
	into parse_global.
	(parser::parse_global): Don't parse global statistic_decls,
	they're obsolete.
	* parse.hh (parser::parse_global): Adjust signature to match.

	* session.h (statistic_decl::operator==): New method.

	* staptree.h (print_format::is_empty): New method.
	(stapfile::stat_decls): Remove field.
	* staptree.cxx (string_to_components): Fix bugs in format-string
	parser.

	* translate.cxx (var): Make private fields protected.
	(var::init): Support HIST_NONE stats.
	(aggvar): New struct.
	(mapvar::is_parallel): New method.
	(mapvar::call_prefix): Use it.
	(mapvar::calculate_aggregate): New method.
	(mapvar::fetch_existing_aggregate): New method.
	(mapvar::get): Support pe_stats.
	(mapvar::init): Use is_parallel(), and support HIST_NONE.
	(itervar::itervar): Only fault on pe_unknown.
	(itervar::start): Use mapvar::is_parallel and
	mapvar::fetch_existing_aggregate.
	(emit_map_type_instantiations): Include alloc.c before pmap-gen.c.
	Include pmap-gen.c for pe_stats maps.
	(c_unparser::gensym_aggregate): New method.
	(c_unparser::visit_foreach_loop): Handle mapvar::is_parallel case.
	(arrayindex_downcaster): New struct.
	(expression_is_arrayindex): New function.
	(c_tmpcounter::visit_stat_op): New method.
	(c_unparser::visit_stat_op): Implement.
	(c_unparser::visit_hist_op): Add commentary, still not implemented.

	* testsuite/buildok/stat_{insert,extract}.stp: New tests.
	* testsuite/semok/ten.stp: Correct for changes to global declarations.
	* testsuite/semko/*.stp: Likewise.

2005-11-21  Roland McGrath  <roland@redhat.com>

	* loc2c.c (c_translate_location): Take Dwarf_Op vector as argument
	directly, not Dwarf_Attribute.
	* 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>

	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>

	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-13  Graydon Hoare  <graydon@redhat.com>

	* staptree.h (struct indexable): New struct.
	(classify_indexable): New function.
	(classify_const_indexable): New function.
	(struct symbol): Implement indexable.
	(struct arrayindex): Take indexable as base.
	(struct foreach_loop): Take indexable as base.
	(struct print_format): New struct.
	(enum stat_component_type): New enum.
	(struct stat_op): New struct.
	(enum historgram_type): New enum.
	(struct hist_op): New struct.
	(struct visitor)
	(struct traversing_visitor)
	(struct throwing_visitor)
	(struct deep_copy_visitor): Add new visitor methods.
	(require): Specialize for indexable*.

	* staptree.cxx (print_format::*)
	(stat_op::*)
	(hist_op::*)
	(indexable::*)
	(traversing_visitor::*)
	(throwing_visitor::*)
	(deep_copy_visitor::*)
	(classify_indexable)
	(classify_const_indexable): Implement
	(deep_copy_visitor::*): Update to use indexables.

	* parse.h (parser::parse_indexable): New method.
	(parser::parse_hist_op_or_bare_name): New method.

	* parse.cxx (lexer::scan): Accept @ in identifiers.
	(parser::parse_array_in)
	(parser::parse_foreach_loop): Call parse_indexable.
	(parser::parse_hist_op_or_bare_name): Implement.
	(parser::parse_indexable): Implement.
	(parser::parse_symbol): Accept printf, stat_ops, hist_ops.

	* elaborate.h (struct typeresolution_info): Add methods for
	visiting print_format, stat_op, hist_op.

	* elaborate.cxx (symbol_fetcher): New class.
	(get_symbol_within_expression): New function.
	(get_symbol_within_indexable): New function.
	(mutated_var_collector): Replace mutated_map_collector.
	(no_var_mutation_during_iteration_check): Replace
	no_map_mutation_during_iteration_check.
	(semantic_pass_vars): Replace semantic_pass_maps.
	(semantic_pass): Update call accordingly.
	(symresolution_info::*) Add new visitors, teach about indexables
	(typeresolution_info::*) Likewise.

	* translate.cxx
	(c_unparser::getiter): Take symbol, not foreach_loop.
	(c_unparser::*) Add new visitors, teach about indexables.
	(c_tmpcounter::*)
	(delete_statement_operand_visitor::visit_arrayindex)
	(c_tmpcounter_assignment::*)
	(c_unparser_assignment::*): Likewise.
	(hist_op_downcaster): New struct.
	(expression_is_hist_op): New function.

	* testsuite/buildok/printf.stp: New test for print_format.

2005-11-10  Frank Ch. Eigler  <fche@elastic.org>

	* translate.cxx (c_unparser::visit_array_in, visit_arrayindex):
	Finish adapting to PR 1275 by switching back to read locks.

2005-11-09  Martin Hunt  <hunt@redhat.com>

	* translate.cxx: New API uses HIST_LOG and HIST_LINEAR
	instead of HSTAT_LOG and HSTAT_LINEAR.

2005-11-09  Frank Ch. Eigler  <fche@elastic.org>

	Reported by Guang Lei Li <liguangl@cn.ibm.com>:
	* tapset/context.stp (pid,ppid,tid): Correctly pick tgid vs pid.
	* testsuite/buildok/context_test.stp: Print out tid() too.

2005-11-08  Frank Ch. Eigler  <fche@redhat.com>

	* 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>

	* translate.cxx (c_unparser::visit_foreach_loop): With PR 1275
	done, add back read lock around foreach loop.  Add a write lock
	around preceding sort operation.  Leave a race condition window. :-(

2005-11-08  Frank Ch. Eigler  <fche@redhat.com>

	* translate.cxx (mapvar::exists): Correct some more.

2005-11-08  Frank Ch. Eigler  <fche@redhat.com>

	Patch from "Mao, Bibo" <bibo.mao@intel.com>
	* translate.cxx (mapvar::exists): Correct 64-bit type mismatch.

2005-11-08  Frank Ch. Eigler  <fche@redhat.com>

	* 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>

	PR 1828.
	* tapsets.cxx (blacklisted_p): New function.  Add a few blacklist
	entries.
	* testsuite/semko/thirtythree.stp: New test.

2005-11-07  Frank Ch. Eigler  <fche@redhat.com>

	* testsuite/buildok/twentytwo.stp: Add another test for PR 1271.

2005-11-04  Frank Ch. Eigler  <fche@redhat.com>

	* 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>

	* 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>

	* tapsets.cxx (add_probe_point): Use explicit test with assignment in
	while condition.

2005-11-03  Frank Ch. Eigler  <fche@elastic.org>

	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-11-02  Martin Hunt  <hunt@redhat.com>

	* Makefile.am (EXTRA_DIST): Add session.h.
	* Makefile.in: Regenerated.

2005-11-01  Frank Ch. Eigler  <fche@elastic.org>

	Sound advice from <drepper@redhat.com>:
	* configure.ac: Undo last change.
	* configure.ac: Unregenerated.
	* parse.cxx: Use glibc strverscmp function instead of rpmlib.
	* stap.1.in: Update correspondingly.

2005-11-01  Graydon Hoare  <graydon@redhat.com>

	* translate.cxx (c_unparser::collect_map_index_types)
	(c_unparser::emit_map_type_instantiations)
	(c_unparser::visit_arrayindex)
	(c_unparser::visit_array_in)
	(delete_statement_operand_visitor::visit_arrayindex)
	(c_unparser_assignment::visit_arrayindex)
	(mapvar::*): Update to new runtime map API.

2005-11-01  Frank Ch. Eigler  <fche@elastic.org>

	PR 1425.
	* configure.ac: Look for rpm-devel headers and libs.
	* configure: Regenerated.
	* session.h: New file to contain systemtap_session decl.
	* staptree.h: Likewise evict statistics_decl.
	* elaborate.h: Corresponding changes.
	* main.cxx (usage): Elaborate.  Re-enable "-r RELEASE" option.
	* parse.cxx (parser): Add systemtap_session& field.  Update users.
	(scan_pp, eval_pp_conditional): New routines for preprocessing.
	(peek, next): Call it.
	(lexer::scan): Lex the preprocessor operators.
	(parser::parse): Include an extra level of exception catching
	for parse errors that occur during recovery.
	* parse.h: Corresponding changes.
	(parse_error): Allow explicit token parameter.
	* stap.1.in: Document preprocessing.
	* testsuite/parseok/fourteen.stp: New test.

2005-10-31  Roland McGrath  <roland@redhat.com>

	* systemtap.spec.in, configure.ac: Version 0.4.2 cooked.
	* configure: Regenerated.

	* 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.

2005-10-26  Roland McGrath  <roland@redhat.com>

	* loc2c.c (max_fetch_size): Default to host pointer size,
	while still waiting for new libdw entrypoint.

2005-10-25  Roland McGrath  <roland@redhat.com>

	PR 1271 cont'd.
	* testsuite/buildok/twentytwo.stp: New file.
	* testsuite/buildok/twentythree.stp: New file.
	* loc2c.c (discontiguify): Add missing ; in output.

2005-10-20  Graydon Hoare  <graydon@redhat.com>

	PR 917 (incomplete)
	* staptree.h (struct statistic_decl): New struct.
	(stapfile::stat_decls): New member.

	* parse.h, parse.cxx
	(parser::expect_known): Fix typo.
	(parser::expect_number): New method.
	(parser::parse_global): Parse global statistic_decls.

	* elaborate.h (systemtap_session::stat_decls): New member.
	* elaborate.cxx (semantic_pass_symbols): Copy per-file stat_decls
	to session-wide.
	(typeresolution_info::visit_assignment): Detect some semantic stats
	errors in type resolution pass.

	* translate.cxx (var::sd): New private member.
	(var::var): Initialize it.
	(var::sdecl): New accessor.
	(var::init): Handle stats values.
	(mapvar::mapvar): Pass through statistic_decl to var ctor.
	(mapvar::get): Test for long explicitly.
	(mapvar::set): Likewise.
	(mapvar::init): Handle stats values.
	(c_unparser::emit_common_header): Remove typedef of stats_t,
	include stat.c when necessary.
	(mapvar::key_typename): Typo.
	(c_unparser::emit_map_type_instantiations): Thinko: value_typename not key_typename.
	(c_unparser::c_typename): Implementation typename is "Stat", not "stats_t".
	(c_unparser::c_assign): Fix bad error message.
	(c_unparser_assignment::c_assignop): Handle operator <<<.
	(c_unparser::getvar): Feed session statistic_decl into var.
	(c_unparser::getmap): Likewise.
	(c_unparser::visit_assignment): Handle operator <<<.
	(c_tmpcounter_assignment::visit_symbol): Derive type from rvalue when present.
	(c_unparser_assignment::visit_symbol)
	(c_tmpcounter_assignment::visit_arrayindex)
	(c_unparser_assignment::load_map_indices): Likewise.
	(c_unparser::visit_arrayindex): Likewise, and Prohibit statistic rvalues.
	(c_unparser_assignment::visit_arrayindex): Handle operator <<<.

	* testsuite/semko/twentyfour.stp:
	* testsuite/semko/twentyfive.stp:
	* testsuite/semko/twentysix.stp:
	* testsuite/semko/twentyseven.stp:
	* testsuite/semko/twentyeight.stp:
	* testsuite/semko/twentynine.stp:
	* testsuite/semko/thirty.stp:
	* testsuite/semko/thirtyone.stp: New tests for prohibited statistic contexts.
	* testsuite/buildok/twentytwo.stp: New test for legal statistic contexts.

2005-10-19  Tom Zanussi  <zanussi@us.ibm.com>

	PR 1194.
	* elaborate.h: Move output_file variable into systemtap_session.
	* buildrun.cxx (run_pass): Pass output file to stpd if applicable.
	* main.cxx (main): Set output_file if -o option specified.

2005-10-18  Frank Ch. Eigler  <fche@redhat.com>

	PR 1477.
	* main.cxx (main): Set PATH and LC_ALL, so
	* buildrun.cxx (compile_pass, run_pass): ... and ...
	* translate.cxx (emit_symbol_data): ... don't have to.

2005-10-18  Frank Ch. Eigler  <fche@elastic.org>

	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>

	PR 1482
	* tapsets.cxx (emit_registrations): On failure, don't
	forget to unregister probe 0;

2005-10-17  Frank Ch. Eigler  <fche@elastic.org>

	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>

	* 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-14  Roland McGrath  <roland@redhat.com>

	PR 1271.
	* loc2c.c (translate): Set LOC->byte_size in loc_noncontiguous result.
	(struct location.address): New member `declare'.
	(new_synthetic_loc, translate): Initialize it.
	(struct location.type): Add loc_fragment, loc_decl to enum.
	(c_emit_location): Emit unadorned code for loc_fragment.
	(discontiguify): New function.
	(c_translate_fetch, c_translate_store): Call it.
	(get_bitfield): New function, broken out of ....
	(emit_bitfield): ... here.  Function removed.
	(declare_noncontig_union): New function.
	(max_fetch_size): New function.
	(translate_base_fetch): New function, broken out of ...
	(c_translate_fetch): ... here.  Call it.
	Use get_bitfield here, not emit_bitfield.
	(c_translate_store): Likewise.
	(c_emit_location): Emit declarations first.

	* loc2c.c (dwarf_diename_integrate): Function removed.
	Change all callers to use dwarf_diename.

	* loc2c-test.c (handle_variable): Check for "=" before fetching DIE
	from ATTR_MEM.

2005-10-13  Roland McGrath  <roland@redhat.com>

	* loc2c.c (c_emit_location): Use final location's used_deref flag too.

	* loc2c.c (translate): Pass LOC to alloc_location, not INPUT.

	* loc2c-test.c (fail): Print a newline after the error message.

2005-10-10  Frank Ch. Eigler  <fche@elastic.org>

	* 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-10  Frank Ch. Eigler  <fche@elastic.org>

	PR 1456.
	* translate.cxx (c_unparser_assignment): Rename "pre" field to "post",
	add blurb to clarify polarity.
	(visit_pre/post_crement): Flip passed flag value.

2005-10-07  Frank Ch. Eigler  <fche@elastic.org>

	PR 1366.
	* staptree.h (foreach_loop): Add sort_column, sort_direction fields.
	* parse.cxx (parse_foreach_loop): Parse "+"/"-" suffix operators.
	* stap.1.in, stapex.5.in: Document them.
	* staptree.cxx (foreach_loop print, copy): Propagate them.
	* translate.cxx (visit_foreach_loop): Support them.
	* testsuite/parseok/fifteen.stp, parseko/thirteen.stp,
	buildok/twentyone.stp: Test them.

2005-10-07  Kevin Stafford  <kevinrs@us.ibm.com>

        * tapset/system_calls.stp: All 281 syscalls *prototyped*. They
	are still untested. Many of the aliases useability are contin-
 	gent upon resolution of namely: bz #1295 & bz #1382.

2005-10-06  Frank Ch. Eigler  <fche@elastic.org>

	* stap.1.in: Document -b/-s options.
	* main.cxx (usage): Clarify -b/-s blurbs.
	* translator.cxx (translate_pass): Handle bulk_mode here instead.

2005-10-06  Frank Ch. Eigler  <fche@elastic.org>

	PR 1332.
	* translate.cxx (emit_symbol_data): New function to transcribe
	a processed address->symbol lookup table, based upon /proc/kallsyms.

2005-10-05  Tom Zanussi  <zanussi@us.ibm.com>

	* buildrun.cxx (run_pass): Add bulk/buffer_size flags to flags
	passed to stpd.
	* elaborate.h (systemtap_session): Add bulk/buffer_size flags.
	* main.cxx (usage,main): Add -b (bulk), -s (buffer_size) options.
	processing.

2005-10-04  Graydon Hoare  <graydon@redhat.com>

	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>

	* 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.

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.

2005-09-30  Frank Ch. Eigler  <fche@elastic.org>

	* tapset/system_calls.stp (*_str): Simplified boolean test logic
	throughout, fixed some typos.

2005-09-28  Frank Ch. Eigler  <fche@elastic.org>

	PR 1182.
	* main.cxx (main): Support -D macro-setting option.
	* stap.1.in: Document it and related macros.
	* buildrun.cxx (compile_pass): Emit macro definitions.
	* translate.cxx (translate_pass): Guard limit macros with #ifdef.
	Eliminate MAXCONCURRENCY macro.
	* elaborate.h (systemtap_session): Add "macros" field.
	* parse.cxx (parse_if_statement): Clear "elseblock" if needed.

2005-09-27  Frank Ch. Eigler  <fche@elastic.org>

	* 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>

	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>

	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.

2005-09-26  Frank Ch. Eigler  <fche@elastic.org>

	* stapfuncs.5.in: Extend errno_str verbiage.
	* tapset/errno.stp: Canonicalize script code slightly.

2005-09-26  Frank Ch. Eigler  <fche@elastic.org>

	PR 1295.
	* tapsets.cxx (resolve_prologue_endings2): Try another heuristic
	for end-of-prologue.

2005-09-22  Graydon Hoare  <graydon@redhat.com>,
	Frank Ch. Eigler  <fche@elastic.org>

	PR 1330.
	* tapsets.cxx (dwarf_derived_probe): Allow multiple probe_point
	locations per derived_probe.
	(dwarf_query): Add probe "flavour" concept, to reuse probe bodies for
	identical flavours across wildcards.
	(dwarf::emit_registrations, emit_deregistrations, emit_probe_entries):
	Reorganize.
	* staptree (probe::printsig): Put multiple locations on separate lines.

2005-09-22  Will Cohen  <wcohen@redhat.com>

	* stap.1.in: Correct sys_read alias example.

2005-09-19  Frank Ch. Eigler  <fche@redhat.com>

	* tapsets.cxx (*::emit_probe_entries): Handle busy-count correctly
	upon contention.

2005-09-14  Graydon Hoare  <graydon@redhat.com>

	PR 1260
	* tapsets.cxx (dwflpp::resolve_prologue_endings): Correct logic
	error triggered by consecutive function-beginning line records.

2005-09-14  Frank Ch. Eigler  <fche@elastic.org>

	PR 1344
	* translate.cxx: Call _stp_map_clear for "delete ARRAY" statement.

2005-09-14  Roland McGrath  <roland@redhat.com>

	* systemtap.spec.in: Version 0.4.1 cooked.
	Build runpath into elfutils libs too.

2005-09-14  Frank Ch. Eigler  <fche@elastic.org>

	PR 1257
	* Makefile.am (AM_CFLAGS): Add -fexceptions.
	* loc2c.c (c_translate_location): Invoke *fail properly.
	* Makefile.in: Regenerated.

2005-09-13  Graydon Hoare  <graydon@redhat.com>

	PR 1260
	* tapsets.cxx (func_info::func_info): Initialize fields.
	(inline_instance_info::inline_instance_info): Likewise.
	(query_inline_instance_info): Add try-catch block.
	(query_func_info): Likewise, and fault when missing prologue-end.
	(query_dwarf_func): Fault when missing entrypc.

2005-09-12  Frank Ch. Eigler  <fche@elastic.org>

	PR 1335
	* translate.cxx (c_tmpcounter::visit_functioncall): Correct
	recursion sequence.
	* testsuite/buildok/nineteen.stp: New test case.

2005-09-12  Graydon Hoare  <graydon@redhat.com>

	PR 1306
	* tapsets.cxx (dwflpp::iterate_over_srcfile_lines): Fix two
	off-by-one errors in previous change.

2005-09-12  Graydon Hoare  <graydon@redhat.com>

	PR 1306
	* tapsets.cxx (dwflpp::has_single_line_record): New function.
	(dwflpp::iterate_over_srcfile_lines): Throw when user requests
	single statement line with multiple records (and provide advice).
	(query_cu): Adjust call to match.
	(query_srcfile_line): Fix indentation.

2005-09-10  Frank Ch. Eigler  <fche@elastic.org>

	* Makefile.am, runtest.sh: Use a "testresuilt/" directory in build
	tree rather than overloading "testsuite/".
	* TODO: Removed obsoleted file.
	* Makefile.in: Regenerated.

2005-09-07  Martin Hunt  <hunt@redhat.com>

	* stap.1.in: Document current "-c" and "-x" options.

2005-09-07  Frank Ch. Eigler  <fche@elastic.org>

	* systemtap.spec.in: Remove kernel-debuginfo dependency.

2005-09-07  Frank Ch. Eigler  <fche@redhat.com>

	* main.cxx (main): Choose getpid()-based module names.
	* tapsets.cxx: Make timer.jiffies' use of task_pt_regs __i386__-only.

2005-09-07  Frank Ch. Eigler  <fche@redhat.com>

	* stap.1.in: Oops, && and || do short-circuit.

2005-09-06  Frank Ch. Eigler  <fche@elastic.org>

	* stap.1.in: Clarify absence of short-circuiting in && and ||.
	* translate.cxx (emit_function): Improve "array locals" message.
	* tapset/timestamp.stp: Add gettimeofday_us function.  Correct
	arithmetic typing in other functions.
	* stapfuncs.5.in: Document new function.

2005-09-06  Martin Hunt  <hunt@redhat.com>

	* systemtap.spec.in: Bump elfutils_version to .115.

2005-09-05  Roland McGrath  <roland@redhat.com>

	* loc2c.h: Comment fix.

2005-09-06  Frank Ch. Eigler  <fche@elastic.org>

	* configure.ac: Require elfutils 0.115+.
	* tapsets.cxx: Restore graydon's PR 1244 code.
	* testsuite/buildok/eighteen.stp: Correct typing.
	* configure: Regenerated.

2005-09-06  Martin Hunt  <hunt@redhat.com>

	* tapset/context.stp: Add function target().
	* stapfuncs.5.in (target): Document it.
	* elaborate.h (struct systemtap_session): Add cmd and target_pid to
	the struct.
	* main.cxx (usage): Add descriptions of "-c" and "-x" options.
	(main): Set s.cmd and s.target_pid.
	* buildrun.cxx (stringify): Copy this utility func here too.
	(run_pass): Add new options to set cmd and pid to the stpd
	command line.

2005-09-06  Frank Ch. Eigler  <fche@redhat.com>

	* tapsets.cxx (emit_probe_entries): Disable fault_handler for now.

2005-09-05  Frank Ch. Eigler  <fche@elastic.org>

	PR 1289
	* translate.cxx (lex_cast_qstring): Correct "cast" of object
	to string containing more than one word.
	* tapset.cxx (lex_cast_qstring): Ditto.
	(dwarf_derived_module::emit_probe_entries): Emit and use
	a generic fault_handler.

2005-09-05  Frank Ch. Eigler  <fche@elastic.org>

	PR 1172.
	* staptree.h, staptree.cxx: Make all ::print*(), operator<<
	functions take const staptree objects.
	(literal_string::print): \-prefix double-quotes.
	* translate.cxx (emit_common_header): Add context probe_point field.
	Switch to atomic_t busy flags.
	(emit_module_exit): Use atomic operations for busy flag.
	(visit_*): Use lex_cast_qstring for last_stmt strings.
	* tapsets.cxx (lex_cast_qstring): New function.
	(*::emit_probe_entries): Populate probe_point.  Use atomic operations
	for busy flag.
	* tapset/context.stp (pp): New function.
	* stapfuncs.5.in: Document it.
	* testsuite/buildok/context_test.stp: Test it.

2005-09-04  Frank Ch. Eigler  <fche@elastic.org>

	* translate.cxx (visit_literal_string): \-prefix double-quotes.

2005-09-04  Martin Hunt  <hunt@redhat.com>

	* testsuite/buildok/context_test.stp: New test.
	* tapset/logging.stp (log): Call _stp_printf().
	* stapfuncs.5.in: Add contextinfo funcs.
	* tapset/context.stp: Minor cleanup.

2005-09-03  Frank Ch. Eigler  <fche@elastic.org>

	PR 1187 prime
	* tapset.cxx (literal_stmt_for_local): Don't automgaically copy
	target char*'s to systemtap strings.
	* tapset/conversions.stp (user_string, kernel_string): New functions.
	* stapfuncs.5.in: Document new functions.

2005-09-03  Frank Ch. Eigler  <fche@elastic.org>

	PR 1292, by popular request.
	* parse.cxx (parse_functiondecl): Allow optional value/param type
	declarations.
	* stap.1.in: Document this.
	* tapset/*.stp: Convert most functions accordingly.
	* testsuite/parseok/twelve.stp, semok/seven.stp,
	semko/twenty.stp: Test this.

2005-09-02  Frank Ch. Eigler  <fche@redhat.com>

	* translate.cxx (varlock): Use trylock only for write locks.
	(translate_pass): Remove read_trylock macro hack.
	(visit_foreach_loop): Remove protective read lock, until PR 1275.
	(visit_*): Added many more "last_stmt"-setting expressions in the
	output, to improve last_error message locality.

2005-09-02  Martin Hunt  <hunt@redhat.com>

	* tapset/logging.stp: Make log() be same as print().

2005-09-02  Frank Ch. Eigler  <fche@elastic.org>

	* tapsets.cxx: Temporarily rolled back graydon's changes.

2005-09-02  Frank Ch. Eigler  <fche@elastic.org>

	* tapset/*.stp: Renamed several files to simplify names.

2005-09-01  Graydon Hoare  <graydon@redhat.com>

	PR systemtap/1244
	* testsuite/buildok/eighteen.stp: New test.
	* tapsets.cxx (dwflpp::literal_stmt_for_local)
	(query_statement, query_inline_instance_info)
	(query_func_info, query_srcfile_line, query_cu)
	(var_expanding_copy_visitor, visit_target_symbol)
	(dwarf_derived_probe): Fix 1244.

2005-09-01  Martin Hunt  <hunt@redhat.com>

	* tapset/builtin_logging.stp: Add print.

	* tapset/context.stp: New file. First cut at some
	context info.

2005-09-01  Martin Hunt  <hunt@redhat.com>

	* translate.cxx (emit_probe): Add a call to _stp_print_flush
	at the end of each probe.
	(translate_pass): Define STP_NUM_STRINGS to be 1 for
	a scratch string. Include current.c and stack.c. Don't
	define KALLSYMS_LOOKUP_NAME or KALLSYMS_LOOKUP. Remove
	references to next_fmt() and stp_dbug().

2005-08-31  Graydon Hoare  <graydon@redhat.com>

	PR systemtap/1258
	* tapsets.cxx (dwflpp::literal_stmt_for_local):
	Support DW_TAG_enumeration_type tag as synonymous with
	DW_TAG_base_type.
	* loc2c.c (base_byte_size): Likewise.
	* testsuite/buildok/seven.stp: Adjust to work on UP kernels.

2005-08-31  Graydon Hoare  <graydon@redhat.com>

	* tapsets.cxx (dwflpp::iterate_over_srcfile_lines): Correct segv
	reported in PR 1270.

2005-08-31  Frank Ch. Eigler  <fche@redhat.com>

	* translate.cxx (visit_array_in, visit_arrayindex): Use write locks
	even for array reads, until PR 1275.
	(translate_pass): Add read_trylock -> write_trylock escalation.

2005-08-30  Roland McGrath  <roland@redhat.com>

	* Makefile.am (install-data-local): Use mkdir -p, not -mkdir.
	* Makefile.in: Regenerated.

2005-08-30  Graydon Hoare  <graydon@redhat.com>

	* tapsets.cxx (dwflpp::literal_stmt_for_local): Handle dwarf
	pointer-to-1-byte-means-char case (found in PR 1187)
	* parse.cxx (parse_symbol): Eliminate use of "." from target
	symbol parser, conflicting with string concatenation operator.
	* staptree.h (target_symbol::component_type) Eliminate
	comp_struct_pointer_member, since . and -> are considered the
	same now.
	* staptree.cxx (target_symbol::print): Likewise.
	* testsuite/buildok/seventeen.stp: Test solution on PR 1191.
	* testsuite/buildok/six.stp: Test working portion of PR 1155.
	* testsuite/semko/nineteen.stp: Unresolved portion of PR 1155.

2005-08-30  Frank Ch. Eigler  <fche@elastic.org>

	PR systemtap/1268
	* translator (varlock): Add deadlock detection code.
	(emit_common_header): Add a new MAXTRYLOCK configuration macro.

2005-08-29  Graydon Hoare  <graydon@redhat.com>

	PR translator/1265
	* tapsets.cxx
	(func_info::decl_file)
	(func_info::decl_line)
	(inline_instance_info::decl_file)
	(inline_instance_info::decl_line): New fields.
	(dwflpp::function_srcfile): Remove.
	(dwflpp::function_file): Add.
	(dwflpp::function_line): Add.
	(dwarf_derived_probe::dwarf_derived_probe): Update.
	(query_statement): Pass func, file, line through.
	(query_inline_instance_info): Likewise.
	(query_func_info): Likewise.
	(query_srcfile_line): Query statement lines if
	statement_str exists, rather than *_info.
	(query_dwarf_inline_instance): Extract file and line.
	(query_dwarf_func): Likewise.
	(query_cu): Pass empty func, file, line, for address-based
	queries.

2005-08-29  Frank Ch. Eigler  <fche@redhat.com>

	* runtest.sh: Tolerate relative $SRCDIR.

2005-08-29  Frank Ch. Eigler  <fche@redhat.com>

	* stapprobes.5.in, stapfuncs.5.in, stapex.5.in: New man pages.
	* stap.1.in: Moved some content out.
	* Makefile.am (man_MANS): Add new man pages.
	* configure.ac (AC_CONFIG_FILES): Add them.
	* systemtap.spec.in: Package them.
	* Makefile.in, configure: Regenerated.
	* buildrun.cxx (run_pass): Pass "-r" to stpd.
	* translate.cxx (emit_common_header): Wrap try/catch around
	variable decls, to improve exception particularity.
	(visit_literal_number): Emit as unsigned literal, which is
	actually a subtle correctness issue.

2005-08-28  Frank Ch. Eigler  <fche@redhat.com>

	* tapsets.cxx (visit_target): Make target variable exceptions
	more informative.
	(literal_stmt_for_local): Improve bad-type exception message.
	* translate.cxx (emit_module_init): Include probe point in comments.

2005-08-27  Roland McGrath  <roland@redhat.com>

	* loc2c-test.c (print_type): New function.
	(print_vars): Use it.

	* loc2c-test.c (paddr, print_vars): New functions.
	(main): If given no variable name argument, print out variables.

2005-08-26  Graydon Hoare  <graydon@redhat.com>

	* translate.cxx: Revert tmp initialization changes.

2005-08-26  Graydon Hoare  <graydon@redhat.com>

	* parse.cxx (scan): Preserve basic C-ish escapes.
	* translate.cxx (c_tmpcounter::declaring): New flag.
	(c_tmpcounter::declare_or_init): New helper method.
	(c_tmpcounter::visit_*): Use declare_or_init.
	(c_unparser::emit_function): Run a tmpcounter to initialize tmps.
	(c_unparser::emit_probe): Likewise.
	(c_unparser::c_strcpy): Use strlcpy.
	(c_unparser::c_strcat): Use strlcat.

2005-08-25  Roland McGrath  <roland@redhat.com>

	* Makefile.am (EXTRA_DIST): List .h files explicitly.
	Automake really does not like wildcards.
	* Makefile.in: Regenerated.

2005-08-25  Frank Ch. Eigler  <fche@redhat.com>

	* Makefile.am (docs): Removed target.
	* Makefile.in: Regenerated.

2005-08-24  Graydon Hoare  <graydon@redhat.com>

	* tapsets.cxx (dwflpp::literal_stmt_for_local): Fetch pointer types,
	array types, strings, from target.

2005-08-24  Roland McGrath  <roland@redhat.com>

	* loc2c-test.c (handle_variable): Iterate on const_type/volatile_type.

2005-08-24  Frank Ch. Eigler  <fche@elastic.org>

	* configure.ac: Require elfutils 0.114.
	* tapsets.cxx: Brought back graydon's changes.
	* configure: Regenerated.

2005-08-24  Roland McGrath  <roland@redhat.com>

	* systemtap.spec.in: Update elfutils requirement.

2005-08-24  Frank Ch. Eigler  <fche@elastic.org>

	* translate.cxx (emit_global, emit_module_init): Use 2.6.9-compatible
	rwlock initialization.

2005-08-24  Frank Ch. Eigler  <fche@elastic.org>

	* tapsets.cxx (*::emit_probe_entries): Treat NULL and "" last_errors
	both as clean early returns, not errors.
	* translate.cxx: Revamp last_error handling logic.  Remove all
	"goto out" paths from expression context.
	(visit_statement): Handle last_error exit one nesting level at a time.
	(visit_return_statement, visit_functioncall): Set/reset last_error="".
	(c_tmpcounter::visit_for_loop): New routine.
	(c_unparser::visit_foreach, visit_for_loop): Rewrite to properly
	support continue/breaks, non-local exits, (foreach) locks.
	(emit_global): Emit lock variable.
	(varlock ctor, dtor): Lock/unlock global variable.
	(varlock_w, varlock_r): New concrete subclasses.  Update all users.
	* tapset/builtin_logging.stp (exit): Don't set last_error.
	* src/testsuite/buildok/sixteen.stp: New test.

	* tapsets.cxx: Temporarily rolled back graydon's changes.

2005-08-23  Graydon Hoare  <graydon@redhat.com>

	* tapsets.cxx: Re-implement dwarf probe-pattern resolution.

2005-08-22  Frank Ch. Eigler  <fche@elastic.org>

	PR systemtap/1134
	* elaborate.h (module_fds): New member in systemtap_session.
	* tapsets.cxx (dwarf_derived_probe ctor): Open /sys/module/$MOD/.text
	for the duration of a systemtap session, to lock module in memory.

2005-08-21  Frank Ch. Eigler  <fche@redhat.com>

	PR systemtap/1195, systemtap/1193
	* elaborate.cxx (alias_expansion_builder): Set new block token.
	* parse.cxx (parse_symbol): Set new target_symbol token.
	* runtest.sh: Store more pertinent failure data.
	* tapsets.cxx (emit_probe_entries): Rewrite error-handling path.
	* translate.cxx (emit_common_header): Goodbye errorcount, hello
	last_error & last_stmt.
	(c_unparser::visit_statement): New "header" for all other stmts.
	(c_assignop, visit_binary_expression): Adapt to last_error.
	* tapset/builtin_logging.stp: Adapt to last_error.

2005-08-19  Frank Ch. Eigler  <fche@elastic.org>

	PR systemtap/1213
	* translate.cxx (visit_if_statement): Translate else arms.

2005-08-19  Frank Ch. Eigler  <fche@elastic.org>

	PR systemtap/1209
	* elaborate.cxx (derived_probe_builder): Add get_param function.
	* elaborate.h: Declare them.
	* tapsets.cxx (dwarf_query::get_*_param): Call them.
	(timer_derived_probe, timer_builder): New classes.
	(register_standard_tapsets): Register timer.jiffies(N) and friend.
	* translate.cxx (translate_pass): #include <linux/timers.h>.
	* stap.1.in: Document timer.jiffies(N) probe points.
	* testsuite/buildok/fourteen.stp: New test.

2005-08-19  Frank Ch. Eigler  <fche@elastic.org>

	* elaborate.cxx (find_var): Remove $pid/$tid builtin logic.

2005-08-19  Martin Hunt  <hunt@redhat.com>

	* stp_check.in: Remove stp-control.

2005-08-18  Roland McGrath  <roland@redhat.com>

	* loc2c.c (c_translate_addressof): Take TYPEDIE instead of TYPEATTR.
	* loc2c.h: Update decl.
	* loc2c-test.c (handle_variable): Handle DW_TAG_pointer_type target
	for fetch.

2005-08-18  Will Cohen  <wcohen@redhat.com>

	* stp_check.in: See if relayfs available filesystem.

2005-08-18  Roland McGrath  <roland@redhat.com>

	* loc2c.c (struct location): New member `emit_address'.
	(alloc_location): Initialize new member from ORIGIN.
	(location_from_address): New argument EMIT_ADDRESS.
	Initialize new member.
	(translate): Use LOC->emit_address hook to format DW_OP_addr constant.
	(location_relative): Die if DW_OP_addr is used.
	(default_emit_address): New function.
	(c_translate_location): New argument EMIT_ADDRESS, pass it down.
	Use default_emit_address if argument is null.
	* loc2c.h: Update decl.
	* loc2c-test.c (handle_variable): Update caller.
	* tapsets.cxx (dwflpp::literal_stmt_for_local): Update caller.
	(dwflpp::loc2c_emit_address): New static method.

2005-08-17  Roland McGrath  <roland@redhat.com>

	PR systemtap/1197
	* loc2c.c (struct location): New members `fail', `fail_arg'.
	(alloc_location): New function.  Initialize those members.
	(new_synthetic_loc, translate): Use that instead of obstack_alloc.
	(location_from_address, location_relative): Likewise.
	(FAIL): New macro.  Use it everywhere in place of `error'.
	(c_translate_location): Take new args FAIL, FAIL_ARG.
	* loc2c.h: Update declaration.
	* loc2c-test.c (fail): New function.
	(handle_variable): Pass it to c_translate_location.
	* tapsets.cxx (dwflpp::loc2c_error): New static method.
	(dwflpp::literal_stmt_for_local): Pass it to to c_translate_location.

	PR systemtap/1205, systemtap/1206
	* loc2c.c (c_translate_fetch): Take TYPEDIE instead of TYPEATTR.
	(c_translate_store): Likewise.
	* loc2c.h: Update decls.
	* loc2c-test.c (handle_variable): Update callers.
	Look up type, resolve typedefs, and check that it's DW_TAG_base_type.
	* tapsets.cxx (dwflpp::literal_stmt_for_local): Likewise.

	* loc2c.c (base_byte_size): Add assert on expected DIE tag.
	(c_translate_array, c_translate_pointer): Likewise.
	* loc2c.h: Amend comments to explicitly state type DIE tags expected.

	* loc2c.c: #include "loc2c.h".

2005-08-16  Frank Ch. Eigler  <fche@elastic.org>

	PR systemtap/1180
	* tapsets.cxx (*): Add more verbose-predicatation to informative
	messages.  Correct more hex/dec ostream mismatches.
	(query_function): Use entry/querypc, not prologue-end, for
	function().return and .statement() probe points.
	(dwarf_derived_probe ctor): Reorganize function/statement
	probe point regeneration.

2005-08-16  Frank Ch. Eigler  <fche@elastic.org>

	* main.cxx: Don't print library parse trees if last_pass=1.

2005-08-14  Roland McGrath  <roland@redhat.com>

	* systemtap.spec.in: Update elfutils_version requirement to 0.113;
	restore bundled_elfutils setting to 1.

2005-08-12  Graydon Hoare  <graydon@redhat.com>

	* translate.cxx (c_tmpcounter::visit_array_in): Implement.
	(c_unparser::visit_array_in): Likewise.
	(mapvar::exists): New method.

2005-08-12  Frank Ch. Eigler  <fche@elastic.org>

	PR systemtap/1122 et alii
	* parse.cxx (parse_literal): Parse and range-limit 64-bit numbers.
	(parse_unary): Correct precedence glitch.
	* staptree.h (literal_number): Store an int64_t.
	* staptree.cxx: Corresponding changes.
	* translate.cxx (check_dbz): Remove - insufficient.
	(emit_function): Define CONTEXT macro sibling for THIS.
	(c_typename): pe_long -> int64_t.
	(visit_literal_number): Format literal rigorously and uglily.
	(c_assignop, visit_binary_expression): Handle div/mod via new
	helper functions in runtime.
	* tapset/builtin_logging.stp: Add error, exit builtins.
	* testsuite/buildok/ten,eleven.stp: New tests.
	* testsuite/parse{ko,ok}/six.stp: Modify for larger numbers.
	* testsuite/transok/one.stp: Add more ";"s, maybe unnecessarily.

2005-08-11  Frank Ch. Eigler  <fche@elastic.org>

	* systemtap.spec.in: Tweak to turn into fedora-flavoured spec.
	Don't build/install runtime docs.

2005-08-11  Frank Ch. Eigler  <fche@elastic.org>

	* Makefile.am (uninstall-local): New target.
	* Makefile.in: Regenerate.

2005-08-11  Frank Ch. Eigler  <fche@elastic.org>

	* translate.cxx (emit_function): Add an extra { } around the
	function body visitation.
	* tapset/timestamp_functions.stp: New file.
	* tapset/builtin_conversions.stp: Aggregated from [hex]string.
	* tapset/builtin_logging.stp: Aggregated from log/warn/printk.

2005-08-11  Frank Ch. Eigler  <fche@elastic.org>

	* tapsets.cxx: Tweak hex/decimal printing for consistency.
	(emit_registrations): Remove module-specific code, anticipating
	that libelf gives us run-time addresses already.

2005-08-10  Roland McGrath  <roland@redhat.com>

	* loc2c.c (emit_base_store): New function.
	(emit_bitfield): Rewritten to handle stores, change parameters.
	(c_translate_fetch): Update caller.
	(c_translate_store): New function.
	* loc2c.h: Declare it.
	* loc2c-test.c (handle_variable): Grok "=" last argument to do a store.

	* loc2c.c (c_translate_location): Increment INDENT.
	(c_translate_pointer): Likewise.
	(emit_loc_value): Increment INDENT after emit_header.

2005-08-10  Graydon Hoare  <graydon@redhat.com>

	* tapsets.cxx (dwflpp::literal_stmt_for_local): Copy code from
	loc2c-test to implement target member variable access.

2005-08-10  Graydon Hoare  <graydon@redhat.com>

	* tapsets.cxx
	(dwflpp::global_addr_of_line_in_cu): Implement next-line heuristic.
	(dwarf_query::get_number_param): Dwarf_Addr variant.
	(query_cu): Add line-selecting variant for function iteration.

2005-08-10  Frank Ch. Eigler  <fche@elastic.org>

	PR translator/1186
	* elaborate.cxx (resolve_2types): Accept a flag to tolerate unresolved
	expression types.
	(visit_functioncall): Call it thusly.
	* translate.cxx (emit_function): Tolerate void functions.
	* stap.1.in: Document possibility of void functions.
	* tapset/builtin_{log,printk,warn}.stp: Make these void functions.
	* testsuite/buildok/nine.stp, semok/eighteen.stp: New tests.

2005-08-10  Frank Ch. Eigler  <fche@elastic.org>

	* tapsets.cxx: Correct hex/decimal misformatting of verbose messages.
	* main.cxx: Add formal "-h" and "-V" options.
	* stap.1.in: Document them.

2005-08-10  Frank Ch. Eigler  <fche@elastic.org>

	* tapsets.cxx: Move around "focusing on ..." messages to print
	them only for matching functions/modules.
	(dwflpp ctor): Also add cu (source file) name to derived
	probe point.

2005-08-09  Graydon Hoare  <graydon@redhat.com>

	* testsuite/parseok/nine.stp: Update
	* testsuite/semok/{six,seven,eleven,seventeen}.stp: Update.

2005-08-09  Graydon Hoare  <graydon@redhat.com>

	* staptree.{cxx,h}
	(target_symbol): New struct.
	(*_visitor::visit_target_symbol): Support it.
	(visitor::active_lvalues)
	(visitor::is_active_lvalue)
	(visitor::push_active_lvalue)
	(visitor::pop_active_lvalue): Support lvalue-detection.
	(delete_statement::visit)
	(pre_crement::visit)
	(post_crement::visit)
	(assignment::visit): Push and pop lvalue expressions.
	* elaborate.{cxx,h}
	(lvalule_aware_traversing_visitor): Remove class.
	(no_map_mutation_during_iteration_check)
	(mutated_map_collector): Update lvalue logic.
	(typeresolution_info::visit_target_symbol): Add, throw error.
	* parse.{cxx,h}
	(tt2str)
	(tok_is)
	(parser::expect_*)
	(parser::peek_*): New helpers.
	(parser::parse_symbol): Rewrite, support target_symbols.
	* translate.cxx (c_unparser::visit_target_symbol): Implement.
	* tapsets.cxx (var_expanding_copy_visitor): Update lvalue logic,
	change visit_symbol to visit_target_symbol.

2005-08-09  Martin Hunt  <hunt@redhat.com>

	PR 1174
	* stp_check.in: Supply path for lsmod.
	* stp_check: Removed.

2005-08-09  Graydon Hoare  <graydon@redhat.com>

	* elaborate.cxx:
	(delete_statement_symresolution_info): New struct.
	(symresolution_info::visit_delete_statement): Use it.
	(delete_statement_typeresolution_info): New struct.
	(typeresolution_info::visit_delete_statement): Use it.
	(symresolution_info::find_var): Accept -1 as 'unknown' arity.
	* elaborate.h: Update to reflect changes in .cxx.
	* translate.cxx (mapvar::del): New method.
	(c_unparser::getmap): Check arity >= 1;
	(delete_statement_operand_visitor): New struct.
	(c_unparser::visit_delete_statement): Use it.
	* staptree.cxx (vardecl::set_arity): Accept and ignore -1.
	(vardecl::compatible_arity): Likewise.
	* testsuite/buildok/eight.stp: New test for 'delete' operator.

2005-08-08  Roland McGrath  <roland@redhat.com>

	* loc2c-test.c: New file.
	* Makefile.am (noinst_PROGRAMS): Add loc2c-test.
	(loc2c_test_SOURCES, loc2c_test_LDADD): New variables.
	* Makefile.in, aclocal.m4: Regenerated.

2005-08-08  Frank Ch. Eigler  <fche@elastic.org>

	* stap.1.in: Autoconfify old man page.
	* configure.ac: Make it so.
	* stap.1: Removed.
	* configure, Makefile.in, aclocal.m4: Regenerated.

2005-08-05  Frank Ch. Eigler  <fche@elastic.org>

	* runtest.sh: Keep around log files from crashed processes,
	those whose rc is neither 0 nor 1.

2005-08-05  Frank Ch. Eigler  <fche@elastic.org>

	* tapsets.cxx (query_statement|function|cu|module): Add explicit
	nested try/catch, since elfutils iteration seems to block
	exception catching.

2005-08-05  Frank Ch. Eigler  <fche@elastic.org>

	PR translator/1175
	* translate.cxx (*): Added unlikely() markers to most emitted error
	checks.
	(mapvar::get,set): Handle NULL<->"" impedance mismatch.
	(itervar::get_key): Ditto.  Use base index=1 for keys.
	* testsuite/buildok/one.stp: Extend.  And it runs with -p5 too.
	* stap.1: Document use of ";" statament as mechanism for grammar
	ambiguity resolution.
	* stp_check.in: Set $prefix.
	* systemtap.spec.in: Prereq kernel-devel, kernel-debuginfo,
	and not tcl.
	* tapsets.cxx: Make slightly less verbose.

2005-08-03  Graydon Hoare  <graydon@redhat.com>

	* tapsets.cxx (dwflpp): Fix address calculation logic a bit,
	and use prologue-end addresses for function probes.

2005-08-03  Frank Ch. Eigler  <fche@redhat.com>

	* stap.1: More meat, all stub sections filled.
	* elaborate.cxx (visit_assignment): Add numerous missing cases.
	* parse.cxx: Parse ".=" operator.
	* testsuite/semok/sixteen.stp: Check them.
	* main.cxx (usage): Don't show incompletely supported options.

2005-08-03  Martin Hunt  <hunt@redhat.com>

	* stp_check.in : Copy sources to /var/cache/systemtap.
	* systemtap.spec.in: Install stp_check.
	* Makefile.am (install-exec-local): Install stp_check.

2005-08-03  Martin Hunt  <hunt@redhat.com>

	* configure.ac: Add stp_check to AC_CONFIG_FILES.
	* stp_check.in : New file.

2005-08-03  Frank Ch. Eigler  <fche@elastic.org>

	* README: Be more specific about prerequisites.
	* tapset/builtin_string.stp: New builtin.
	* testsuite/buildok/seven.stp, semko/eighteen.stp: New tests.

2005-08-03  Roland McGrath  <roland@redhat.com>

	* configure.ac, systemtap.spec.in: Version 0.2.1.
	* Makefile.in, aclocal.m4, configure: Regenerated.

2005-08-02  Roland McGrath  <roland@redhat.com>

	* loc2c.c (emit_bitfield): Return bool, value from emit_base_fetch.
	(c_translate_fetch): Update caller.
	(c_translate_pointer): Never ignore emit_base_fetch return value.

	* systemtap.spec.in (%install): Remove parameters after %makeinstall.

2005-08-02  Frank Ch. Eigler  <fche@elastic.org>

	* loc2.c (emit_loc_address): Emit interleaved declaration into
	its own nested { } block.
	* tapsets.cxx (literal_stmt_for_local): Emit deref_fault block
	unconditionally.
	* tapset/builtin_hexstring.stp: New builtin.
	* testsuite/buildok/six.stp: New test.

2005-08-02  Frank Ch. Eigler  <fche@elastic.org>

	* tapsets.cxx (emit_registrations): Treat module_name="kernel"
	as if module_name="".

2005-08-01  Graydon Hoare  <graydon@redhat.com>

	* staptree.{cxx,h} (probe_point::component): Add a ctor.
	* tapsets.cxx (dwarf_derived_probe): Synthesize concrete
	probe_point for matched pattern.
	(dwarf_probe_type)
	(dwarf_query::add_kernel_probe)
	(dwarf_query::add_module_probe): Remove, they were noise.
	(dwflpp::module_name_matches): Don't call get_module_dwarf().

2005-08-01  Frank Ch. Eigler  <fche@elastic.org>

	* tapsets.cxx: Support ".return" option for function probe points.
	* testuite/buildok/five.stp: Try it.

2005-08-01  Frank Ch. Eigler  <fche@elastic.org>

	* elaborate.cxx (derive_probes, semantic_pass_symbols): Improve
	error message specificity.
	* translate.cxx (emit_module_init): Compact partial registration
	recovery code.
	(emit_module_exit): Invert deregistration sequence.
	* testsuite/buildok/four.stp: Some module() test case.

2005-08-01  Frank Ch. Eigler  <fche@elastic.org>

	* elaborate.cxx (derive_probes): Print error if results empty.
	* tapsets.cxx (dwflpp_assert): Handle positive RCs, which likely
	came from errno.
	(dwflpp::setup): Improve missing debug-info messages.
	* testsuite/semko/sixteen,seventeen.stp: New tests.
	* runtest.sh: Save stdout/stderr of FAIL/XPASS test cases.
	* Makefile.am (clean-local): Clean up testsuite/.
	* Makefile.in, aclocal.m4: Regenerated.

2005-07-29  Frank Ch. Eigler  <fche@redhat.com>

	From Graydon Hoare <graydon@redhat.com:
	* tapsets.cxx (var_expanding_copy_visitor): Correct lvalue cases.

2005-07-29  Frank Ch. Eigler  <fche@redhat.com>

	* Makefile.am: Make sure stpd goes into libexec/systemtap/
	* Makefile.in: Regenerated.

2005-07-29  Frank Ch. Eigler  <fche@redhat.com>

	* configure.ac: Fail configure stage if elfutils 0.111+ is not found.
	* Makefile.am, elaborate.cxx, tapsets.cxx: Unconditionalize.
	* configure, Makefile.in, config.in: Regenerated.

2005-07-29  Roland McGrath  <roland@redhat.com>

	* Version 0.2 distribution.

	* systemtap.spec.in: Include %{_datadir}/systemtap/tapset directory.
	(%check): Add section, run make check.
	* Makefile.am (EXTRA_DIST): Add runtest.sh.
	* Makefile.in: Regenerated.

	* systemtap.spec.in: Include man pages.
	* Makefile.am (man_MANS): Renamed to dist_man_MANS.

	* configure.ac: Add AM_CONDITIONAL definition of HAVE_LIBDW.
	* Makefile.am [HAVE_LIBDW] (stap_SOURCES_libdw): New variable.
	(stap_SOURCES): Use it, moving loc2c.c there.
	* configure, config.in: Regenerated.

	* tapsets.cxx: <libdw.h> -> <elfutils/libdw.h>
	* loc2c.c, loc2c.h: Likewise.

	* main.cxx (main): Check return value of system.

	* systemtap.spec.in (LDFLAGS): Punt using $ORIGIN here, just hard-code
	%{_libdir}.
	(elfutils_version): Bump to 0.111.
	[bundled_elfutils]: Don't massage libdwfl.h header any more.

	* configure.ac: Don't check for libelf.h, not actually #include'd.
	Update -ldw check for merged libdwfl+libdw.
	(stap_LIBS): New substituted variable.  Set only this, not LIBS,
	with -ldw check.
	* Makefile.am (stap_LDADD): New variable, use @stap_LIBS@.

	* Makefile.am (AM_CPPFLAGS): Use ${pkgdatadir}.
	(AM_CFLAGS): Use -W instead of -Wextra, for gcc 3 compatibility.
	(stpd_LDFLAGS): Variable removed.
	(AM_MAKEFLAGS): Variable removed.

2005-07-28  Frank Ch. Eigler  <fche@elastic.org>

	* elaborate.cxx (find_var): Correct array dereferencing thinko.

2005-07-28  Graydon Hoare  <graydon@redhat.com>

	* elaborate.cxx (derived_probe::derived_probe): Accept NULL probe.
	* staptree.cxx (provide, require): Move from here...
	* staptree.h: to here, and virtualize deep-copy methods.
	* translate.cxx
	(c_unparser::emit_common_header): Include loc2c-runtime.h
	* tapsets.cxx
	(dwflpp::iterate_over_modules): Use new, faster getmodules loop.
	(dwflpp::literal_stmt_for_local): New method, call loc2c.
	(var_expanding_copy_visitor): New struct which expands $-vars.
	(dwarf_derived_probe): Rebuild this->body using var expander.
	(query_function): Refactor logic a bit for speed.
	* loc2c.{c,h}: Copies (with minor changes) of Roland's work
	from elfutils CVS.
	* Makefile.am (AM_CFLAGS): Set to elfutils-style.
	(stap_SOURCES): Add loc2c.c.
	* Makefile.in: Regenerate.

2005-07-28  Frank Ch. Eigler  <fche@redhat.com>

	* stap.1: Beginnings of a man page.
	* Makefile.am: Install it.  Comment out stpd LDADD goodies.
	* configure.ac: Futilely complain about non-stpd LIBS.
	* Makefile.in, configure.in: Regenerated.
	* main.cxx (usage): Remove ARGS from help text, as nothing is
	done with these yet.

2005-07-28  Frank Ch. Eigler  <fche@redhat.com>

	* translate.cxx: Add "pt_regs*" field to context.
	* tapsets.cxx (*): Correct kprobes API interface.
	* testsuite/buildok/three.stp: New test, copied from semok.
	* Makefile.am (install-data-local): Also install runtime/relayfs,
	so scripts can build against headers located thereunder.
	* Makefile.in: Regenerated.

2005-07-28  Frank Ch. Eigler  <fche@redhat.com>

	translator/1120
	* main.cxx (main): Preset -R and -I options from environment
	variables (if set).  Pass guru mode flags to parser.
	* parse.cxx (privileged): New parser operation flag.  Update callers.
	(parse_embeddedcode): Throw an error if !privileged.
	(parse_functiondecl): Change signature.  Prevent duplicates.
	(parse_globals): Ditto.
	* parse.h: Corresponding changes.
	* tapset/*.stp: Beginnings of real tapset library, to replace
	previous builtins.
	* tapsets.cxx: Greatly reduce verbose mode output.
	* Makefile.am: Install & dist it.
	* runtest.sh: Refer to it.
	* Makefile.in, aclocal.m4: Regenerated.
	* testsuite/*/*.stp: Set guru mode via /bin/sh if needed.
	* testusite/*/*ko.stp: Homogenize shell scripts.

2005-07-28  Frank Ch. Eigler  <fche@redhat.com>

	translator/1120
	translator/1123
	* elaborate.cxx (semantic_pass_symbols): Print a more helpful
	error message around exceptions.
	* elaborate.h (systemtap_session): Add guru_mode field.
	* main.cxx (main): Initialize it to false.  Add version-sensitive
	script library searching.  Add more failure messages.
	* tapsets.cxx (dwflpp_assert): Add a decorative text parameter.
	Update callers.

2005-07-28  Martin Hunt  <hunt@redhat.com>

	* Makefile.am (install-data-local): Add runtime/transport.
	* Makefile.in: regenerated.

2005-07-26  Graydon Hoare  <graydon@redhat.com>

	* elaborate.cxx: Revert builtin-function code.
	* translate.cxx: Likewise.
	* tapsets.{h,cxx}: Likewise.

2005-07-26  Martin Hunt  <hunt@redhat.com>

	* buildrun.cxx (compile_pass): Add -Wno-unused to CFLAGS because
	usually a module doesn't use every function in the runtime.

2005-07-26  Martin Hunt  <hunt@redhat.com>

	* Makefile.am (stpd_LDFLAGS): Set rpath correclty because otherwise
	automake doesn't seem to get it right when binaries are in libexec
	subdirs.
	(AM_CPPFLAGS): revert.
	* systemtap.spec.in (LDFLAGS): Set libexecdir here instead.

2005-07-26  Frank Ch. Eigler  <fche@redhat.com>

	Support %{ embedded-c %}
	* staptree.h (embeddedcode): New statement subtype.  Stub support in
	visitors.
	* staptree.cxx: Ditto.
	* parse.cxx: Parse %{ / %}.  Accept "_" as identifier leading char.
	(parse_probe): Simplify calling convention.
	* elaborate.h: Store embedded code.
	* elaborate.cxx: Pass it.
	* translate.cxx: Transcribe it.  Return some dropped module init/exit
	code.
	* Makefile.am: Add buildok/buildko tests.
	* Makefile.in: Regenerated.
	* main.cxx: Return EXIT_SUCCESS/FAILURE even for weird rc.
	* testsuite/parseok/nine.stp: Test _identifiers.
	* testsuite/transko/*.stp: Tweak to force -p3 rather than -p2 errors.
	* testsuite/semok/transko.stp: ... and keep it that way in the future.
	* testsuite/parse*/*: Some new tests for %{ %}.
	* testsuite/build*/*: New tests for -p4.

2005-07-26  Martin Hunt  <hunt@redhat.com>

	* Makefile.am (AM_CPPFLAGS): Set PKGLIBDIR correctly.

2005-07-26  Martin Hunt  <hunt@redhat.com>

	* systemtap.spec.in: Stpd goes in libexec/systemtap.
	* Makefile.am (libexecdir): Set to libexecdir/systemtap.
	* aclocal.m4, Makefile.in: Regenerated

2005-07-25  Roland McGrath  <roland@redhat.com>

	* configure.ac: Don't define PKGLIBDIR and PKGDATADIR here.
	* Makefile.am (AM_CPPFLAGS): New variable, use -D here instead.
	(dist-hook): Don't remove ChangeLog files.
	(install-data-local): Don't install docs, just runtime stuff.
	(rpm, clean-local): Use make variables instead of @substitution@s.
	* configure, config.in, aclocal.m4, Makefile.in: Regenerated

2005-07-22  Graydon Hoare  <graydon@redhat.com>

	* translate.cxx (itervar): New class.
	(*::visit_foreach_loop): Implement.
	Various bug fixes.
	* staptree.cxx (deep_copy_visitor::*): Copy tok fields.
	* elaborate.cxx (lvalue_aware_traversing_visitor):
	(mutated_map_collector):
	(no_map_mutation_during_iteration_check): New classes.
	(semantic_pass_maps): New function to check map usage.
	(semantic_pass): Call it.
	* testsuite/transok/eight.stp: Test 'foreach' loop translation.
	* testsuite/semko/{thirteen,fourteen,fifteen}.stp:
	Test prohibited forms of foreach loops.

2005-07-21  Martin Hunt  <hunt@redhat.com>

	* Makefile.am (EXTRA_DIST): Add systemtap.spec.
	(install-data-local): Install docs and probes.
	(docs): New target.
	(rpm): New target.

	* configure.ac: Set initial version to 0.1.1.
	(pkglibdir): Set to libexec.

	* Makefile.in: Regenerated.

2005-07-20  Graydon Hoare  <graydon@redhat.com>

	* elaborate.{cxx,h} (find_array): Remove.
	(find_scalar): Rename to find_var, add array support.
	* staptree.{cxx,h} (vardecl::compatible_arity): New method.
	* translate.cxx: Refactor, add array read/write support.
	* testsuite/transok/three.stp: Uncomment array uses.
	* testsuite/transok/seven.stp: New test of array r/w.

2005-07-20  Frank Ch. Eigler  <fche@redhat.com>

	* tapsets.cxx (*::emit_[de]registrations): Add logic for probe
	lifecycle control (session_state).
	* translate.cxx (emit_common_header,emit_module_{init,exit}): Ditto.
	(visit_*): Use per-context errorcount.

2005-07-19  Frank Ch. Eigler  <fche@redhat.com>

	* Makefile.am (dist-hook): Complete the resulting tarball.
	* Makefile.in: Regenerated.

2005-07-19  Frank Ch. Eigler  <fche@redhat.com>

	* translate.cxx (emit_module_init/exit, translate_pass): Conform
	to newer runtime startup/shutdown hooks.

2005-07-15  Frank Ch. Eigler  <fche@redhat.com>

	* Makefile.am (install-data-local): Correct typo.
	* buildrun.cxx (compile_pass): Ditto.
	* main.cxx (main): Print errors if passes 4 or 5 fail.

2005-07-14  Frank Ch. Eigler  <fche@redhat.com>

	* buildrun.cxx (compile_pass, run_pass): Get closer to a working
	test_mode.
	* translate.cxx (emit_module_init, emit_common_header): Ditto.
	(translate_pass): Ditto.

2005-07-14  Frank Ch. Eigler  <fche@redhat.com>

	* Makefile.am (stpd): Install in $pkglibdir.
	(runtime): Copy to $pkgdatadir.
	* configure.ac: Pass along pkgdatadir and pkglibdir.
	* main.cxx: Default runtime_path from pkgdatadir.
	* buildrun.cxx (run_pass): Correct stpd directory.
	* Makefile.in, configure, config.in: Regenerated.

2005-07-12  Graydon Hoare  <graydon@redhat.com>

	* elaborate.cxx
	(semantic_pass_symbols): Only enter body if non-null.
	(semantic_pass_types): Likewise.
	(semantic_pass): Pass session to register_standard_tapsets.
	* translate.cxx
	(builtin_collector): New struct.
	(hookup_builtins): New function.
	(translate_pass): Only translate functions with bodies.
	(c_unparser::emit_common_header): Likewise, and call hookup_builtins.
	* tapsets.hh (builtin_function): New class.
	(register_standard_tapsets): Change parameter to session.
	* tapsets.cc (bultin_function::*): Implement class.
	(register_standard_tapsets): Register printk, log, warn.
	* testsuite/transok/six.stp: New test.

2005-07-12  Frank Ch. Eigler  <fche@redhat.com>

	* buildrun.cxx (compile_pass): Make non-verbose mode quieter.
	(run_pass): Spawn stpd for dirty work.
	* Makefile.am: Also build stpd into libexecdir.
	* configure.ac: Pass LIBEXECDIR.
	* Makefile.in, configure, config.in: Regenerated.
	* AUTHORS: Update.

2005-07-11  Graydon Hoare  <graydon@redhat.com>

	* staptree.cxx (require): Generally handle null pointers in src.
	(deep_copy_visitor::visit_if_statement): Revert fche's change.

2005-07-11  Frank Ch. Eigler  <fche@redhat.com>

	* parse.cxx (parse_literal): Compile cleanly on 64-bit host.
	* staptree.cxx (deep_copy_visitor::visit_if_statement): Don't
	freak on a null if_statement.elseblock.

2005-07-07  Graydon Hoare  <graydon@redhat.com>

	* staptree.{h,cxx} (deep_copy_visitor): New visitor.
	* elaborate.cxx
	(derived_probe::derived_probe):
	(alias_expansion_builder::build): Use it.
	* testsuite/semok/fifteen.stp: New test which relies on deep copy.

2005-07-07  Frank Ch. Eigler  <fche@redhat.com>

	* 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.

2005-07-05  Graydon Hoare  <graydon@redhat.com>

	* 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.

2005-07-05  Frank Ch. Eigler  <fche@redhat.com>

	* 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.

2005-07-04  Graydon Hoare  <graydon@redhat.com>

	* 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.

2005-06-27  Graydon Hoare  <graydon@redhat.com>

	* staptree.{h,cxx} (probe_alias): New structure.
	* parse.{h,cxx} (parser::parse): Parse probes or probe aliases.
	(parser::parse_probe): Likewise.
	* tapsets.{h,cxx}:
	(derived_probe_builder):
	(match_key):
	(match_node):
	(alias_derived_probe): Move from here,
	* elaborate.{h,cxx}: to here.
	* elaborate.h (systemtap_session::pattern_root): New member.
	(register_library_aliases): New function.
	* tapsets.cxx: Build one dwarf_derived_probe per target address.

2005-06-23  Graydon Hoare  <graydon@redhat.com>

	* tapsets.cxx
	(probe_type): New enum.
	(probe_spec): New struct.
	(dwarf_derived_probe): Reorganize a bit, interpret .return.
	(query_statement): Translate addresses back to module space.
	(probe_entry_function_name):
	(probe_entry_struct_kprobe_name):
	(foreach_dwarf_probe_entry):
	(declare_dwarf_kernel_entry):
	(deregister_dwarf_kernel_entry):
	(register_dwarf_kernel_entry):
	(register_dwarf_module):
	(declare_dwarf_module_entry):
	(deregister_dwarf_module_entry):
	(register_dwarf_module_entry): New functions.
	(dwarf_derived_probes::emit_probe_entries):
	(dwarf_derived_probes::emit_registrations):
	(dwarf_derived_probes::emit_deregistrations): Implement.

2005-06-21  Frank Ch. Eigler  <fche@redhat.com>

	* config.in, configure: Regenerated.
	* tapsets.cxx: Make dwarf code conditional on new elfutils header.

2005-06-20  Graydon Hoare  <graydon@redhat.com>

	* configure.ac: Scan for libdwfl.
	* staptree.h (verbose): New global.
	* main.cxx (usage, main): Implement -v option.
	* tapsets.cxx (dwflpp): New struct.
	(query_statement): New function.
	(query_function): New function.
	(query_cu): New function.
	(query_module): New function.
	(dwarf_derived_probe): Implement primary forms.

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.

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.

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.

2005-06-05  Frank Ch. Eigler  <fche@elastic.org>

	Implement for/next/continue/break/while statements.
	* staptree.h: Declare new 0-arity statement types.  Tweak for_loop.
	* parse.cxx: Parse them all.
	* translate.cxx (c_unparser): Maintain break/continue label stack.
	(visit_for_loop, *_statement): New implementations.
	* elaborate.*, staptree.cxx: Mechanical changes.
	* testsuite/parseok/ten.stp, semko/twelve.stp, transko/two.stp,
	transok/five.stp: New tests.

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.

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.

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.

2005-06-02  Frank Ch. Eigler  <fche@redhat.com>

	* translate.cxx (visit_concatenation, visit_binary_expression):
	New basic implementation.
	(*): Reduce emitted whitespace and remove `# LINE "FILE"' lines.

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 ().

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.

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.

2005-05-24  Frank Ch. Eigler  <fche@redhat.com>

	* elaborate.cxx (find_array): Support automagic tapset globals.
	* testsuite/semok/nine.stp: Test it.
	* staptree.cxx (stapfile print): List globals.

2005-05-24  Frank Ch. Eigler  <fche@redhat.com>

	* testsuite/semlib/*: New tapset library chunks for "-I" testing.
	* testsuite/semok/eight.stp, nine.stp: New tests.

2005-05-22  Frank Ch. Eigler  <fche@elastic.org>

	* Makefile.am (gcov): New target to generate test-coverage data from
	a testsuite run.
	* Makefile.in: Regenerated.

2005-05-20  Frank Ch. Eigler  <fche@redhat.com>

	Many changes throughout.  Partial sketch of translation output.
	* elaborate.*: Elaboration pass.
	* translate.*: Translation pass.
	* staptree.*: Simplified for visitor concept.
	* main.cxx: Translator mainline.
	* *test.cxx: Removed.
	* testsuite/*: Some new tests, some changed for newer syntax.

2005-05-05  Frank Ch. Eigler  <fche@redhat.com>

	* parse.cxx (parse): Add helper methods.
	(lexer::scan, parse_assignment): Parse "<<<" operator.  Fix assignment
	associativity.
	(parse_symbol): Permit function with empty arg list.
	(parse_global, parse_statement, parse_functiondecl): Expect
	unconsumed leading keyword.
	(parse_global): Don't use ";" termination.
	* parse.h: Corresponding changes.
	* staptree.cxx (binary_expression::resolve_types): Fix <<<
	type inference.
	(translator_output): Improve pretty-printing.
	(*): Add general visitors to statement/expression types.
	* staptree.h: Corresponding changes.  Tweak symresolution_info fields.
	Add semantic_error class.
	* semtest.cxx: Adapt to this.
	* testsuite/parseok/two.stp, semok/*.stp: Adapt to syntax changes.

2005-03-15  Frank Ch. Eigler  <fche@redhat.com>

	* semtest.cxx: Print probe signatures properly.
	* staptree.cxx (probe::printsig): New function.

2005-03-15  Frank Ch. Eigler  <fche@redhat.com>

	* TODO: New file.  Include some probe-point-provider syntax examples.
	* parse.cxx (lexer::scan, parser::parse_literal): Support hex, octal
	numbers via strtol.
	(parse_probe, parse_probe_point): Modify for dotted syntax.
	* staptree.cxx: Ditto.
	* parsetest.cxx, semtest.cxx: Print parse/sem results even if
	.stp files were given on command line.
	* parse.h, staptree.h: Rename probe_point_spec -> probe_point.
	* runtest.sh: New test-runner front-end script.
	* Makefile.am: Use it for TESTS_ENVIRONMENT.
	* testsuite/*: Update probe point syntax.  Add a bunch of new tests.

2005-03-04  Frank Ch. Eigler  <fche@redhat.com>

	* parse.cxx (scan): Support '$' characters in identifiers.
	(parse_symbol): Support thread-> / process-> shorthand.
	* staptree.cxx (symresolution_info::find): Split up into
	find_scalar, find_array, find_function.
	(resolve_symbols): Call the above for symbol/arrayindex/functioncall.
	(find_scalar): Add stub support for synthetic builtin variables.
	* staptree.h: Corresponding changes.
	* testsuite/*: Some new tests.

2005-03-03  Frank Ch. Eigler  <fche@redhat.com>

	* parse.cxx (parse_assignment): Assert lvalueness of left
	operand.
	* staptree.h (expression): Add is_lvalue member.
	* staptree.cxx (functioncall::resolve_types): Don't crash on
	formal-vs-actual argument count mismatch.
	(*): Add some is_lvalue stub functions.
	* testsuite/*: Some new tests.

2005-03-01  Frank Ch. Eigler  <fche@redhat.com>

	* parse.cxx: Implement left-associativity for several types of
	operators.  Add some more statement types.  Parse functions.
	Be able to print tokens.  Simplify error generating functions.
	Save tokens in all parse tree nodes.
	* parse.h: Corresponding changes.
	* staptree.cxx: Move tree-printing functions here.  Add many
	new functions for symbol and type resolution.
	* staptree.h: Corresponding changes.
	* semtest.cxx: New semantic analysis pass & test driver.
	* testsuite/sem*/*: New tests.
	* parsetest.cxx: Separated parse test driver.
	* testsuite/parse*/*: Adapt tests to parsetest driver.
	* Makefile.am: Build semtest.  Run its tests.
	* Makefile.in: Regenerated.

2005-02-11  Frank Ch. Eigler  <fche@redhat.com>

	* parse.cxx, parse.h: New files: parser.
	* staptree.h: New file: semantic object declarations.
	* staptree.cxx: New dummy driver file.
