#include "src/execution/thread-local-top.h"
#include "src/base/sanitizer/msan.h"
#include "src/execution/isolate.h"
#include "src/execution/simulator.h"
#if V8_ENABLE_WEBASSEMBLY
#include "src/trap-handler/trap-handler.h"
#endif
namespace v8 {
namespace internal {
void ThreadLocalTop::Clear() { … }
void ThreadLocalTop::Initialize(Isolate* isolate) { … }
void ThreadLocalTop::Free() { … }
#if defined(USE_SIMULATOR)
void ThreadLocalTop::StoreCurrentStackPosition() {
last_api_entry_ = simulator_->get_sp();
}
#elif defined(V8_USE_ADDRESS_SANITIZER)
void ThreadLocalTop::StoreCurrentStackPosition() {
last_api_entry_ = reinterpret_cast<Address>(GetCurrentStackPosition());
}
#endif
}
}