]> sourceware.org Git - systemtap.git/commit
Fix PR17055 by reading perf values in a sleepable context.
authorDavid Smith <dsmith@redhat.com>
Mon, 23 May 2016 15:26:08 +0000 (10:26 -0500)
committerDavid Smith <dsmith@redhat.com>
Mon, 23 May 2016 15:26:08 +0000 (10:26 -0500)
commit285ca4273c79bbabbddde09d6bdf9a17d4d0c1a2
tree7f164fe7e3ca7c4398817be9f53dd9cd0effbe81
parent37a4150fe4ace4af2d8335442feb91f5bb06d91e
Fix PR17055 by reading perf values in a sleepable context.

* tapsets.cxx (common_probe_entryfn_prologue): Add 'declaration_callback'
  and 'pre_context_callback' to allow callers to add to output prologue.
  (dwarf_derived_probe::emit_probe_local_init): For perf values, instead
  of reading the values here, just copy the values from where we stashed
  them when we read them before (when we could sleep).
  (uprobe_derived_probe::emit_perf_read_handler): New function.
  (uprobe_derived_probe_group::emit_module_perf_read_handlers): Ditto.
  (udpg_entryfn_prologue_declaration_callback): Ditto.
  (udpg_entryfn_prologue_pre_context_callback): Ditto.
  (uprobe_derived_probe_group::emit_module_utrace_decls): Call
  new function emit_module_perf_read_handlers().
  (uprobe_derived_probe_group::emit_module_decls): Figure out the maximun
  number of perf counters used per probe.
* tapsets.h: Add new callbacks to common_probe_entryfn_prologue().
* runtime/linux/uprobes-common.h (stap_uprobe_spec): Add
  'perf_read_handler' to actually read perf values.
* runtime/linux/uprobes-inode.c (stapiu_consumer): Ditto.
* runtime/linux/runtime.h: After loading the task_finder code, load the
  perf code if needed.
* runtime/common_probe_context.h: Add 'perf_read_values' to the context
  structure when we're using perf derived probes.
* testsuite/systemtap.base/perf.sh: Change '/usr/bin/cat' to '/bin/cat' so
  that systems (like RHEL6) that don't have 'usrmove' will still work.
runtime/common_probe_context.h
runtime/linux/runtime.h
runtime/linux/uprobes-common.h
runtime/linux/uprobes-inode.c
tapsets.cxx
tapsets.h
testsuite/systemtap.base/perf.sh
This page took 0.030951 seconds and 5 git commands to generate.