Index: vm/code_index_table_test.cc |
=================================================================== |
--- vm/code_index_table_test.cc (revision 6302) |
+++ vm/code_index_table_test.cc (working copy) |
@@ -4,10 +4,10 @@ |
#include "platform/assert.h" |
#include "vm/class_finalizer.h" |
+#include "vm/code_index_table.h" |
#include "vm/compiler.h" |
#include "vm/object.h" |
#include "vm/pages.h" |
-#include "vm/stack_frame.h" |
#include "vm/unit_test.h" |
namespace dart { |
@@ -35,8 +35,9 @@ |
char buffer[256]; |
// Get access to the code index table. |
- Isolate* isolate = Isolate::Current(); |
- ASSERT(isolate != NULL); |
+ ASSERT(Isolate::Current() != NULL); |
+ CodeIndexTable* code_index_table = Isolate::Current()->code_index_table(); |
+ ASSERT(code_index_table != NULL); |
lib = Library::CoreLibrary(); |
@@ -125,7 +126,7 @@ |
code = function.CurrentCode(); |
EXPECT(code.Size() > 16); |
pc = code.EntryPoint() + 16; |
- EXPECT(StackFrame::LookupCode(isolate, pc) == code.raw()); |
+ EXPECT(code_index_table->LookupCode(pc) == code.raw()); |
OS::SNPrint(buffer, 256, "moo%d", 54); |
function_name = String::New(buffer); |
@@ -134,7 +135,7 @@ |
code = function.CurrentCode(); |
EXPECT(code.Size() > 16); |
pc = code.EntryPoint() + 16; |
- EXPECT(StackFrame::LookupCode(isolate, pc) == code.raw()); |
+ EXPECT(code_index_table->LookupCode(pc) == code.raw()); |
// Lookup the large function |
OS::SNPrint(buffer, 256, "moo%d", 0); |
@@ -145,10 +146,10 @@ |
EXPECT(code.Size() > 16); |
pc = code.EntryPoint() + 16; |
EXPECT(code.Size() > PageSpace::kPageSize); |
- EXPECT(StackFrame::LookupCode(isolate, pc) == code.raw()); |
+ EXPECT(code_index_table->LookupCode(pc) == code.raw()); |
EXPECT(code.Size() > (1 * MB)); |
pc = code.EntryPoint() + (1 * MB); |
- EXPECT(StackFrame::LookupCode(isolate, pc) == code.raw()); |
+ EXPECT(code_index_table->LookupCode(pc) == code.raw()); |
} |
#endif // TARGET_ARCH_IA32 || TARGET_ARCH_X64 |