Index: runtime/vm/stub_code.cc |
diff --git a/runtime/vm/stub_code.cc b/runtime/vm/stub_code.cc |
index cf77f5fa4e413b31b25f694d23c1691a8095529b..dda8a2650ca36e54cd37338745d39db17d1082f6 100644 |
--- a/runtime/vm/stub_code.cc |
+++ b/runtime/vm/stub_code.cc |
@@ -7,6 +7,7 @@ |
#include "platform/assert.h" |
#include "platform/globals.h" |
#include "vm/assembler.h" |
+#include "vm/clustered_snapshot.h" |
#include "vm/disassembler.h" |
#include "vm/flags.h" |
#include "vm/object_store.h" |
@@ -14,7 +15,6 @@ |
#include "vm/snapshot.h" |
#include "vm/virtual_memory.h" |
#include "vm/visitor.h" |
-#include "vm/clustered_snapshot.h" |
namespace dart { |
@@ -26,7 +26,6 @@ StubEntry* StubCode::entries_[kNumStubEntries] = { |
#undef STUB_CODE_DECLARE |
}; |
- |
StubEntry::StubEntry(const Code& code) |
: code_(code.raw()), |
entry_point_(code.UncheckedEntryPoint()), |
@@ -34,19 +33,16 @@ StubEntry::StubEntry(const Code& code) |
size_(code.Size()), |
label_(code.UncheckedEntryPoint()) {} |
- |
// Visit all object pointers. |
void StubEntry::VisitObjectPointers(ObjectPointerVisitor* visitor) { |
ASSERT(visitor != NULL); |
visitor->VisitPointer(reinterpret_cast<RawObject**>(&code_)); |
} |
- |
#define STUB_CODE_GENERATE(name) \ |
code ^= Generate("_stub_" #name, StubCode::Generate##name##Stub); \ |
entries_[k##name##Index] = new StubEntry(code); |
- |
void StubCode::InitOnce() { |
#if defined(DART_PRECOMPILED_RUNTIME) |
// Stubs will be loaded from the snapshot. |
@@ -58,16 +54,12 @@ void StubCode::InitOnce() { |
#endif // DART_PRECOMPILED_RUNTIME |
} |
- |
#undef STUB_CODE_GENERATE |
- |
void StubCode::Init(Isolate* isolate) {} |
- |
void StubCode::VisitObjectPointers(ObjectPointerVisitor* visitor) {} |
- |
bool StubCode::HasBeenInitialized() { |
#if !defined(TARGET_ARCH_DBC) |
// Use JumpToHandler and InvokeDart as canaries. |
@@ -79,7 +71,6 @@ bool StubCode::HasBeenInitialized() { |
#endif |
} |
- |
bool StubCode::InInvocationStub(uword pc) { |
#if !defined(TARGET_ARCH_DBC) |
ASSERT(HasBeenInitialized()); |
@@ -93,7 +84,6 @@ bool StubCode::InInvocationStub(uword pc) { |
#endif |
} |
- |
bool StubCode::InJumpToFrameStub(uword pc) { |
#if !defined(TARGET_ARCH_DBC) |
ASSERT(HasBeenInitialized()); |
@@ -106,7 +96,6 @@ bool StubCode::InJumpToFrameStub(uword pc) { |
#endif |
} |
- |
RawCode* StubCode::GetAllocationStubForClass(const Class& cls) { |
// These stubs are not used by DBC. |
#if !defined(TARGET_ARCH_DBC) |
@@ -175,7 +164,6 @@ RawCode* StubCode::GetAllocationStubForClass(const Class& cls) { |
return Code::null(); |
} |
- |
const StubEntry* StubCode::UnoptimizedStaticCallEntry( |
intptr_t num_args_tested) { |
// These stubs are not used by DBC. |
@@ -196,7 +184,6 @@ const StubEntry* StubCode::UnoptimizedStaticCallEntry( |
#endif |
} |
- |
RawCode* StubCode::Generate(const char* name, |
void (*GenerateStub)(Assembler* assembler)) { |
Assembler assembler; |
@@ -217,7 +204,6 @@ RawCode* StubCode::Generate(const char* name, |
return code.raw(); |
} |
- |
const char* StubCode::NameOfStub(uword entry_point) { |
#define VM_STUB_CODE_TESTER(name) \ |
if ((name##_entry() != NULL) && \ |