diff options
author | Steve Block <steveblock@google.com> | 2009-12-15 09:54:21 +0000 |
---|---|---|
committer | Steve Block <steveblock@google.com> | 2009-12-15 09:54:21 +0000 |
commit | d0582a6c46733687d045e4188a1bcd0123c758a1 (patch) | |
tree | 4139657adad206f69647f3d03f6fb2da2e8ae14e /src/execution.cc | |
parent | 3ce2e2076e8e3e60cf1810eec160ea2d8557e9e7 (diff) | |
download | android_external_v8-d0582a6c46733687d045e4188a1bcd0123c758a1.tar.gz android_external_v8-d0582a6c46733687d045e4188a1bcd0123c758a1.tar.bz2 android_external_v8-d0582a6c46733687d045e4188a1bcd0123c758a1.zip |
Update V8 to r3431 as required by WebKit r51976.
Change-Id: I567392c3f8c0a0d5201a4249611ac4ccf468cd5b
Diffstat (limited to 'src/execution.cc')
-rw-r--r-- | src/execution.cc | 39 |
1 files changed, 14 insertions, 25 deletions
diff --git a/src/execution.cc b/src/execution.cc index 229b8df9..2f646a56 100644 --- a/src/execution.cc +++ b/src/execution.cc @@ -31,18 +31,8 @@ #include "api.h" #include "codegen-inl.h" - -#if V8_TARGET_ARCH_IA32 -#include "ia32/simulator-ia32.h" -#elif V8_TARGET_ARCH_X64 -#include "x64/simulator-x64.h" -#elif V8_TARGET_ARCH_ARM -#include "arm/simulator-arm.h" -#else -#error Unsupported target architecture. -#endif - #include "debug.h" +#include "simulator.h" #include "v8threads.h" namespace v8 { @@ -237,15 +227,14 @@ void StackGuard::SetStackLimit(uintptr_t limit) { // If the current limits are special (eg due to a pending interrupt) then // leave them alone. uintptr_t jslimit = SimulatorStack::JsLimitFromCLimit(limit); - if (thread_local_.jslimit_ == thread_local_.initial_jslimit_) { + if (thread_local_.jslimit_ == thread_local_.real_jslimit_) { thread_local_.jslimit_ = jslimit; - Heap::SetStackLimit(jslimit); } - if (thread_local_.climit_ == thread_local_.initial_climit_) { + if (thread_local_.climit_ == thread_local_.real_climit_) { thread_local_.climit_ = limit; } - thread_local_.initial_climit_ = limit; - thread_local_.initial_jslimit_ = jslimit; + thread_local_.real_climit_ = limit; + thread_local_.real_jslimit_ = jslimit; } @@ -354,7 +343,7 @@ char* StackGuard::ArchiveStackGuard(char* to) { char* StackGuard::RestoreStackGuard(char* from) { ExecutionAccess access; memcpy(reinterpret_cast<char*>(&thread_local_), from, sizeof(ThreadLocal)); - Heap::SetStackLimit(thread_local_.jslimit_); + Heap::SetStackLimits(); return from + sizeof(ThreadLocal); } @@ -366,33 +355,33 @@ static internal::Thread::LocalStorageKey stack_limit_key = void StackGuard::FreeThreadResources() { Thread::SetThreadLocal( stack_limit_key, - reinterpret_cast<void*>(thread_local_.initial_climit_)); + reinterpret_cast<void*>(thread_local_.real_climit_)); } void StackGuard::ThreadLocal::Clear() { - initial_jslimit_ = kIllegalLimit; + real_jslimit_ = kIllegalLimit; jslimit_ = kIllegalLimit; - initial_climit_ = kIllegalLimit; + real_climit_ = kIllegalLimit; climit_ = kIllegalLimit; nesting_ = 0; postpone_interrupts_nesting_ = 0; interrupt_flags_ = 0; - Heap::SetStackLimit(kIllegalLimit); + Heap::SetStackLimits(); } void StackGuard::ThreadLocal::Initialize() { - if (initial_climit_ == kIllegalLimit) { + if (real_climit_ == kIllegalLimit) { // Takes the address of the limit variable in order to find out where // the top of stack is right now. uintptr_t limit = reinterpret_cast<uintptr_t>(&limit) - kLimitSize; ASSERT(reinterpret_cast<uintptr_t>(&limit) > kLimitSize); - initial_jslimit_ = SimulatorStack::JsLimitFromCLimit(limit); + real_jslimit_ = SimulatorStack::JsLimitFromCLimit(limit); jslimit_ = SimulatorStack::JsLimitFromCLimit(limit); - initial_climit_ = limit; + real_climit_ = limit; climit_ = limit; - Heap::SetStackLimit(SimulatorStack::JsLimitFromCLimit(limit)); + Heap::SetStackLimits(); } nesting_ = 0; postpone_interrupts_nesting_ = 0; |