diff options
author | Elliott Baron <ebaron@toriamos.yyz.redhat.com> | 2008-11-28 17:12:57 -0500 |
---|---|---|
committer | Elliott Baron <ebaron@toriamos.yyz.redhat.com> | 2008-11-28 17:12:57 -0500 |
commit | 82762adc9d7e77cdce48a87a477a47fb9e14ecd9 (patch) | |
tree | 9698df6c70514f339cabb0eb72824f410db06a0e /translate.cxx | |
parent | 1ad820e32419c6ff9237962ec911e9c4eee79c4a (diff) | |
download | systemtap-steved-82762adc9d7e77cdce48a87a477a47fb9e14ecd9.tar.gz systemtap-steved-82762adc9d7e77cdce48a87a477a47fb9e14ecd9.tar.xz systemtap-steved-82762adc9d7e77cdce48a87a477a47fb9e14ecd9.zip |
PR6965 - Conditionally compile symbol table. Split context.stp into 3 files.
Diffstat (limited to 'translate.cxx')
-rw-r--r-- | translate.cxx | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/translate.cxx b/translate.cxx index 43299791..8f47ca92 100644 --- a/translate.cxx +++ b/translate.cxx @@ -1289,7 +1289,7 @@ c_unparser::emit_module_exit () << "atomic_read (& ((struct context *)per_cpu_ptr(contexts, i))->busy)) " << "holdon = 1;"; // NB: we run at least one of these during the shutdown sequence: - o->newline () << "yield ();"; // aka schedule() and then some + o->newline () << "yield ();"; // aka schedule() and then some o->newline(-2) << "} while (holdon);"; // cargo cult epilogue @@ -4601,6 +4601,9 @@ dump_unwindsyms (Dwfl_Module *m, c->output << "struct _stp_symbol " << "_stp_module_" << stpmod_idx<< "_symbols_" << secidx << "[] = {" << endl; + // Only include symbols if they will be used + c->output << "#ifdef NEED_SYMBOL_DATA" << endl; + // We write out a *sorted* symbol table, so the runtime doesn't have to sort them later. for (addrmap_t::iterator it = addrmap[secidx].begin(); it != addrmap[secidx].end(); it++) { @@ -4610,6 +4613,9 @@ dump_unwindsyms (Dwfl_Module *m, c->output << " { 0x" << hex << it->first-extra_offset << dec << ", " << lex_cast_qstring (it->second) << " }," << endl; } + + c->output << "#endif" << endl; + c->output << "};" << endl; } @@ -4675,7 +4681,7 @@ dump_unwindsyms (Dwfl_Module *m, c->output << ".build_id_len = 0, " << endl; //initialize the note section representing unloaded - c->output << ".notes_sect = 0," << endl; + c->output << ".notes_sect = 0," << endl; c->output << "};" << endl << endl; |