Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(74)

Side by Side Diff: test/cctest/test-unboxed-doubles.cc

Issue 1731063007: Remove the global Strength enum class completely. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@local_strong-remove-literals
Patch Set: Remove more cruft. Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include <stdlib.h> 5 #include <stdlib.h>
6 #include <utility> 6 #include <utility>
7 7
8 #include "src/v8.h" 8 #include "src/v8.h"
9 9
10 #include "src/compilation-cache.h" 10 #include "src/compilation-cache.h"
(...skipping 1095 matching lines...) Expand 10 before | Expand all | Expand 10 after
1106 Representation::Tagged(), 1106 Representation::Tagged(),
1107 INSERT_TRANSITION).ToHandleChecked(); 1107 INSERT_TRANSITION).ToHandleChecked();
1108 1108
1109 // Create |obj_value| in old space. 1109 // Create |obj_value| in old space.
1110 Handle<HeapObject> obj_value; 1110 Handle<HeapObject> obj_value;
1111 Page* ec_page; 1111 Page* ec_page;
1112 { 1112 {
1113 AlwaysAllocateScope always_allocate(isolate); 1113 AlwaysAllocateScope always_allocate(isolate);
1114 // Make sure |obj_value| is placed on an old-space evacuation candidate. 1114 // Make sure |obj_value| is placed on an old-space evacuation candidate.
1115 SimulateFullSpace(old_space); 1115 SimulateFullSpace(old_space);
1116 obj_value = factory->NewJSArray(32 * KB, FAST_HOLEY_ELEMENTS, 1116 obj_value = factory->NewJSArray(32 * KB, FAST_HOLEY_ELEMENTS, TENURED);
1117 Strength::WEAK, TENURED);
1118 ec_page = Page::FromAddress(obj_value->address()); 1117 ec_page = Page::FromAddress(obj_value->address());
1119 } 1118 }
1120 1119
1121 // Create object in new space. 1120 // Create object in new space.
1122 Handle<JSObject> obj = factory->NewJSObjectFromMap(map, NOT_TENURED); 1121 Handle<JSObject> obj = factory->NewJSObjectFromMap(map, NOT_TENURED);
1123 1122
1124 Handle<HeapNumber> heap_number = factory->NewHeapNumber(42.5); 1123 Handle<HeapNumber> heap_number = factory->NewHeapNumber(42.5);
1125 obj->WriteToField(0, *heap_number); 1124 obj->WriteToField(0, *heap_number);
1126 obj->WriteToField(1, *obj_value); 1125 obj->WriteToField(1, *obj_value);
1127 1126
(...skipping 318 matching lines...) Expand 10 before | Expand all | Expand 10 after
1446 Handle<JSObject> obj; 1445 Handle<JSObject> obj;
1447 Handle<HeapObject> obj_value; 1446 Handle<HeapObject> obj_value;
1448 Page* ec_page; 1447 Page* ec_page;
1449 { 1448 {
1450 AlwaysAllocateScope always_allocate(isolate); 1449 AlwaysAllocateScope always_allocate(isolate);
1451 obj = factory->NewJSObjectFromMap(map, TENURED); 1450 obj = factory->NewJSObjectFromMap(map, TENURED);
1452 CHECK(old_space->Contains(*obj)); 1451 CHECK(old_space->Contains(*obj));
1453 1452
1454 // Make sure |obj_value| is placed on an old-space evacuation candidate. 1453 // Make sure |obj_value| is placed on an old-space evacuation candidate.
1455 SimulateFullSpace(old_space); 1454 SimulateFullSpace(old_space);
1456 obj_value = factory->NewJSArray(32 * KB, FAST_HOLEY_ELEMENTS, 1455 obj_value = factory->NewJSArray(32 * KB, FAST_HOLEY_ELEMENTS, TENURED);
1457 Strength::WEAK, TENURED);
1458 ec_page = Page::FromAddress(obj_value->address()); 1456 ec_page = Page::FromAddress(obj_value->address());
1459 CHECK_NE(ec_page, Page::FromAddress(obj->address())); 1457 CHECK_NE(ec_page, Page::FromAddress(obj->address()));
1460 } 1458 }
1461 1459
1462 // Heap is ready, force |ec_page| to become an evacuation candidate and 1460 // Heap is ready, force |ec_page| to become an evacuation candidate and
1463 // simulate incremental marking. 1461 // simulate incremental marking.
1464 ec_page->SetFlag(MemoryChunk::FORCE_EVACUATION_CANDIDATE_FOR_TESTING); 1462 ec_page->SetFlag(MemoryChunk::FORCE_EVACUATION_CANDIDATE_FOR_TESTING);
1465 SimulateIncrementalMarking(heap); 1463 SimulateIncrementalMarking(heap);
1466 1464
1467 // Check that everything is ready for triggering incremental write barrier 1465 // Check that everything is ready for triggering incremental write barrier
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
1554 1552
1555 // TODO(ishell): add respective tests for property kind reconfiguring from 1553 // TODO(ishell): add respective tests for property kind reconfiguring from
1556 // accessor field to double, once accessor fields are supported by 1554 // accessor field to double, once accessor fields are supported by
1557 // Map::ReconfigureProperty(). 1555 // Map::ReconfigureProperty().
1558 1556
1559 1557
1560 // TODO(ishell): add respective tests for fast property removal case once 1558 // TODO(ishell): add respective tests for fast property removal case once
1561 // Map::ReconfigureProperty() supports that. 1559 // Map::ReconfigureProperty() supports that.
1562 1560
1563 #endif 1561 #endif
OLDNEW
« no previous file with comments | « test/cctest/interpreter/bytecode_expectations/CallRuntime.golden ('k') | test/mjsunit/es6/classes-subclass-builtins.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698