ensure debug helper functions are retained by linker

Apple's linker tends to remove functions which are never called, which
is not what we want for e.g. vmPrintTrace, since that function is only
intended to be called interactively from within GDB.
This commit is contained in:
Joel Dice 2012-02-04 15:42:19 -07:00
parent be6896b8a0
commit 33976d1ba4

View File

@ -4402,7 +4402,7 @@ noop()
} // namespace vm } // namespace vm
// for debugging // for debugging
void JNIEXPORT void
vmPrintTrace(Thread* t) vmPrintTrace(Thread* t)
{ {
class Visitor: public Processor::StackVisitor { class Visitor: public Processor::StackVisitor {
@ -4444,7 +4444,7 @@ vmPrintTrace(Thread* t)
} }
// also for debugging // also for debugging
void* JNIEXPORT void*
vmAddressFromLine(Thread* t, object m, unsigned line) vmAddressFromLine(Thread* t, object m, unsigned line)
{ {
object code = methodCode(t, m); object code = methodCode(t, m);