Changeset View
Changeset View
Standalone View
Standalone View
www/firefox/files/patch-bug1532851
diff --git js/src/wasm/WasmSignalHandlers.cpp js/src/wasm/WasmSignalHandlers.cpp | diff --git js/src/wasm/WasmSignalHandlers.cpp js/src/wasm/WasmSignalHandlers.cpp | ||||
index fc49f361d82a..636537f84786 100644 | index fc49f361d82a..636537f84786 100644 | ||||
--- js/src/wasm/WasmSignalHandlers.cpp | --- js/src/wasm/WasmSignalHandlers.cpp | ||||
+++ js/src/wasm/WasmSignalHandlers.cpp | +++ js/src/wasm/WasmSignalHandlers.cpp | ||||
@@ -102,6 +102,11 @@ using mozilla::DebugOnly; | @@ -103,6 +103,11 @@ using mozilla::DebugOnly; | ||||
#define EPC_sig(p) ((p)->sc_pc) | # define EPC_sig(p) ((p)->sc_pc) | ||||
#define RFP_sig(p) ((p)->sc_regs[30]) | # define RFP_sig(p) ((p)->sc_regs[30]) | ||||
#endif | # endif | ||||
+#if defined(__ppc64__) || defined(__PPC64__) || defined(__ppc64le__) || \ | +# if defined(__ppc64__) || defined(__PPC64__) || defined(__ppc64le__) || \ | ||||
+ defined(__PPC64LE__) | + defined(__PPC64LE__) | ||||
+#define R01_sig(p) ((p)->sc_frame.fixreg[1]) | +# define R01_sig(p) ((p)->sc_frame.fixreg[1]) | ||||
+#define R32_sig(p) ((p)->sc_frame.srr0) | +# define R32_sig(p) ((p)->sc_frame.srr0) | ||||
+#endif | +# endif | ||||
#elif defined(__linux__) || defined(__sun) | #elif defined(__linux__) || defined(__sun) | ||||
#if defined(__linux__) | # if defined(__linux__) | ||||
#define EIP_sig(p) ((p)->uc_mcontext.gregs[REG_EIP]) | # define EIP_sig(p) ((p)->uc_mcontext.gregs[REG_EIP]) | ||||
@@ -169,6 +174,11 @@ using mozilla::DebugOnly; | @@ -170,6 +175,11 @@ using mozilla::DebugOnly; | ||||
#define EPC_sig(p) ((p)->uc_mcontext.__gregs[_REG_EPC]) | # define EPC_sig(p) ((p)->uc_mcontext.__gregs[_REG_EPC]) | ||||
#define RFP_sig(p) ((p)->uc_mcontext.__gregs[_REG_S8]) | # define RFP_sig(p) ((p)->uc_mcontext.__gregs[_REG_S8]) | ||||
#endif | # endif | ||||
+#if defined(__ppc64__) || defined(__PPC64__) || defined(__ppc64le__) || \ | +# if defined(__ppc64__) || defined(__PPC64__) || defined(__ppc64le__) || \ | ||||
+ defined(__PPC64LE__) | + defined(__PPC64LE__) | ||||
+#define R01_sig(p) ((p)->uc_mcontext.__gregs[_REG_R1]) | +# define R01_sig(p) ((p)->uc_mcontext.__gregs[_REG_R1]) | ||||
+#define R32_sig(p) ((p)->uc_mcontext.__gregs[_REG_PC]) | +# define R32_sig(p) ((p)->uc_mcontext.__gregs[_REG_PC]) | ||||
+#endif | +# endif | ||||
#elif defined(__DragonFly__) || defined(__FreeBSD__) || \ | #elif defined(__DragonFly__) || defined(__FreeBSD__) || \ | ||||
defined(__FreeBSD_kernel__) | defined(__FreeBSD_kernel__) | ||||
#define EIP_sig(p) ((p)->uc_mcontext.mc_eip) | # define EIP_sig(p) ((p)->uc_mcontext.mc_eip) | ||||
@@ -197,6 +207,11 @@ using mozilla::DebugOnly; | @@ -199,6 +209,11 @@ using mozilla::DebugOnly; | ||||
#if defined(__FreeBSD__) && defined(__mips__) | |||||
#define EPC_sig(p) ((p)->uc_mcontext.mc_pc) | # define EPC_sig(p) ((p)->uc_mcontext.mc_pc) | ||||
#define RFP_sig(p) ((p)->uc_mcontext.mc_regs[30]) | # define RFP_sig(p) ((p)->uc_mcontext.mc_regs[30]) | ||||
+#endif | # endif | ||||
+#if defined(__FreeBSD__) && (defined(__ppc64__) || defined(__PPC64__) || \ | +# if defined(__FreeBSD__) && (defined(__ppc64__) || defined(__PPC64__) || \ | ||||
+ defined(__ppc64le__) || defined(__PPC64LE__)) | + defined(__ppc64le__) || defined(__PPC64LE__)) | ||||
+#define R01_sig(p) ((p)->uc_mcontext.mc_gpr[1]) | +# define R01_sig(p) ((p)->uc_mcontext.mc_gpr[1]) | ||||
+#define R32_sig(p) ((p)->uc_mcontext.mc_srr0) | +# define R32_sig(p) ((p)->uc_mcontext.mc_srr0) | ||||
#endif | +# endif | ||||
#elif defined(XP_DARWIN) | #elif defined(XP_DARWIN) | ||||
#define EIP_sig(p) ((p)->thread.uts.ts32.__eip) | # define EIP_sig(p) ((p)->thread.uts.ts32.__eip) | ||||
# define EBP_sig(p) ((p)->thread.uts.ts32.__ebp) |