Bug 1267557 part 3 - Define JS_SWEPT_CODE_PATTERN for mips. r=nbp a=ritu
authorHeiher <r@hev.cc>
Thu, 28 Apr 2016 13:38:14 +0200
changeset 332711 fa1e3821e0e483b702425ddea96238222bf85a76
parent 332710 2fa3f71011ccb7f8171af8295cc7ffbaa556333c
child 332712 cf28b66d74125b9de5de34191292cc1187fbd410
push id6048
push userkmoir@mozilla.com
push dateMon, 06 Jun 2016 19:02:08 +0000
treeherdermozilla-beta@46d72a56c57d [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersnbp, ritu
bugs1267557
milestone48.0a2
Bug 1267557 part 3 - Define JS_SWEPT_CODE_PATTERN for mips. r=nbp a=ritu
js/src/jsutil.h
--- a/js/src/jsutil.h
+++ b/js/src/jsutil.h
@@ -333,16 +333,18 @@ PodSet(T* aDst, T aSrc, size_t aNElem)
  * Ensure JS_SWEPT_CODE_PATTERN is a byte pattern that will crash immediately
  * when executed, so either an undefined instruction or an instruction that's
  * illegal in user mode.
  */
 #if defined(JS_CODEGEN_X86) || defined(JS_CODEGEN_X64) || defined(JS_CODEGEN_NONE)
 # define JS_SWEPT_CODE_PATTERN 0xED // IN instruction, crashes in user mode.
 #elif defined(JS_CODEGEN_ARM) || defined(JS_CODEGEN_ARM64)
 # define JS_SWEPT_CODE_PATTERN 0xA3 // undefined instruction
+#elif defined(JS_CODEGEN_MIPS32) || defined(JS_CODEGEN_MIPS64)
+# define JS_SWEPT_CODE_PATTERN 0x01 // undefined instruction
 #else
 # error "JS_SWEPT_CODE_PATTERN not defined for this platform"
 #endif
 
 static inline void*
 Poison(void* ptr, uint8_t value, size_t num)
 {
     static bool disablePoison = bool(getenv("JSGC_DISABLE_POISONING"));