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

Side by Side Diff: test/cctest/test-heap.cc

Issue 1226203011: Remove unused byte from Map::instance_sizes field. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Ported to all architectures. Created 5 years, 5 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
« no previous file with comments | « src/x87/macro-assembler-x87.cc ('k') | test/cctest/test-unboxed-doubles.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 5369 matching lines...) Expand 10 before | Expand all | Expand 10 after
5380 int padding_size = desired_offset - Page::kObjectStartOffset; 5380 int padding_size = desired_offset - Page::kObjectStartOffset;
5381 int padding_array_length = 5381 int padding_array_length =
5382 (padding_size - FixedArray::kHeaderSize) / kPointerSize; 5382 (padding_size - FixedArray::kHeaderSize) / kPointerSize;
5383 5383
5384 Handle<FixedArray> temp2 = 5384 Handle<FixedArray> temp2 =
5385 factory->NewFixedArray(padding_array_length, TENURED); 5385 factory->NewFixedArray(padding_array_length, TENURED);
5386 Page* page = Page::FromAddress(temp2->address()); 5386 Page* page = Page::FromAddress(temp2->address());
5387 CHECK_EQ(Page::kObjectStartOffset, page->Offset(temp2->address())); 5387 CHECK_EQ(Page::kObjectStartOffset, page->Offset(temp2->address()));
5388 } 5388 }
5389 5389
5390 Handle<JSObject> o = factory->NewJSObjectFromMap(map1, TENURED, false); 5390 Handle<JSObject> o = factory->NewJSObjectFromMap(map1, TENURED);
5391 o->set_properties(*factory->empty_fixed_array()); 5391 o->set_properties(*factory->empty_fixed_array());
5392 5392
5393 // Ensure that the object allocated where we need it. 5393 // Ensure that the object allocated where we need it.
5394 Page* page = Page::FromAddress(o->address()); 5394 Page* page = Page::FromAddress(o->address());
5395 CHECK_EQ(desired_offset, page->Offset(o->address())); 5395 CHECK_EQ(desired_offset, page->Offset(o->address()));
5396 5396
5397 // Now we have an object right at the end of the page. 5397 // Now we have an object right at the end of the page.
5398 5398
5399 // Enable incremental marking to trigger actions in Heap::AdjustLiveBytes() 5399 // Enable incremental marking to trigger actions in Heap::AdjustLiveBytes()
5400 // that would cause crash. 5400 // that would cause crash.
(...skipping 647 matching lines...) Expand 10 before | Expand all | Expand 10 after
6048 array->address(), 6048 array->address(),
6049 array->address() + array->Size()); 6049 array->address() + array->Size());
6050 DCHECK(reinterpret_cast<void*>(buffer->Get(1)) == 6050 DCHECK(reinterpret_cast<void*>(buffer->Get(1)) ==
6051 HeapObject::RawField(heap->empty_fixed_array(), 6051 HeapObject::RawField(heap->empty_fixed_array(),
6052 FixedArrayBase::kLengthOffset)); 6052 FixedArrayBase::kLengthOffset));
6053 DCHECK(reinterpret_cast<void*>(buffer->Get(2)) == 6053 DCHECK(reinterpret_cast<void*>(buffer->Get(2)) ==
6054 HeapObject::RawField(heap->empty_fixed_array(), 6054 HeapObject::RawField(heap->empty_fixed_array(),
6055 FixedArrayBase::kLengthOffset)); 6055 FixedArrayBase::kLengthOffset));
6056 delete buffer; 6056 delete buffer;
6057 } 6057 }
OLDNEW
« no previous file with comments | « src/x87/macro-assembler-x87.cc ('k') | test/cctest/test-unboxed-doubles.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698