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

Side by Side Diff: src/frames.cc

Issue 1632913003: [heap] Move to page lookups for SemiSpace, NewSpace, and Heap containment methods (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Addressed comments Created 4 years, 10 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/assembler.cc ('k') | src/heap/heap.h » ('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/ast/ast.h" 9 #include "src/ast/ast.h"
10 #include "src/ast/scopeinfo.h" 10 #include "src/ast/scopeinfo.h"
(...skipping 1501 matching lines...) Expand 10 before | Expand all | Expand 10 after
1512 Code* code = reinterpret_cast<Code*>(object); 1512 Code* code = reinterpret_cast<Code*>(object);
1513 DCHECK(code != NULL && GcSafeCodeContains(code, inner_pointer)); 1513 DCHECK(code != NULL && GcSafeCodeContains(code, inner_pointer));
1514 return code; 1514 return code;
1515 } 1515 }
1516 1516
1517 1517
1518 Code* InnerPointerToCodeCache::GcSafeFindCodeForInnerPointer( 1518 Code* InnerPointerToCodeCache::GcSafeFindCodeForInnerPointer(
1519 Address inner_pointer) { 1519 Address inner_pointer) {
1520 Heap* heap = isolate_->heap(); 1520 Heap* heap = isolate_->heap();
1521 if (!heap->code_space()->Contains(inner_pointer) && 1521 if (!heap->code_space()->Contains(inner_pointer) &&
1522 !heap->lo_space()->Contains(inner_pointer)) { 1522 !heap->lo_space()->ContainsSlow(inner_pointer)) {
Michael Lippautz 2016/02/08 18:00:39 This was already a slow version. The name now refl
1523 return nullptr; 1523 return nullptr;
1524 } 1524 }
1525 1525
1526 // Check if the inner pointer points into a large object chunk. 1526 // Check if the inner pointer points into a large object chunk.
1527 LargePage* large_page = heap->lo_space()->FindPage(inner_pointer); 1527 LargePage* large_page = heap->lo_space()->FindPage(inner_pointer);
1528 if (large_page != NULL) { 1528 if (large_page != NULL) {
1529 return GcSafeCastToCode(large_page->GetObject(), inner_pointer); 1529 return GcSafeCastToCode(large_page->GetObject(), inner_pointer);
1530 } 1530 }
1531 1531
1532 // Iterate through the page until we reach the end or find an object starting 1532 // Iterate through the page until we reach the end or find an object starting
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after
1640 for (StackFrameIterator it(isolate); !it.done(); it.Advance()) { 1640 for (StackFrameIterator it(isolate); !it.done(); it.Advance()) {
1641 StackFrame* frame = AllocateFrameCopy(it.frame(), zone); 1641 StackFrame* frame = AllocateFrameCopy(it.frame(), zone);
1642 list.Add(frame, zone); 1642 list.Add(frame, zone);
1643 } 1643 }
1644 return list.ToVector(); 1644 return list.ToVector();
1645 } 1645 }
1646 1646
1647 1647
1648 } // namespace internal 1648 } // namespace internal
1649 } // namespace v8 1649 } // namespace v8
OLDNEW
« no previous file with comments | « src/assembler.cc ('k') | src/heap/heap.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698