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

Side by Side Diff: src/spaces.cc

Issue 7979019: SemiSpace::AssertValidRange should use NewSpacePage::FromLimit for start. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 9 years, 3 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 | « no previous file | 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 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 1301 matching lines...) Expand 10 before | Expand all | Expand 10 after
1312 } 1312 }
1313 CHECK(page->IsFlagSet(MemoryChunk::SCAN_ON_SCAVENGE)); 1313 CHECK(page->IsFlagSet(MemoryChunk::SCAN_ON_SCAVENGE));
1314 CHECK(page->prev_page()->next_page() == page); 1314 CHECK(page->prev_page()->next_page() == page);
1315 page = page->next_page(); 1315 page = page->next_page();
1316 } 1316 }
1317 } 1317 }
1318 1318
1319 1319
1320 void SemiSpace::AssertValidRange(Address start, Address end) { 1320 void SemiSpace::AssertValidRange(Address start, Address end) {
1321 // Addresses belong to same semi-space 1321 // Addresses belong to same semi-space
1322 NewSpacePage* page = NewSpacePage::FromAddress(start); 1322 NewSpacePage* page = NewSpacePage::FromLimit(start);
1323 NewSpacePage* end_page = NewSpacePage::FromLimit(end); 1323 NewSpacePage* end_page = NewSpacePage::FromLimit(end);
1324 SemiSpace* space = page->semi_space(); 1324 SemiSpace* space = page->semi_space();
1325 CHECK_EQ(space, end_page->semi_space()); 1325 CHECK_EQ(space, end_page->semi_space());
1326 // Start address is before end address, either on same page, 1326 // Start address is before end address, either on same page,
1327 // or end address is on a later page in the linked list of 1327 // or end address is on a later page in the linked list of
1328 // semi-space pages. 1328 // semi-space pages.
1329 if (page == end_page) { 1329 if (page == end_page) {
1330 CHECK(start <= end); 1330 CHECK(start <= end);
1331 } else { 1331 } else {
1332 while (page != end_page) { 1332 while (page != end_page) {
(...skipping 1193 matching lines...) Expand 10 before | Expand all | Expand 10 after
2526 object->ShortPrint(); 2526 object->ShortPrint();
2527 PrintF("\n"); 2527 PrintF("\n");
2528 } 2528 }
2529 printf(" --------------------------------------\n"); 2529 printf(" --------------------------------------\n");
2530 printf(" Marked: %x, LiveCount: %x\n", mark_size, LiveBytes()); 2530 printf(" Marked: %x, LiveCount: %x\n", mark_size, LiveBytes());
2531 } 2531 }
2532 2532
2533 #endif // DEBUG 2533 #endif // DEBUG
2534 2534
2535 } } // namespace v8::internal 2535 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698