diff options
author | fche <fche> | 2007-10-02 21:41:06 +0000 |
---|---|---|
committer | fche <fche> | 2007-10-02 21:41:06 +0000 |
commit | 4a6d3dfa0f3ce20f95c892818b9f1b617ddcd0cf (patch) | |
tree | e1490763657f8bd3152862e302e93be986d02beb /translate.h | |
parent | 55913279fa530b4400e8aba9c9791e2fe32f5bcc (diff) | |
download | systemtap-steved-4a6d3dfa0f3ce20f95c892818b9f1b617ddcd0cf.tar.gz systemtap-steved-4a6d3dfa0f3ce20f95c892818b9f1b617ddcd0cf.tar.xz systemtap-steved-4a6d3dfa0f3ce20f95c892818b9f1b617ddcd0cf.zip |
PR 3635: reduce number of global objects
2007-10-02 Frank Ch. Eigler <fche@redhat.com>
PR 3635
* translate.cxx (emit_global): Wrap all globals and locks into one
top-level struct. Update references to former "global_VAR" prefix.
* translate.h (emit_global_init): New function.
Diffstat (limited to 'translate.h')
-rw-r--r-- | translate.h | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/translate.h b/translate.h index fde8af9f..6c8b4785 100644 --- a/translate.h +++ b/translate.h @@ -64,9 +64,13 @@ struct unparser // ... // } context [MAXCONCURRENCY]; + // struct { virtual void emit_global (vardecl* v) = 0; - // static TYPE global_NAME; - // static rwlock_t global_NAME_lock; + // TYPE s_NAME; // NAME is prefixed with "s_" to avoid kernel id collisions + // rwlock_t s_NAME_lock; + // } global = { + virtual void emit_global_init (vardecl* v) = 0; + // }; virtual void emit_global_param (vardecl* v) = 0; // module_param_... -- at end of file |