diff options
author | Mike Pall <mike> | 2019-12-08 21:21:30 +0100 |
---|---|---|
committer | Mike Pall <mike> | 2019-12-08 21:21:30 +0100 |
commit | bd00094c3b50e193fb32aad79b7ea8ea6b78ed25 (patch) | |
tree | ce9a51d4a295e76a00f98351348bbbe03f2aa86d /src | |
parent | 70f4b15ee45a6137fe6b48b941faea79d72f7159 (diff) | |
download | luajit-bd00094c3b50e193fb32aad79b7ea8ea6b78ed25.tar.gz luajit-bd00094c3b50e193fb32aad79b7ea8ea6b78ed25.tar.bz2 luajit-bd00094c3b50e193fb32aad79b7ea8ea6b78ed25.zip |
x64: Enable LJ_GC64 mode by default.
Diffstat (limited to 'src')
-rw-r--r-- | src/Makefile | 4 | ||||
-rw-r--r-- | src/lj_arch.h | 2 | ||||
-rw-r--r-- | src/msvcbuild.bat | 12 |
3 files changed, 10 insertions, 8 deletions
diff --git a/src/Makefile b/src/Makefile index 71c284e2..ad80642b 100644 --- a/src/Makefile +++ b/src/Makefile | |||
@@ -110,8 +110,8 @@ XCFLAGS= | |||
110 | #XCFLAGS+= -DLUAJIT_NUMMODE=1 | 110 | #XCFLAGS+= -DLUAJIT_NUMMODE=1 |
111 | #XCFLAGS+= -DLUAJIT_NUMMODE=2 | 111 | #XCFLAGS+= -DLUAJIT_NUMMODE=2 |
112 | # | 112 | # |
113 | # Enable GC64 mode for x64. | 113 | # Disable LJ_GC64 mode for x64. |
114 | #XCFLAGS+= -DLUAJIT_ENABLE_GC64 | 114 | #XCFLAGS+= -DLUAJIT_DISABLE_GC64 |
115 | # | 115 | # |
116 | ############################################################################## | 116 | ############################################################################## |
117 | 117 | ||
diff --git a/src/lj_arch.h b/src/lj_arch.h index 31a11593..903d6c64 100644 --- a/src/lj_arch.h +++ b/src/lj_arch.h | |||
@@ -184,7 +184,7 @@ | |||
184 | #define LJ_TARGET_MASKROT 1 | 184 | #define LJ_TARGET_MASKROT 1 |
185 | #define LJ_TARGET_UNALIGNED 1 | 185 | #define LJ_TARGET_UNALIGNED 1 |
186 | #define LJ_ARCH_NUMMODE LJ_NUMMODE_SINGLE_DUAL | 186 | #define LJ_ARCH_NUMMODE LJ_NUMMODE_SINGLE_DUAL |
187 | #ifdef LUAJIT_ENABLE_GC64 | 187 | #ifndef LUAJIT_DISABLE_GC64 |
188 | #define LJ_TARGET_GC64 1 | 188 | #define LJ_TARGET_GC64 1 |
189 | #endif | 189 | #endif |
190 | 190 | ||
diff --git a/src/msvcbuild.bat b/src/msvcbuild.bat index 4abc461a..91de2b52 100644 --- a/src/msvcbuild.bat +++ b/src/msvcbuild.bat | |||
@@ -5,6 +5,7 @@ | |||
5 | @rem Then cd to this directory and run this script. Use the following | 5 | @rem Then cd to this directory and run this script. Use the following |
6 | @rem options (in order), if needed. The default is a dynamic release build. | 6 | @rem options (in order), if needed. The default is a dynamic release build. |
7 | @rem | 7 | @rem |
8 | @rem nogc64 disable LJ_GC64 mode for x64 | ||
8 | @rem debug emit debug symbols | 9 | @rem debug emit debug symbols |
9 | @rem amalg amalgamated build | 10 | @rem amalg amalgamated build |
10 | @rem static static linkage | 11 | @rem static static linkage |
@@ -20,7 +21,7 @@ | |||
20 | @set LJLIB=lib /nologo /nodefaultlib | 21 | @set LJLIB=lib /nologo /nodefaultlib |
21 | @set DASMDIR=..\dynasm | 22 | @set DASMDIR=..\dynasm |
22 | @set DASM=%DASMDIR%\dynasm.lua | 23 | @set DASM=%DASMDIR%\dynasm.lua |
23 | @set DASC=vm_x86.dasc | 24 | @set DASC=vm_x64.dasc |
24 | @set LJDLLNAME=lua51.dll | 25 | @set LJDLLNAME=lua51.dll |
25 | @set LJLIBNAME=lua51.lib | 26 | @set LJLIBNAME=lua51.lib |
26 | @set BUILDTYPE=release | 27 | @set BUILDTYPE=release |
@@ -37,15 +38,16 @@ if exist minilua.exe.manifest^ | |||
37 | @set LJARCH=x64 | 38 | @set LJARCH=x64 |
38 | @minilua | 39 | @minilua |
39 | @if errorlevel 8 goto :X64 | 40 | @if errorlevel 8 goto :X64 |
41 | @set DASC=vm_x86.dasc | ||
40 | @set DASMFLAGS=-D WIN -D JIT -D FFI | 42 | @set DASMFLAGS=-D WIN -D JIT -D FFI |
41 | @set LJARCH=x86 | 43 | @set LJARCH=x86 |
42 | @set LJCOMPILE=%LJCOMPILE% /arch:SSE2 | 44 | @set LJCOMPILE=%LJCOMPILE% /arch:SSE2 |
43 | :X64 | 45 | :X64 |
44 | @if "%1" neq "gc64" goto :NOGC64 | 46 | @if "%1" neq "nogc64" goto :GC64 |
45 | @shift | 47 | @shift |
46 | @set DASC=vm_x64.dasc | 48 | @set DASC=vm_x86.dasc |
47 | @set LJCOMPILE=%LJCOMPILE% /DLUAJIT_ENABLE_GC64 | 49 | @set LJCOMPILE=%LJCOMPILE% /DLUAJIT_DISABLE_GC64 |
48 | :NOGC64 | 50 | :GC64 |
49 | minilua %DASM% -LN %DASMFLAGS% -o host\buildvm_arch.h %DASC% | 51 | minilua %DASM% -LN %DASMFLAGS% -o host\buildvm_arch.h %DASC% |
50 | @if errorlevel 1 goto :BAD | 52 | @if errorlevel 1 goto :BAD |
51 | 53 | ||