Disable IonMonkey on ARM (bug 671475, r=adrake).
authorMarty Rosenberg <mrosenberg@mozilla.com>
Thu, 14 Jul 2011 17:27:59 -0700
changeset 104913 bb12acebda0fd562e5fd8bea56527ae0331dddcd
parent 104912 42375f98039f65e60b7e3c8e23936c6b9f9eb95a
child 104914 4ec0e4e86693d053fd590702f1b38601bb0f0630
push id23447
push userdanderson@mozilla.com
push dateTue, 11 Sep 2012 17:34:27 +0000
treeherderautoland@fdfaef738a00 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersadrake
bugs671475
milestone8.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Disable IonMonkey on ARM (bug 671475, r=adrake).
js/src/Makefile.in
js/src/config/autoconf.mk.in
js/src/configure.in
js/src/jsapi.cpp
js/src/jsinterp.cpp
--- a/js/src/Makefile.in
+++ b/js/src/Makefile.in
@@ -356,16 +356,17 @@ CPPSRCS += 	MethodJIT.cpp \
 		PolyIC.cpp \
 		ImmutableSync.cpp \
 		InvokeHelpers.cpp \
 		Retcon.cpp \
 		TrampolineCompiler.cpp \
 		$(NULL)
 
 # Ion
+ifdef ENABLE_ION
 VPATH +=	$(srcdir)/ion
 VPATH +=	$(srcdir)/ion/shared
 
 CPPSRCS +=	MIR.cpp \
 		IonBuilder.cpp \
 		MIRGraph.cpp \
 		IonAnalysis.cpp \
 		IonLowering.cpp \
@@ -377,17 +378,17 @@ CPPSRCS +=	MIR.cpp \
 		JSONSpewer.cpp \
 		IonSpewer.cpp \
 		LICM.cpp \
 		ValueNumbering.cpp \
 		LinearScan.cpp \
 		MoveGroup.cpp \
 		CodeGenerator-shared.cpp \
 		$(NULL)
-
+endif #ENABLE_ION
 ifeq (86, $(findstring 86,$(TARGET_CPU)))
 CPPSRCS +=	CodeGenerator-x86-shared.cpp
 ifeq (x86_64, $(TARGET_CPU))
 ifdef _MSC_VER
 ASFILES +=	TrampolineMasmX64.asm
 endif
 ifeq ($(OS_ARCH),WINNT)
 ifdef GNU_CC
@@ -406,21 +407,23 @@ else
 VPATH +=	$(srcdir)/ion/x86
 CPPSRCS +=	Lowering-x86.cpp
 CPPSRCS +=	CodeGenerator-x86.cpp
 ifdef SOLARIS_SUNPRO_CXX
 ASFILES +=	TrampolineSUNWX86.s
 endif
 endif
 endif
+ifdef ENABLE_ION
 ifeq (arm, $(TARGET_CPU))
 #CPPSRCS		+= only_on_arm.cpp
 VPATH +=	$(srcdir)/ion/arm
 CPPSRCS +=	Lowering-arm.cpp
 endif
+endif #ENABLE_ION
 ifeq (sparc, $(findstring sparc,$(TARGET_CPU)))
 ASFILES +=	TrampolineSparc.s
 endif
 #
 # END enclude sources for the method JIT
 #############################################
 
 endif
--- a/js/src/config/autoconf.mk.in
+++ b/js/src/config/autoconf.mk.in
@@ -326,16 +326,17 @@ MACOS_SDK_DIR	= @MACOS_SDK_DIR@
 NEXT_ROOT	= @NEXT_ROOT@
 GCC_VERSION	= @GCC_VERSION@
 UNIVERSAL_BINARY= @UNIVERSAL_BINARY@
 HAVE_DTRACE= @HAVE_DTRACE@
 
 VISIBILITY_FLAGS = @VISIBILITY_FLAGS@
 WRAP_SYSTEM_INCLUDES = @WRAP_SYSTEM_INCLUDES@
 
+ENABLE_ION = @ENABLE_ION@
 ENABLE_TRACEJIT = @ENABLE_TRACEJIT@
 ENABLE_METHODJIT = @ENABLE_METHODJIT@
 NANOJIT_ARCH = @NANOJIT_ARCH@
 HAVE_ARM_SIMD= @HAVE_ARM_SIMD@
 
 JS_SHARED_LIBRARY = @JS_SHARED_LIBRARY@
 HAVE_LINUX_PERF_EVENT_H = @HAVE_LINUX_PERF_EVENT_H@
 
--- a/js/src/configure.in
+++ b/js/src/configure.in
@@ -2733,48 +2733,53 @@ fi
 
 dnl Configure JIT support
 
 case "$target" in
 i?86-*)
     ENABLE_TRACEJIT=1
     NANOJIT_ARCH=i386
     ENABLE_METHODJIT=1
+    ENABLE_ION=1
     ENABLE_MONOIC=1
     ENABLE_POLYIC=1
     ENABLE_POLYIC_TYPED_ARRAY=1
     AC_DEFINE(JS_CPU_X86)
     AC_DEFINE(JS_NUNBOX32)
     ;;
 x86_64*-*)
     ENABLE_TRACEJIT=1
     NANOJIT_ARCH=X64
     ENABLE_METHODJIT=1
