| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 4457 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4468 // Verify that the pointers in the large object got updated. | 4468 // Verify that the pointers in the large object got updated. |
| 4469 for (int i = 0; i < kSize; i += kStep) { | 4469 for (int i = 0; i < kSize; i += kStep) { |
| 4470 CHECK_EQ(lo->get(i), *lit); | 4470 CHECK_EQ(lo->get(i), *lit); |
| 4471 CHECK(lo->get(i) != old_location); | 4471 CHECK(lo->get(i) != old_location); |
| 4472 } | 4472 } |
| 4473 } | 4473 } |
| 4474 | 4474 |
| 4475 | 4475 |
| 4476 class DummyVisitor : public ObjectVisitor { | 4476 class DummyVisitor : public ObjectVisitor { |
| 4477 public: | 4477 public: |
| 4478 void VisitPointers(Object** start, Object** end) { } | 4478 void VisitPointers(Object** start, Object** end) override {} |
| 4479 }; | 4479 }; |
| 4480 | 4480 |
| 4481 | 4481 |
| 4482 TEST(DeferredHandles) { | 4482 TEST(DeferredHandles) { |
| 4483 CcTest::InitializeVM(); | 4483 CcTest::InitializeVM(); |
| 4484 Isolate* isolate = CcTest::i_isolate(); | 4484 Isolate* isolate = CcTest::i_isolate(); |
| 4485 Heap* heap = isolate->heap(); | 4485 Heap* heap = isolate->heap(); |
| 4486 v8::HandleScope scope(reinterpret_cast<v8::Isolate*>(isolate)); | 4486 v8::HandleScope scope(reinterpret_cast<v8::Isolate*>(isolate)); |
| 4487 HandleScopeData* data = isolate->handle_scope_data(); | 4487 HandleScopeData* data = isolate->handle_scope_data(); |
| 4488 Handle<Object> init(heap->empty_string(), isolate); | 4488 Handle<Object> init(heap->empty_string(), isolate); |
| (...skipping 1795 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6284 isolate->IncrementJsCallsFromApiCounter(); | 6284 isolate->IncrementJsCallsFromApiCounter(); |
| 6285 isolate->IncrementJsCallsFromApiCounter(); | 6285 isolate->IncrementJsCallsFromApiCounter(); |
| 6286 isolate->IncrementJsCallsFromApiCounter(); | 6286 isolate->IncrementJsCallsFromApiCounter(); |
| 6287 calls_per_ms = memory_reducer->SampleAndGetJsCallsPerMs(4); | 6287 calls_per_ms = memory_reducer->SampleAndGetJsCallsPerMs(4); |
| 6288 CheckDoubleEquals(2, calls_per_ms); | 6288 CheckDoubleEquals(2, calls_per_ms); |
| 6289 } | 6289 } |
| 6290 | 6290 |
| 6291 | 6291 |
| 6292 } // namespace internal | 6292 } // namespace internal |
| 6293 } // namespace v8 | 6293 } // namespace v8 |
| OLD | NEW |