Index: src/mips/simulator-mips.h |
diff --git a/src/mips/simulator-mips.h b/src/mips/simulator-mips.h |
index 624d4acf8094936fbce5b2ad08eb9a3afe3af18d..0d1fe664b860a3ae356bc979d62102b49d7bf288 100644 |
--- a/src/mips/simulator-mips.h |
+++ b/src/mips/simulator-mips.h |
@@ -23,7 +23,7 @@ namespace v8 { |
namespace internal { |
// When running without a simulator we call the entry directly. |
-#define CALL_GENERATED_CODE(entry, p0, p1, p2, p3, p4) \ |
+#define CALL_GENERATED_CODE(isolate, entry, p0, p1, p2, p3, p4) \ |
entry(p0, p1, p2, p3, p4) |
typedef int (*mips_regexp_matcher)(String*, int, const byte*, const byte*, |
@@ -34,9 +34,10 @@ typedef int (*mips_regexp_matcher)(String*, int, const byte*, const byte*, |
// should act as a function matching the type arm_regexp_matcher. |
// The fifth argument is a dummy that reserves the space used for |
// the return address added by the ExitFrame in native calls. |
-#define CALL_GENERATED_REGEXP_CODE(entry, p0, p1, p2, p3, p4, p5, p6, p7, p8) \ |
- (FUNCTION_CAST<mips_regexp_matcher>(entry)( \ |
- p0, p1, p2, p3, NULL, p4, p5, p6, p7, p8)) |
+#define CALL_GENERATED_REGEXP_CODE(isolate, entry, p0, p1, p2, p3, p4, p5, p6, \ |
+ p7, p8) \ |
+ (FUNCTION_CAST<mips_regexp_matcher>(entry)(p0, p1, p2, p3, NULL, p4, p5, p6, \ |
+ p7, p8)) |
// The stack limit beyond which we will throw stack overflow errors in |
// generated code. Because generated code on mips uses the C stack, we |
@@ -48,11 +49,13 @@ class SimulatorStack : public v8::internal::AllStatic { |
return c_limit; |
} |
- static inline uintptr_t RegisterCTryCatch(uintptr_t try_catch_address) { |
+ static inline uintptr_t RegisterCTryCatch(Isolate* isolate, |
+ uintptr_t try_catch_address) { |
+ USE(isolate); |
return try_catch_address; |
} |
- static inline void UnregisterCTryCatch() { } |
+ static inline void UnregisterCTryCatch(Isolate* isolate) { USE(isolate); } |
}; |
} // namespace internal |
@@ -408,7 +411,8 @@ class Simulator { |
void SignalException(Exception e); |
// Runtime call support. |
- static void* RedirectExternalReference(void* external_function, |
+ static void* RedirectExternalReference(Isolate* isolate, |
+ void* external_function, |
ExternalReference::Type type); |
// Handle arguments and return value for runtime FP functions. |
@@ -464,13 +468,14 @@ class Simulator { |
// When running with the simulator transition into simulated execution at this |
// point. |
-#define CALL_GENERATED_CODE(entry, p0, p1, p2, p3, p4) \ |
- reinterpret_cast<Object*>(Simulator::current(Isolate::Current())->Call( \ |
+#define CALL_GENERATED_CODE(isolate, entry, p0, p1, p2, p3, p4) \ |
+ reinterpret_cast<Object*>(Simulator::current(isolate)->Call( \ |
FUNCTION_ADDR(entry), 5, p0, p1, p2, p3, p4)) |
-#define CALL_GENERATED_REGEXP_CODE(entry, p0, p1, p2, p3, p4, p5, p6, p7, p8) \ |
- Simulator::current(Isolate::Current())->Call( \ |
- entry, 10, p0, p1, p2, p3, NULL, p4, p5, p6, p7, p8) |
+#define CALL_GENERATED_REGEXP_CODE(isolate, entry, p0, p1, p2, p3, p4, p5, p6, \ |
+ p7, p8) \ |
+ Simulator::current(isolate) \ |
+ ->Call(entry, 10, p0, p1, p2, p3, NULL, p4, p5, p6, p7, p8) |
// The simulator has its own stack. Thus it has a different stack limit from |
@@ -484,13 +489,14 @@ class SimulatorStack : public v8::internal::AllStatic { |
return Simulator::current(isolate)->StackLimit(c_limit); |
} |
- static inline uintptr_t RegisterCTryCatch(uintptr_t try_catch_address) { |
- Simulator* sim = Simulator::current(Isolate::Current()); |
+ static inline uintptr_t RegisterCTryCatch(Isolate* isolate, |
+ uintptr_t try_catch_address) { |
+ Simulator* sim = Simulator::current(isolate); |
return sim->PushAddress(try_catch_address); |
} |
- static inline void UnregisterCTryCatch() { |
- Simulator::current(Isolate::Current())->PopAddress(); |
+ static inline void UnregisterCTryCatch(Isolate* isolate) { |
+ Simulator::current(isolate)->PopAddress(); |
} |
}; |