Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 1 | // Copyright 2014 the V8 project authors. All rights reserved. |
| 2 | // Use of this source code is governed by a BSD-style license that can be |
| 3 | // found in the LICENSE file. |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 4 | |
| 5 | #ifndef V8_EXECUTION_H_ |
| 6 | #define V8_EXECUTION_H_ |
| 7 | |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 8 | #include "src/handles.h" |
Ben Murdoch | 257744e | 2011-11-30 15:57:28 +0000 | [diff] [blame] | 9 | |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 10 | namespace v8 { |
| 11 | namespace internal { |
| 12 | |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 13 | class Execution FINAL : public AllStatic { |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 14 | public: |
| 15 | // Call a function, the caller supplies a receiver and an array |
| 16 | // of arguments. Arguments are Object* type. After function returns, |
| 17 | // pointers in 'args' might be invalid. |
| 18 | // |
| 19 | // *pending_exception tells whether the invoke resulted in |
| 20 | // a pending exception. |
| 21 | // |
Ben Murdoch | 589d697 | 2011-11-30 16:04:58 +0000 | [diff] [blame] | 22 | // When convert_receiver is set, and the receiver is not an object, |
| 23 | // and the function called is not in strict mode, receiver is converted to |
| 24 | // an object. |
| 25 | // |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 26 | MUST_USE_RESULT static MaybeHandle<Object> Call( |
| 27 | Isolate* isolate, |
| 28 | Handle<Object> callable, |
| 29 | Handle<Object> receiver, |
| 30 | int argc, |
| 31 | Handle<Object> argv[], |
| 32 | bool convert_receiver = false); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 33 | |
| 34 | // Construct object from function, the caller supplies an array of |
| 35 | // arguments. Arguments are Object* type. After function returns, |
| 36 | // pointers in 'args' might be invalid. |
| 37 | // |
| 38 | // *pending_exception tells whether the invoke resulted in |
| 39 | // a pending exception. |
| 40 | // |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 41 | MUST_USE_RESULT static MaybeHandle<Object> New(Handle<JSFunction> func, |
| 42 | int argc, |
| 43 | Handle<Object> argv[]); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 44 | |
| 45 | // Call a function, just like Call(), but make sure to silently catch |
| 46 | // any thrown exceptions. The return value is either the result of |
| 47 | // calling the function (if caught exception is false) or the exception |
| 48 | // that occurred (if caught exception is true). |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 49 | // In the exception case, exception_out holds the caught exceptions, unless |
| 50 | // it is a termination exception. |
| 51 | static MaybeHandle<Object> TryCall(Handle<JSFunction> func, |
| 52 | Handle<Object> receiver, int argc, |
| 53 | Handle<Object> argv[], |
| 54 | MaybeHandle<Object>* exception_out = NULL); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 55 | |
| 56 | // ECMA-262 9.3 |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 57 | MUST_USE_RESULT static MaybeHandle<Object> ToNumber( |
| 58 | Isolate* isolate, Handle<Object> obj); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 59 | |
| 60 | // ECMA-262 9.4 |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 61 | MUST_USE_RESULT static MaybeHandle<Object> ToInteger( |
| 62 | Isolate* isolate, Handle<Object> obj); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 63 | |
| 64 | // ECMA-262 9.5 |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 65 | MUST_USE_RESULT static MaybeHandle<Object> ToInt32( |
| 66 | Isolate* isolate, Handle<Object> obj); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 67 | |
| 68 | // ECMA-262 9.6 |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 69 | MUST_USE_RESULT static MaybeHandle<Object> ToUint32( |
| 70 | Isolate* isolate, Handle<Object> obj); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 71 | |
Emily Bernier | d0a1eb7 | 2015-03-24 16:35:39 -0400 | [diff] [blame^] | 72 | |
| 73 | // ES6, draft 10-14-14, section 7.1.15 |
| 74 | MUST_USE_RESULT static MaybeHandle<Object> ToLength( |
| 75 | Isolate* isolate, Handle<Object> obj); |
| 76 | |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 77 | // ECMA-262 9.8 |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 78 | MUST_USE_RESULT static MaybeHandle<Object> ToString( |
| 79 | Isolate* isolate, Handle<Object> obj); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 80 | |
| 81 | // ECMA-262 9.8 |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 82 | MUST_USE_RESULT static MaybeHandle<Object> ToDetailString( |
| 83 | Isolate* isolate, Handle<Object> obj); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 84 | |
| 85 | // ECMA-262 9.9 |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 86 | MUST_USE_RESULT static MaybeHandle<Object> ToObject( |
| 87 | Isolate* isolate, Handle<Object> obj); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 88 | |
| 89 | // Create a new date object from 'time'. |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 90 | MUST_USE_RESULT static MaybeHandle<Object> NewDate( |
| 91 | Isolate* isolate, double time); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 92 | |
Ben Murdoch | f87a203 | 2010-10-22 12:50:53 +0100 | [diff] [blame] | 93 | // Create a new regular expression object from 'pattern' and 'flags'. |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 94 | MUST_USE_RESULT static MaybeHandle<JSRegExp> NewJSRegExp( |
| 95 | Handle<String> pattern, Handle<String> flags); |
Ben Murdoch | f87a203 | 2010-10-22 12:50:53 +0100 | [diff] [blame] | 96 | |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 97 | // Used to implement [] notation on strings (calls JS code) |
| 98 | static Handle<Object> CharAt(Handle<String> str, uint32_t index); |
| 99 | |
| 100 | static Handle<Object> GetFunctionFor(); |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 101 | MUST_USE_RESULT static MaybeHandle<JSFunction> InstantiateFunction( |
| 102 | Handle<FunctionTemplateInfo> data); |
| 103 | MUST_USE_RESULT static MaybeHandle<JSObject> InstantiateObject( |
| 104 | Handle<ObjectTemplateInfo> data); |
| 105 | MUST_USE_RESULT static MaybeHandle<Object> ConfigureInstance( |
| 106 | Isolate* isolate, Handle<Object> instance, Handle<Object> data); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 107 | static Handle<String> GetStackTraceLine(Handle<Object> recv, |
| 108 | Handle<JSFunction> fun, |
| 109 | Handle<Object> pos, |
| 110 | Handle<Object> is_global); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 111 | |
| 112 | // Get a function delegate (or undefined) for the given non-function |
| 113 | // object. Used for support calling objects as functions. |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 114 | static Handle<Object> GetFunctionDelegate(Isolate* isolate, |
| 115 | Handle<Object> object); |
| 116 | MUST_USE_RESULT static MaybeHandle<Object> TryGetFunctionDelegate( |
| 117 | Isolate* isolate, |
| 118 | Handle<Object> object); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 119 | |
| 120 | // Get a function delegate (or undefined) for the given non-function |
| 121 | // object. Used for support calling objects as constructors. |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 122 | static Handle<Object> GetConstructorDelegate(Isolate* isolate, |
| 123 | Handle<Object> object); |
| 124 | static MaybeHandle<Object> TryGetConstructorDelegate(Isolate* isolate, |
| 125 | Handle<Object> object); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 126 | }; |
| 127 | |
| 128 | |
| 129 | class ExecutionAccess; |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 130 | class PostponeInterruptsScope; |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 131 | |
| 132 | |
| 133 | // StackGuard contains the handling of the limits that are used to limit the |
| 134 | // number of nested invocations of JavaScript and the stack size used in each |
| 135 | // invocation. |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 136 | class StackGuard FINAL { |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 137 | public: |
| 138 | // Pass the address beyond which the stack should not grow. The stack |
| 139 | // is assumed to grow downwards. |
Steve Block | 44f0eee | 2011-05-26 01:26:41 +0100 | [diff] [blame] | 140 | void SetStackLimit(uintptr_t limit); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 141 | |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 142 | // Threading support. |
Steve Block | 44f0eee | 2011-05-26 01:26:41 +0100 | [diff] [blame] | 143 | char* ArchiveStackGuard(char* to); |
| 144 | char* RestoreStackGuard(char* from); |
| 145 | static int ArchiveSpacePerThread() { return sizeof(ThreadLocal); } |
| 146 | void FreeThreadResources(); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 147 | // Sets up the default stack guard for this thread if it has not |
| 148 | // already been set up. |
Steve Block | 44f0eee | 2011-05-26 01:26:41 +0100 | [diff] [blame] | 149 | void InitThread(const ExecutionAccess& lock); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 150 | // Clears the stack guard for this thread so it does not look as if |
| 151 | // it has been set up. |
Steve Block | 44f0eee | 2011-05-26 01:26:41 +0100 | [diff] [blame] | 152 | void ClearThread(const ExecutionAccess& lock); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 153 | |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 154 | #define INTERRUPT_LIST(V) \ |
| 155 | V(DEBUGBREAK, DebugBreak, 0) \ |
| 156 | V(DEBUGCOMMAND, DebugCommand, 1) \ |
| 157 | V(TERMINATE_EXECUTION, TerminateExecution, 2) \ |
| 158 | V(GC_REQUEST, GC, 3) \ |
| 159 | V(INSTALL_CODE, InstallCode, 4) \ |
| 160 | V(API_INTERRUPT, ApiInterrupt, 5) \ |
| 161 | V(DEOPT_MARKED_ALLOCATION_SITES, DeoptMarkedAllocationSites, 6) |
| 162 | |
| 163 | #define V(NAME, Name, id) \ |
| 164 | inline bool Check##Name() { return CheckInterrupt(NAME); } \ |
| 165 | inline void Request##Name() { RequestInterrupt(NAME); } \ |
| 166 | inline void Clear##Name() { ClearInterrupt(NAME); } |
| 167 | INTERRUPT_LIST(V) |
| 168 | #undef V |
| 169 | |
| 170 | // Flag used to set the interrupt causes. |
| 171 | enum InterruptFlag { |
| 172 | #define V(NAME, Name, id) NAME = (1 << id), |
| 173 | INTERRUPT_LIST(V) |
| 174 | #undef V |
| 175 | #define V(NAME, Name, id) NAME | |
| 176 | ALL_INTERRUPTS = INTERRUPT_LIST(V) 0 |
| 177 | #undef V |
| 178 | }; |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 179 | |
Steve Block | d0582a6 | 2009-12-15 09:54:21 +0000 | [diff] [blame] | 180 | // This provides an asynchronous read of the stack limits for the current |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 181 | // thread. There are no locks protecting this, but it is assumed that you |
| 182 | // have the global V8 lock if you are using multiple V8 threads. |
Steve Block | 44f0eee | 2011-05-26 01:26:41 +0100 | [diff] [blame] | 183 | uintptr_t climit() { |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 184 | return thread_local_.climit_; |
| 185 | } |
Steve Block | 44f0eee | 2011-05-26 01:26:41 +0100 | [diff] [blame] | 186 | uintptr_t real_climit() { |
Shimeng (Simon) Wang | 8a31eba | 2010-12-06 19:01:33 -0800 | [diff] [blame] | 187 | return thread_local_.real_climit_; |
| 188 | } |
Steve Block | 44f0eee | 2011-05-26 01:26:41 +0100 | [diff] [blame] | 189 | uintptr_t jslimit() { |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 190 | return thread_local_.jslimit_; |
| 191 | } |
Steve Block | 44f0eee | 2011-05-26 01:26:41 +0100 | [diff] [blame] | 192 | uintptr_t real_jslimit() { |
Steve Block | d0582a6 | 2009-12-15 09:54:21 +0000 | [diff] [blame] | 193 | return thread_local_.real_jslimit_; |
| 194 | } |
Steve Block | 44f0eee | 2011-05-26 01:26:41 +0100 | [diff] [blame] | 195 | Address address_of_jslimit() { |
Steve Block | d0582a6 | 2009-12-15 09:54:21 +0000 | [diff] [blame] | 196 | return reinterpret_cast<Address>(&thread_local_.jslimit_); |
| 197 | } |
Steve Block | 44f0eee | 2011-05-26 01:26:41 +0100 | [diff] [blame] | 198 | Address address_of_real_jslimit() { |
Steve Block | d0582a6 | 2009-12-15 09:54:21 +0000 | [diff] [blame] | 199 | return reinterpret_cast<Address>(&thread_local_.real_jslimit_); |
| 200 | } |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 201 | |
| 202 | // If the stack guard is triggered, but it is not an actual |
| 203 | // stack overflow, then handle the interruption accordingly. |
| 204 | Object* HandleInterrupts(); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 205 | |
| 206 | private: |
Steve Block | 44f0eee | 2011-05-26 01:26:41 +0100 | [diff] [blame] | 207 | StackGuard(); |
| 208 | |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 209 | bool CheckInterrupt(InterruptFlag flag); |
| 210 | void RequestInterrupt(InterruptFlag flag); |
| 211 | void ClearInterrupt(InterruptFlag flag); |
| 212 | bool CheckAndClearInterrupt(InterruptFlag flag); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 213 | |
| 214 | // You should hold the ExecutionAccess lock when calling this method. |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 215 | bool has_pending_interrupts(const ExecutionAccess& lock) { |
| 216 | return thread_local_.interrupt_flags_ != 0; |
Steve Block | 6ded16b | 2010-05-10 14:33:55 +0100 | [diff] [blame] | 217 | } |
| 218 | |
| 219 | // You should hold the ExecutionAccess lock when calling this method. |
Steve Block | 44f0eee | 2011-05-26 01:26:41 +0100 | [diff] [blame] | 220 | inline void set_interrupt_limits(const ExecutionAccess& lock); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 221 | |
Steve Block | d0582a6 | 2009-12-15 09:54:21 +0000 | [diff] [blame] | 222 | // Reset limits to actual values. For example after handling interrupt. |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 223 | // You should hold the ExecutionAccess lock when calling this method. |
Steve Block | 44f0eee | 2011-05-26 01:26:41 +0100 | [diff] [blame] | 224 | inline void reset_limits(const ExecutionAccess& lock); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 225 | |
| 226 | // Enable or disable interrupts. |
Steve Block | 44f0eee | 2011-05-26 01:26:41 +0100 | [diff] [blame] | 227 | void EnableInterrupts(); |
| 228 | void DisableInterrupts(); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 229 | |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 230 | #if V8_TARGET_ARCH_64_BIT |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 231 | static const uintptr_t kInterruptLimit = V8_UINT64_C(0xfffffffffffffffe); |
| 232 | static const uintptr_t kIllegalLimit = V8_UINT64_C(0xfffffffffffffff8); |
| 233 | #else |
| 234 | static const uintptr_t kInterruptLimit = 0xfffffffe; |
| 235 | static const uintptr_t kIllegalLimit = 0xfffffff8; |
| 236 | #endif |
| 237 | |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 238 | void PushPostponeInterruptsScope(PostponeInterruptsScope* scope); |
| 239 | void PopPostponeInterruptsScope(); |
| 240 | |
| 241 | class ThreadLocal FINAL { |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 242 | public: |
| 243 | ThreadLocal() { Clear(); } |
| 244 | // You should hold the ExecutionAccess lock when you call Initialize or |
| 245 | // Clear. |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 246 | void Clear(); |
Steve Block | d0582a6 | 2009-12-15 09:54:21 +0000 | [diff] [blame] | 247 | |
Steve Block | 44f0eee | 2011-05-26 01:26:41 +0100 | [diff] [blame] | 248 | // Returns true if the heap's stack limits should be set, false if not. |
Ben Murdoch | 257744e | 2011-11-30 15:57:28 +0000 | [diff] [blame] | 249 | bool Initialize(Isolate* isolate); |
Steve Block | 44f0eee | 2011-05-26 01:26:41 +0100 | [diff] [blame] | 250 | |
Steve Block | d0582a6 | 2009-12-15 09:54:21 +0000 | [diff] [blame] | 251 | // The stack limit is split into a JavaScript and a C++ stack limit. These |
| 252 | // two are the same except when running on a simulator where the C++ and |
| 253 | // JavaScript stacks are separate. Each of the two stack limits have two |
| 254 | // values. The one eith the real_ prefix is the actual stack limit |
| 255 | // set for the VM. The one without the real_ prefix has the same value as |
| 256 | // the actual stack limit except when there is an interruption (e.g. debug |
| 257 | // break or preemption) in which case it is lowered to make stack checks |
| 258 | // fail. Both the generated code and the runtime system check against the |
| 259 | // one without the real_ prefix. |
| 260 | uintptr_t real_jslimit_; // Actual JavaScript stack limit set for the VM. |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 261 | uintptr_t jslimit_; |
Steve Block | d0582a6 | 2009-12-15 09:54:21 +0000 | [diff] [blame] | 262 | uintptr_t real_climit_; // Actual C++ stack limit set for the VM. |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 263 | uintptr_t climit_; |
Steve Block | d0582a6 | 2009-12-15 09:54:21 +0000 | [diff] [blame] | 264 | |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 265 | PostponeInterruptsScope* postpone_interrupts_; |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 266 | int interrupt_flags_; |
| 267 | }; |
| 268 | |
Steve Block | 44f0eee | 2011-05-26 01:26:41 +0100 | [diff] [blame] | 269 | // TODO(isolates): Technically this could be calculated directly from a |
| 270 | // pointer to StackGuard. |
| 271 | Isolate* isolate_; |
| 272 | ThreadLocal thread_local_; |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 273 | |
Steve Block | 44f0eee | 2011-05-26 01:26:41 +0100 | [diff] [blame] | 274 | friend class Isolate; |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 275 | friend class StackLimitCheck; |
| 276 | friend class PostponeInterruptsScope; |
Steve Block | 44f0eee | 2011-05-26 01:26:41 +0100 | [diff] [blame] | 277 | |
| 278 | DISALLOW_COPY_AND_ASSIGN(StackGuard); |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 279 | }; |
| 280 | |
Steve Block | a7e24c1 | 2009-10-30 11:49:00 +0000 | [diff] [blame] | 281 | } } // namespace v8::internal |
| 282 | |
| 283 | #endif // V8_EXECUTION_H_ |