Closed Bug 693300 Opened 13 years ago Closed 13 years ago

float patch queue does not compile on linux32

Categories

(Tamarin Graveyard :: Virtual Machine, defect, P2)

x86
Linux
defect

Tracking

(Not tracked)

VERIFIED FIXED
Q2 12 - Cyril

People

(Reporter: brbaker, Assigned: virgilp)

References

Details

Current patch queue (170:b34841678e73) does not compile on linux 32. 

In file included from ../platform/unix/unix-platform.h:163,
                 from ../VMPI/VMPI.h:85,
                 from ../VMPI/PosixSpecificUtils.cpp:41:
/usr/local/lib/gcc/x86_64-unknown-linux-gnu/4.3.6/include/xmmintrin.h:35:3: error: #error "SSE instruction set not enabled"

The sse instruction set must be enabled for the compiler by adding the gcc switch -msse 


--- a/configure.py	Fri Oct 07 08:18:00 2011 -0400
+++ b/configure.py	Mon Oct 10 10:19:11 2011 -0400
@@ -137,7 +137,7 @@
 APP_CPPFLAGS = "-DAVMSHELL_BUILD "
 APP_CXXFLAGS = ""
 APP_CFLAGS = ""
-OPT_CXXFLAGS = "-O3 "
+OPT_CXXFLAGS = "-O3 -msse"
 OPT_CPPFLAGS = ""
 DEBUG_CPPFLAGS = "-DDEBUG -D_DEBUG "
 DEBUG_CXXFLAGS = ""

However once you get the compiler past this issue you run into the following error:


In file included from ../core/../nanojit/nanojit.h:364,
                 from ../core/LirHelper.h:45,
                 from ../core/CodegenLIR.h:45,
                 from ../core/AvmCore.cpp:46:
../core/../nanojit/Containers.h: In function ‘bool nanojit::keysEqual(K, K) [with K = float __vector__]’:
../core/../nanojit/Containers.h:260: error: ‘_mm_castps_si128’ was not declared in this scope
../core/../nanojit/Containers.h:260: error: ‘_mm_movemask_epi8’ was not declared in this scope
Flags: flashplayer-triage+
Flags: flashplayer-qrb?
Flags: flashplayer-bug-
The switch really should be -msse2 I believe, which results in a linking error:


shell/../extensions/SelftestExec.o: In function `avmplus::ST_vmpi_threads::CASTest::workerThreadEntry()':
SelftestExec.cpp:(.text._ZN7avmplus15ST_vmpi_threads7CASTest17workerThreadEntryEv[avmplus::ST_vmpi_threads::CASTest::workerThreadEntry()]+0x32): undefined reference to `__sync_bool_compare_and_swap_4'
This error is probably a little more interesting (compiled with selftests disabled)

./libvmbase.a(VMThread.o): In function `vmbase::VMThread::VMThread(vmbase::Runnable*)':
VMThread.cpp:(.text+0xb43): undefined reference to `__sync_add_and_fetch_4'
./libvmbase.a(VMThread.o): In function `vmbase::VMThread::VMThread(vmbase::Runnable*)':
VMThread.cpp:(.text+0xc63): undefined reference to `__sync_add_and_fetch_4'
./libvmbase.a(VMThread.o): In function `vmbase::VMThread::VMThread()':
VMThread.cpp:(.text+0xf00): undefined reference to `__sync_add_and_fetch_4'
./libvmbase.a(VMThread.o): In function `vmbase::VMThread::VMThread()':
VMThread.cpp:(.text+0x1020): undefined reference to `__sync_add_and_fetch_4'
Seems as though when compiling linux32 on a 64bit platform we need to include the following gcc/g++ switches:

-march=i686 -mss2e
This currently is not blocking the autobuild system as I have tweaked the jenkins config to pass these 2 switches into gcc/g++
Flags: flashplayer-qrb?
Flags: flashplayer-qrb+
Flags: flashplayer-injection+
Priority: -- → P2
Target Milestone: --- → Q2 12 - Cyril
This is resolved in bug-615489.floatClass.build.diff (184:fde0c16e4d0a)
Status: ASSIGNED → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.