]> sourceware.org Git - systemtap.git/commit
stapdyn: Move contexts into shm
authorJosh Stone <jistone@redhat.com>
Wed, 12 Dec 2012 23:34:39 +0000 (15:34 -0800)
committerJosh Stone <jistone@redhat.com>
Wed, 12 Dec 2012 23:34:39 +0000 (15:34 -0800)
commitc08bf9de6995364f438b523785081d68e34dfe96
tree7e49616f9b70ddab4bf5f83a7f9146de7b578be3
parent7c3e97f401ce202270ab77893b5db4dc855d0cc3
stapdyn: Move contexts into shm

David already abstracted different allocation schemes for runtime
contexts, so this time the kernel runtime needs no change.  The dyninst
runtime now has the per-cpu contexts included in shared memory.

* translate.cxx (c_unparser::emit_common_header): Move runtime_context.h
  and common_session_state.h right after the struct context definition.
* runtime/dyninst/common_session_state.h: Add struct context[] to shm.
  (stp_session_context): New function to access a specific context.
* runtime/dyninst/runtime_context.h (_stp_runtime_contexts_alloc/free):
  Don't manage memory anymore, just initialize the locks and be done.
  Use stp_session_context throughout to retrieve contexts.
* runtime/dyninst/runtime.h (stp_pthread_mutex_init_shared): New, set
  the PTHREAD_PROCESS_SHARED attribute while initializing a mutex.
* runtime/dyninst/shm.c (_stp_shm_finalize): dbug the final mmap addr.
runtime/dyninst/common_session_state.h
runtime/dyninst/runtime.h
runtime/dyninst/runtime_context.h
runtime/dyninst/shm.c
translate.cxx
This page took 0.027108 seconds and 5 git commands to generate.