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

Side by Side Diff: src/frames.cc

Issue 1222013002: Concurrent sweeping of code space. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: 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 | « no previous file | src/heap/heap.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 // 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 "src/frames.h" 5 #include "src/frames.h"
6 6
7 #include <sstream> 7 #include <sstream>
8 8
9 #include "src/v8.h" 9 #include "src/v8.h"
10 10
(...skipping 1413 matching lines...) Expand 10 before | Expand all | Expand 10 after
1424 // Check if the inner pointer points into a large object chunk. 1424 // Check if the inner pointer points into a large object chunk.
1425 LargePage* large_page = heap->lo_space()->FindPage(inner_pointer); 1425 LargePage* large_page = heap->lo_space()->FindPage(inner_pointer);
1426 if (large_page != NULL) { 1426 if (large_page != NULL) {
1427 return GcSafeCastToCode(large_page->GetObject(), inner_pointer); 1427 return GcSafeCastToCode(large_page->GetObject(), inner_pointer);
1428 } 1428 }
1429 1429
1430 // Iterate through the page until we reach the end or find an object starting 1430 // Iterate through the page until we reach the end or find an object starting
1431 // after the inner pointer. 1431 // after the inner pointer.
1432 Page* page = Page::FromAddress(inner_pointer); 1432 Page* page = Page::FromAddress(inner_pointer);
1433 1433
1434 page->skip_list()->Lock();
1434 Address addr = page->skip_list()->StartFor(inner_pointer); 1435 Address addr = page->skip_list()->StartFor(inner_pointer);
1436 page->skip_list()->Unlock();
1435 1437
1436 Address top = heap->code_space()->top(); 1438 Address top = heap->code_space()->top();
1437 Address limit = heap->code_space()->limit(); 1439 Address limit = heap->code_space()->limit();
1438 1440
1439 while (true) { 1441 while (true) {
1440 if (addr == top && addr != limit) { 1442 if (addr == top && addr != limit) {
1441 addr = limit; 1443 addr = limit;
1442 continue; 1444 continue;
1443 } 1445 }
1444 1446
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
1536 for (StackFrameIterator it(isolate); !it.done(); it.Advance()) { 1538 for (StackFrameIterator it(isolate); !it.done(); it.Advance()) {
1537 StackFrame* frame = AllocateFrameCopy(it.frame(), zone); 1539 StackFrame* frame = AllocateFrameCopy(it.frame(), zone);
1538 list.Add(frame, zone); 1540 list.Add(frame, zone);
1539 } 1541 }
1540 return list.ToVector(); 1542 return list.ToVector();
1541 } 1543 }
1542 1544
1543 1545
1544 } // namespace internal 1546 } // namespace internal
1545 } // namespace v8 1547 } // namespace v8
OLDNEW
« no previous file with comments | « no previous file | src/heap/heap.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698