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

Unified Diff: Source/platform/heap/ThreadState.cpp

Issue 910663002: [Oilpan] Set stack limit using estimated sizes (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Add FIXME Created 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/platform/heap/StackFrameDepth.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/platform/heap/ThreadState.cpp
diff --git a/Source/platform/heap/ThreadState.cpp b/Source/platform/heap/ThreadState.cpp
index fb3061f56e3381ea5b25ba375bc969e1aa2da6e7..230801275137e5a862d5e2eac9e0a07f05a0ff62 100644
--- a/Source/platform/heap/ThreadState.cpp
+++ b/Source/platform/heap/ThreadState.cpp
@@ -254,7 +254,9 @@ ThreadState::ThreadState()
if (isMainThread()) {
s_mainThreadStackStart = reinterpret_cast<uintptr_t>(m_startOfStack) - sizeof(void*);
- s_mainThreadUnderestimatedStackSize = StackFrameDepth::getUnderestimatedStackSize() - sizeof(void*);
+ size_t underestimatedStackSize = StackFrameDepth::getUnderestimatedStackSize();
+ if (underestimatedStackSize > 0)
+ s_mainThreadUnderestimatedStackSize = underestimatedStackSize - sizeof(void*);
}
for (int heapIndex = 0; heapIndex < LargeObjectHeapIndex; heapIndex++)
« no previous file with comments | « Source/platform/heap/StackFrameDepth.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698