+    ENABLE_ION=1
     ENABLE_MONOIC=1
     ENABLE_POLYIC=1
     ENABLE_POLYIC_TYPED_ARRAY=1
     AC_DEFINE(JS_CPU_X64)
     AC_DEFINE(JS_PUNBOX64)
     ;;
 arm*-*)
     ENABLE_TRACEJIT=1
     NANOJIT_ARCH=ARM
     ENABLE_METHODJIT=1
+dnl    ENABLE_ION=0
     ENABLE_MONOIC=1
     ENABLE_POLYIC=1
     AC_DEFINE(JS_CPU_ARM)
+dnl    ENABLE_POLYIC_TYPED_ARRAY=0
     AC_DEFINE(JS_NUNBOX32)
     ;;
 sparc*-*)
     ENABLE_TRACEJIT=1
     NANOJIT_ARCH=Sparc
     ENABLE_METHODJIT=1
     ENABLE_MONOIC=1
     ENABLE_POLYIC=1
     ENABLE_POLYIC_TYPED_ARRAY=1
+dnl ENABLE_ION=0
     AC_DEFINE(JS_CPU_SPARC)
     AC_DEFINE(JS_NUNBOX32)
     ;;
 esac
 
 MOZ_ARG_DISABLE_BOOL(methodjit,
 [  --disable-methodjit           Disable method JIT support],
   ENABLE_METHODJIT= )
@@ -2791,16 +2796,25 @@ MOZ_ARG_DISABLE_BOOL(tracejit,
 [  --disable-tracejit      Disable tracing JIT support],
   ENABLE_TRACEJIT=)
 
 MOZ_ARG_ENABLE_BOOL(methodjit-spew,
 [  --enable-methodjit-spew      Enable method JIT spew support],
   ENABLE_METHODJIT_SPEW=1,
   ENABLE_METHODJIT_SPEW= )
 
+MOZ_ARG_DISABLE_BOOL(polyic-typed-array,
+[  --disable-polyic-typed-array      Disable use of Typed Array PICs by JIT compiler],
+  ENABLE_POLYIC_TYPED_ARRAY=,
+  ENABLE_POLYIC_TYPED_ARRAY=1 )
+
+MOZ_ARG_DISABLE_BOOL(ion,
+[  --disable-ion      Disable use of IONMonkey compiler],
+  ENABLE_ION= )
+
 AC_SUBST(ENABLE_METHODJIT)
 
 if test "$ENABLE_METHODJIT"; then
     AC_DEFINE(JS_METHODJIT)
 fi
 
 if test "$ENABLE_MONOIC"; then
     AC_DEFINE(JS_MONOIC)
@@ -2813,16 +2827,22 @@ fi
 if test "$ENABLE_POLYIC_TYPED_ARRAY"; then
     AC_DEFINE(JS_POLYIC_TYPED_ARRAY)
 fi
 
 if test "$ENABLE_METHODJIT_SPEW"; then
     AC_DEFINE(JS_METHODJIT_SPEW)
 fi
 
+AC_SUBST(ENABLE_ION)
+
+if test "$ENABLE_ION"; then
+    AC_DEFINE(JS_ION)
+fi
+
 if test "$ENABLE_TRACEJIT"; then
 
 AC_DEFINE(FEATURE_NANOJIT)
 AC_DEFINE(JS_TRACER)
 
 case "$target" in
 i?86-*)
     AC_DEFINE(AVMPLUS_IA32)
--- a/js/src/jsapi.cpp
+++ b/js/src/jsapi.cpp
@@ -786,17 +786,17 @@ JS_NewRuntime(uint32 maxbytes)
 
         js_NewRuntimeWasCalled = JS_TRUE;
     }
 
     void *mem = OffTheBooks::calloc_(sizeof(JSRuntime));
     if (!mem)
         return NULL;
 
-#ifdef JS_METHODJIT
+#if defined(JS_METHODJIT) && defined(JS_ION)
     if (!ion::InitializeIon())
         return NULL;
 #endif
 
     JSRuntime *rt = new (mem) JSRuntime();
     if (!rt->init(maxbytes)) {
         JS_DestroyRuntime(rt);
         return NULL;
--- a/js/src/jsinterp.cpp
+++ b/js/src/jsinterp.cpp
@@ -4104,19 +4104,20 @@ BEGIN_CASE(JSOP_FUNAPPLY)
 
     /* Only create call object after frame is rooted. */
     if (fun->isHeavyweight() && !CreateFunCallObject(cx, regs.fp()))
         goto error;
 
     RESET_USE_METHODJIT();
     TRACE_0(EnterFrame);
 
+#ifdef JS_ION
     if (ion::Go(cx, script, regs.fp()))
         return true;
-
+#endif
 #ifdef JS_METHODJIT
     {
         /* Try to ensure methods are method JIT'd.  */
         mjit::CompileRequest request = (interpMode == JSINTERP_NORMAL)
                                        ? mjit::CompileRequest_Interpreter
                                        : mjit::CompileRequest_JIT;
         mjit::CompileStatus status = mjit::CanMethodJIT(cx, script, regs.fp(), request);
         if (status == mjit::Compile_Error)