OLD | NEW |
1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 20 matching lines...) Expand all Loading... |
31 #include "src/v8.h" | 31 #include "src/v8.h" |
32 #include "test/cctest/cctest.h" | 32 #include "test/cctest/cctest.h" |
33 | 33 |
34 #include "src/api.h" | 34 #include "src/api.h" |
35 #include "src/debug/debug.h" | 35 #include "src/debug/debug.h" |
36 #include "src/execution.h" | 36 #include "src/execution.h" |
37 #include "src/factory.h" | 37 #include "src/factory.h" |
38 #include "src/global-handles.h" | 38 #include "src/global-handles.h" |
39 #include "src/macro-assembler.h" | 39 #include "src/macro-assembler.h" |
40 #include "src/objects.h" | 40 #include "src/objects.h" |
| 41 #include "test/cctest/heap/utils-inl.h" |
41 | 42 |
42 using namespace v8::internal; | 43 using namespace v8::internal; |
43 | 44 |
44 namespace { | 45 namespace { |
45 | 46 |
46 | 47 |
47 template<typename HashMap> | 48 template<typename HashMap> |
48 static void TestHashMap(Handle<HashMap> table) { | 49 static void TestHashMap(Handle<HashMap> table) { |
49 Isolate* isolate = CcTest::i_isolate(); | 50 Isolate* isolate = CcTest::i_isolate(); |
50 Factory* factory = isolate->factory(); | 51 Factory* factory = isolate->factory(); |
(...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
224 TEST(ObjectHashTableCausesGC) { | 225 TEST(ObjectHashTableCausesGC) { |
225 i::FLAG_stress_compaction = false; | 226 i::FLAG_stress_compaction = false; |
226 LocalContext context; | 227 LocalContext context; |
227 v8::HandleScope scope(context->GetIsolate()); | 228 v8::HandleScope scope(context->GetIsolate()); |
228 Isolate* isolate = CcTest::i_isolate(); | 229 Isolate* isolate = CcTest::i_isolate(); |
229 TestHashMapCausesGC(ObjectHashTable::New(isolate, 1)); | 230 TestHashMapCausesGC(ObjectHashTable::New(isolate, 1)); |
230 } | 231 } |
231 #endif | 232 #endif |
232 | 233 |
233 } // namespace | 234 } // namespace |
OLD | NEW |