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

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

Issue 1706013: Changing string length field type from int to SMI. It will make it be a regu... (Closed) Base URL: http://v8.googlecode.com/svn/trunk/
Patch Set: '' Created 10 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « src/x64/stub-cache-x64.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2007-2010 the V8 project authors. All rights reserved. 1 // Copyright 2007-2010 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 555 matching lines...) Expand 10 before | Expand all | Expand 10 after
566 size, // Code space. 566 size, // Code space.
567 size, // Map space. 567 size, // Map space.
568 size, // Cell space. 568 size, // Cell space.
569 size); // Large object space. 569 size); // Large object space.
570 LinearAllocationScope linear_allocation_scope; 570 LinearAllocationScope linear_allocation_scope;
571 const int kSmallFixedArrayLength = 4; 571 const int kSmallFixedArrayLength = 4;
572 const int kSmallFixedArraySize = 572 const int kSmallFixedArraySize =
573 FixedArray::kHeaderSize + kSmallFixedArrayLength * kPointerSize; 573 FixedArray::kHeaderSize + kSmallFixedArrayLength * kPointerSize;
574 const int kSmallStringLength = 16; 574 const int kSmallStringLength = 16;
575 const int kSmallStringSize = 575 const int kSmallStringSize =
576 SeqAsciiString::kHeaderSize + kSmallStringLength; 576 (SeqAsciiString::kHeaderSize + kSmallStringLength +
577 kObjectAlignmentMask) & ~kObjectAlignmentMask;
577 const int kMapSize = Map::kSize; 578 const int kMapSize = Map::kSize;
578 579
579 Object* new_last = NULL; 580 Object* new_last = NULL;
580 for (int i = 0; 581 for (int i = 0;
581 i + kSmallFixedArraySize <= new_space_size; 582 i + kSmallFixedArraySize <= new_space_size;
582 i += kSmallFixedArraySize) { 583 i += kSmallFixedArraySize) {
583 Object* obj = Heap::AllocateFixedArray(kSmallFixedArrayLength); 584 Object* obj = Heap::AllocateFixedArray(kSmallFixedArrayLength);
584 if (new_last != NULL) { 585 if (new_last != NULL) {
585 CHECK(reinterpret_cast<char*>(obj) == 586 CHECK(reinterpret_cast<char*>(obj) ==
586 reinterpret_cast<char*>(new_last) + kSmallFixedArraySize); 587 reinterpret_cast<char*>(new_last) + kSmallFixedArraySize);
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
662 TEST(TestThatAlwaysFails) { 663 TEST(TestThatAlwaysFails) {
663 bool ArtificialFailure = false; 664 bool ArtificialFailure = false;
664 CHECK(ArtificialFailure); 665 CHECK(ArtificialFailure);
665 } 666 }
666 667
667 668
668 DEPENDENT_TEST(DependentTestThatAlwaysFails, TestThatAlwaysSucceeds) { 669 DEPENDENT_TEST(DependentTestThatAlwaysFails, TestThatAlwaysSucceeds) {
669 bool ArtificialFailure2 = false; 670 bool ArtificialFailure2 = false;
670 CHECK(ArtificialFailure2); 671 CHECK(ArtificialFailure2);
671 } 672 }
OLDNEW
« no previous file with comments | « src/x64/stub-cache-x64.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698