OLD | NEW |
1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 235 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
246 inline void set_interrupt_limits(const ExecutionAccess& lock); | 246 inline void set_interrupt_limits(const ExecutionAccess& lock); |
247 | 247 |
248 // Reset limits to actual values. For example after handling interrupt. | 248 // Reset limits to actual values. For example after handling interrupt. |
249 // You should hold the ExecutionAccess lock when calling this method. | 249 // You should hold the ExecutionAccess lock when calling this method. |
250 inline void reset_limits(const ExecutionAccess& lock); | 250 inline void reset_limits(const ExecutionAccess& lock); |
251 | 251 |
252 // Enable or disable interrupts. | 252 // Enable or disable interrupts. |
253 void EnableInterrupts(); | 253 void EnableInterrupts(); |
254 void DisableInterrupts(); | 254 void DisableInterrupts(); |
255 | 255 |
256 #ifdef V8_TARGET_ARCH_X64 | 256 #if V8_TARGET_ARCH_X64 |
257 static const uintptr_t kInterruptLimit = V8_UINT64_C(0xfffffffffffffffe); | 257 static const uintptr_t kInterruptLimit = V8_UINT64_C(0xfffffffffffffffe); |
258 static const uintptr_t kIllegalLimit = V8_UINT64_C(0xfffffffffffffff8); | 258 static const uintptr_t kIllegalLimit = V8_UINT64_C(0xfffffffffffffff8); |
259 #else | 259 #else |
260 static const uintptr_t kInterruptLimit = 0xfffffffe; | 260 static const uintptr_t kInterruptLimit = 0xfffffffe; |
261 static const uintptr_t kIllegalLimit = 0xfffffff8; | 261 static const uintptr_t kIllegalLimit = 0xfffffff8; |
262 #endif | 262 #endif |
263 | 263 |
264 class ThreadLocal { | 264 class ThreadLocal { |
265 public: | 265 public: |
266 ThreadLocal() { Clear(); } | 266 ThreadLocal() { Clear(); } |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
299 friend class StackLimitCheck; | 299 friend class StackLimitCheck; |
300 friend class PostponeInterruptsScope; | 300 friend class PostponeInterruptsScope; |
301 | 301 |
302 DISALLOW_COPY_AND_ASSIGN(StackGuard); | 302 DISALLOW_COPY_AND_ASSIGN(StackGuard); |
303 }; | 303 }; |
304 | 304 |
305 | 305 |
306 } } // namespace v8::internal | 306 } } // namespace v8::internal |
307 | 307 |
308 #endif // V8_EXECUTION_H_ | 308 #endif // V8_EXECUTION_H_ |
OLD | NEW |