Bug 463172 - add a --disable-jit option, r=ted

This commit is contained in:
Benjamin Smedberg 2009-01-13 11:34:51 -05:00
parent 469b7ca86d
commit fec9af26d0
3 changed files with 57 additions and 27 deletions

View File

@ -102,33 +102,6 @@ ifndef JS_STATIC_BUILD
FORCE_SHARED_LIB = 1
endif
ifeq (86,$(findstring 86,$(OS_TEST)))
ifeq (64,$(findstring 64,$(OS_TEST)))
else
DEFINES += -DAVMPLUS_IA32
NANOJIT_ARCH = i386
ENABLE_JIT = 1
endif
endif
ifeq (arm,$(findstring arm,$(OS_TEST)))
DEFINES += -DAVMPLUS_ARM
NANOJIT_ARCH = ARM
ENABLE_JIT = 1
endif
ifneq (,$(filter Linux Darwin SunOS FreeBSD,$(OS_ARCH)))
DEFINES += -DAVMPLUS_UNIX
endif
ifeq ($(OS_ARCH),Linux)
DEFINES += -DAVMPLUS_LINUX
endif
ifeq ($(OS_ARCH),WINNT)
DEFINES += -DAVMPLUS_WIN32
endif
VPATH = $(srcdir)
CPPSRCS = \

View File

@ -351,4 +351,6 @@ HAVE_DTRACE= @HAVE_DTRACE@
VISIBILITY_FLAGS = @VISIBILITY_FLAGS@
WRAP_SYSTEM_INCLUDES = @WRAP_SYSTEM_INCLUDES@
ENABLE_JIT = @ENABLE_JIT@
NANOJIT_ARCH = @NANOJIT_ARCH@
HAVE_ARM_SIMD= @HAVE_ARM_SIMD@

View File

@ -2872,6 +2872,61 @@ if test ! "$GNU_CXX"; then
fi
AC_CHECK_LIB(socket, socket)
dnl Configure JIT support
case "$target" in
i?86-*)
ENABLE_JIT=1
NANOJIT_ARCH=i386
;;
arm*-*)
ENABLE_JIT=1
NANOJIT_ARCH=ARM
;;
esac
MOZ_ARG_DISABLE_BOOL(jit,
[ --disable-jit Disable JIT support],
ENABLE_JIT=)
if test "$ENABLE_JIT"; then
case "$target" in
i?86-*)
AC_DEFINE(AVMPLUS_IA32)
;;
arm*-*)
AC_DEFINE(AVMPLUS_ARM)
;;
esac
case "$target_os" in
linux*)
AC_DEFINE(AVMPLUS_UNIX)
AC_DEFINE(AVMPLUS_LINUX)
;;
darwin*)
AC_DEFINE(AVMPLUS_UNIX)
;;
solaris*)
AC_DEFINE(AVMPLUS_UNIX)
;;
freebsd*|kfreebsd*)
AC_DEFINE(AVMPLUS_UNIX)
;;
*cygwin*|*mingw*|*mks*|*msvc*|*wince)
AC_DEFINE(AVMPLUS_WIN32)
;;
*)
AC_MSG_ERROR([Unrecognized nanojit platform])
esac
fi # ENABLE_JIT
AC_SUBST(ENABLE_JIT)
AC_SUBST(NANOJIT_ARCH)
dnl Enable VFP support on ARM
MOZ_ARG_DISABLE_BOOL(arm-vfp,
[ --disable-arm-vfp Disable ARM VFP instructions in JavaScript JIT],