Patches for Linux Makefile

A place to discuss everything related to Newton Dynamics.

Moderators: Sascha Willems, walaber

Patches for Linux Makefile

Postby carli2 » Thu May 31, 2012 4:25 am

The following patch creates a proper libNewton.so and also updates the file list.
Core300 still crashes on world creation, but this patch is a step into the right direction of getting newton running.

Code: Select all
Index: linux64/makefile
===================================================================
--- linux64/makefile   (revision 2050)
+++ linux64/makefile   (working copy)
@@ -1,15 +1,15 @@
 #*******************************************************
 #
-# Newton game dynamics
+# Newton game dynamics
 # copy right by Julio Jerez 2002 - 2012
 #
 #*******************************************************
 #
-# Generic makefile
-# this make file generate the libraries:
+# Generic makefile
+# this make file generate the libraries:
 # dg, physics, and newton
 #
-#******************************************************* 
+#*******************************************************
 
 
 # ******************************************************
@@ -52,7 +52,7 @@
    $(DG_PATH)dgThreadHive.cpp \
    $(DG_PATH)dgTree.cpp \
    $(DG_PATH)dgTypes.cpp \
-   $(DG_PATH)dgWorkerThread.cpp
+   $(DG_PATH)dgThreadHive.cpp
 
 
 # ******************************************************
@@ -77,12 +77,11 @@
    $(DG_PHYSICS_PATH)dgCollisionCone.cpp \
    $(DG_PHYSICS_PATH)dgCollisionConvex.cpp \
    $(DG_PHYSICS_PATH)dgCollisionConvexHull.cpp \
-   $(DG_PHYSICS_PATH)dgCollisionConvexModifier.cpp \
    $(DG_PHYSICS_PATH)dgCollisionConvexPolygon.cpp \
    $(DG_PHYSICS_PATH)dgCollision.cpp \
    $(DG_PHYSICS_PATH)dgCollisionCylinder.cpp \
    $(DG_PHYSICS_PATH)dgCollisionDeformableMesh.cpp \
-   $(DG_PHYSICS_PATH)dgCollisionEllipse.cpp \
+   $(DG_PHYSICS_PATH)dgCollisionCone.cpp \
    $(DG_PHYSICS_PATH)dgCollisionHeightField.cpp \
    $(DG_PHYSICS_PATH)dgCollisionInstance.cpp \
    $(DG_PHYSICS_PATH)dgCollisionMesh.cpp \
@@ -116,7 +115,7 @@
 
 # ******************************************************
 #
-# mesh gemotry
+# mesh gemotry
 #
 # ******************************************************
 DG_INCLUDED_MESH_PATH = ../../source/meshUtil
@@ -164,7 +163,7 @@
 COMPILER = gcc
 
 # Linux options    gcc 4.4.2
-#CPU_FLAGS = -O0 -fPIC  -g
+#CPU_FLAGS = -O0 -fPIC  -g
 #CPU_FLAGS = -O2 -fsingle-precision-constant
 #CPU_FLAGS = -O2 -fpic -msse -msse4.1 -mfpmath=sse -ffloat-store -ffast-math -freciprocal-math -funsafe-math-optimizations -fsingle-precision-constant
 CPU_FLAGS = -O3 -fpic -msse -msse4.1 -mfpmath=sse -ffloat-store -ffast-math -freciprocal-math -funsafe-math-optimizations -fsingle-precision-constant
@@ -192,6 +191,8 @@
    cp libNewton.a ../../../packages/linux64/libNewton.a
    cp ../../source/newton/Newton.h ../../../packages/linux64/Newton.h
    cp ../../source/ai/NewtonAI.h ../../../packages/linux64/NewtonAI.h
-   gcc -shared -Wl,-soname,libNewton.so $? -o libNewton.so
+   sh -c "mkdir x; cd x; ar x ../libNewton.a"
+   gcc -shared -Wl,-soname,libNewton.so x/*.o -o libNewton.so
+   rm -r x
    cp libNewton.so ../../../packages/linux64/libNewton.so
    #sudo cp libNewton.so /usr/lib
carli2
 
Posts: 157
Joined: Thu Nov 10, 2011 1:53 pm

Re: Patches for Linux Makefile

Postby Julio Jerez » Thu May 31, 2012 8:03 am

I just made a define to disblae threading on all no window platfoprm until I debug the code.
if you sync, it shoul work in all platforms.
Julio Jerez
Moderator
Moderator
 
Posts: 12426
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: Patches for Linux Makefile

Postby carli2 » Thu May 31, 2012 10:49 am

What about the makefile changes? (I'd like to see fixes in trunk so I can keep my newton in sync)
carli2
 
Posts: 157
Joined: Thu Nov 10, 2011 1:53 pm

Re: Patches for Linux Makefile

Postby carli2 » Thu May 31, 2012 10:56 am

Code: Select all
Program received signal SIGILL, Illegal instruction.
0x00007ffff6647af2 in dgPolyhedraMassProperties::AddCGFace(int, dgVector const*) ()
   from src/libNewton.so
(gdb) backtrace
#0  0x00007ffff6647af2 in dgPolyhedraMassProperties::AddCGFace(int, dgVector const*) ()
   from src/libNewton.so
#1  0x00007ffff6541419 in dgCollisionConvex::SetVolumeAndCG() () from src/libNewton.so
#2  0x00007ffff6581d74 in dgCollisionSphere::Init(float, dgMemoryAllocator*) () from src/libNewton.so
#3  0x00007ffff65822e3 in dgCollisionSphere::dgCollisionSphere(dgMemoryAllocator*, unsigned int, float) () from src/libNewton.so
#4  0x00007ffff66553d8 in dgWorld::dgWorld(dgMemoryAllocator*) () from src/libNewton.so
#5  0x00007ffff64eaeeb in Newton::Newton(float, dgMemoryAllocator*) () from src/libNewton.so
#6  0x00007ffff64df036 in NewtonCreate () from src/libNewton.so
carli2
 
Posts: 157
Joined: Thu Nov 10, 2011 1:53 pm

Re: Patches for Linux Makefile

Postby Julio Jerez » Thu May 31, 2012 11:01 am

I see that the patch make a dll, I had it like that before and people asked to make a static library.
when you tyr to intall .so file in systme folder peopel thoink tehy is some kind of hoax or conspiracy, so I decided to let the end user to make the .so if they like.

I will add the patch by I will not set teh make file to generare .so file

also this weekend I will see why it crashes in that line.

Oh I see you are doing it right, ok I will apply the patch. But liek I say peopel do niot reallik like when file are installed. I do not knwo if thsi is only with Newton or it is a general linux world thing.
Julio Jerez
Moderator
Moderator
 
Posts: 12426
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: Patches for Linux Makefile

Postby Julio Jerez » Thu May 31, 2012 11:11 am

I saved the tex with the .patch extension
but when I try to apply teh patch I get unknown symple at line 5.
I always get these errors with patches that are submited like that.
can you post the .ptch as a zip file, so that I can apply it directly?
Julio Jerez
Moderator
Moderator
 
Posts: 12426
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: Patches for Linux Makefile

Postby carli2 » Tue Jun 05, 2012 2:43 am

Julio Jerez wrote:Oh I see you are doing it right, ok I will apply the patch. But liek I say peopel do niot reallik like when file are installed. I do not knwo if thsi is only with Newton or it is a general linux world thing.


In this case, ppl can link statically. When the compilation pass creates both, static and dynamic library, the developer can choose which to take (the way you create the .so file is not correct due to the symbol list is empty)

I saved the tex with the .patch extension
but when I try to apply teh patch I get unknown symple at line 5.
I always get these errors with patches that are submited like that.
can you post the .ptch as a zip file, so that I can apply it directly?


The patch is not really big, so you would be faster when applying it manually (i picked out the relevant parts for you)
Code: Select all
@@ -52,7 +52,7 @@
   $(DG_PATH)dgThreadHive.cpp \
   $(DG_PATH)dgTree.cpp \
   $(DG_PATH)dgTypes.cpp \
-   $(DG_PATH)dgWorkerThread.cpp
+   $(DG_PATH)dgThreadHive.cpp


# ******************************************************
@@ -77,12 +77,11 @@
   $(DG_PHYSICS_PATH)dgCollisionCone.cpp \
   $(DG_PHYSICS_PATH)dgCollisionConvex.cpp \
   $(DG_PHYSICS_PATH)dgCollisionConvexHull.cpp \
-   $(DG_PHYSICS_PATH)dgCollisionConvexModifier.cpp \
   $(DG_PHYSICS_PATH)dgCollisionConvexPolygon.cpp \
   $(DG_PHYSICS_PATH)dgCollision.cpp \
   $(DG_PHYSICS_PATH)dgCollisionCylinder.cpp \
   $(DG_PHYSICS_PATH)dgCollisionDeformableMesh.cpp \
-   $(DG_PHYSICS_PATH)dgCollisionEllipse.cpp \
+   $(DG_PHYSICS_PATH)dgCollisionCone.cpp \
   $(DG_PHYSICS_PATH)dgCollisionHeightField.cpp \
   $(DG_PHYSICS_PATH)dgCollisionInstance.cpp \
   $(DG_PHYSICS_PATH)dgCollisionMesh.cpp \
@@ -192,6 +191,8 @@
   cp libNewton.a ../../../packages/linux64/libNewton.a
   cp ../../source/newton/Newton.h ../../../packages/linux64/Newton.h
   cp ../../source/ai/NewtonAI.h ../../../packages/linux64/NewtonAI.h
-   gcc -shared -Wl,-soname,libNewton.so $? -o libNewton.so
+   sh -c "mkdir x; cd x; ar x ../libNewton.a"
+   gcc -shared -Wl,-soname,libNewton.so x/*.o -o libNewton.so
+   rm -r x
   cp libNewton.so ../../../packages/linux64/libNewton.so
   #sudo cp libNewton.so /usr/lib
carli2
 
Posts: 157
Joined: Thu Nov 10, 2011 1:53 pm

Re: Patches for Linux Makefile

Postby Julio Jerez » Tue Jun 05, 2012 8:09 am

before we try anything a forum user by the name d.l.i.w was working on linux build he had it running with everything. here is a quote and an image of the Linux build
d.l.i.w wrote:
Now even the "demoSandbox" compiles well and runs (!):
Image
There are only some minor issues... :D
(description not right, camera movement with keyboard / mouse doesn't work, ...)

Some demos crash the application with SIGSEV, if it would help you, I could send you some backtraces.

They look like:
Code: Select all
Program received signal SIGSEGV, Segmentation fault.
0x000000000044c34d in GetWorkingFileName (name=0x6651fc "NewtonSky0001.tga", outPathName=0x7fffffffc5e0 "")
    at ../../sdkDemos/toolBox/toolbox_stdafx.cpp:129
129             ptr [0] = 0;

(But this error is already solved - in this patch... :lol: )

d.l.i.w

could you sinc to the latest version and so that commonalitie and conflict are resolve, ther are many chnged to teh make files, no just teh newton libraries, but also the Packages makefiles
Julio Jerez
Moderator
Moderator
 
Posts: 12426
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: Patches for Linux Makefile

Postby carli2 » Thu Jun 07, 2012 4:33 am

I built from a cleaned, upstream svn repos and got:
Code: Select all
Program received signal SIGILL, Illegal instruction.
0x00007ffff6520aa2 in dgPolyhedraMassProperties::AddCGFace(int, dgVector const*) () from src/libNewton.so
(gdb) backtrace
#0  0x00007ffff6520aa2 in dgPolyhedraMassProperties::AddCGFace(int, dgVector const*) ()
   from src/libNewton.so
#1  0x00007ffff65733a9 in dgCollisionConvex::SetVolumeAndCG() () from src/libNewton.so
#2  0x00007ffff65b4024 in dgCollisionSphere::Init(float, dgMemoryAllocator*) () from src/libNewton.so
#3  0x00007ffff65b4593 in dgCollisionSphere::dgCollisionSphere(dgMemoryAllocator*, unsigned int, float) ()
   from src/libNewton.so
#4  0x00007ffff6623658 in dgWorld::dgWorld(dgMemoryAllocator*) () from src/libNewton.so
#5  0x00007ffff6672cbb in Newton::Newton(float, dgMemoryAllocator*) () from src/libNewton.so
#6  0x00007ffff6667536 in NewtonCreate () from src/libNewton.so
carli2
 
Posts: 157
Joined: Thu Nov 10, 2011 1:53 pm

Re: Patches for Linux Makefile

Postby d.l.i.w » Thu Jun 07, 2012 5:58 am

I just compiled SVN Rev. 2085, both the library and the demoSandbox, and it just works (Linux64)...
[gcc (SUSE Linux) 4.6.2, kernel: 3.1.10-1.9-desktop]

But I only tested with the demoSandbox (statically linked); I see that there is something wrong with the shared library libNewton.so

If you change the makefile as you suggested, does it work then?
Code: Select all
-   gcc -shared -Wl,-soname,libNewton.so $? -o libNewton.so
+   sh -c "mkdir x; cd x; ar x ../libNewton.a"
+   gcc -shared -Wl,-soname,libNewton.so x/*.o -o libNewton.so
+   rm -r x


If I find time, I will hack together a demo (linked against the shared library) and test...
Julio currently doesn't have a Linux machine to test, so he probably won't be able to help...
d.l.i.w
 
Posts: 81
Joined: Mon Sep 26, 2011 4:35 am

Re: Patches for Linux Makefile

Postby carli2 » Sat Jun 09, 2012 4:47 pm

d.l.i.w wrote:I just compiled SVN Rev. 2085, both the library and the demoSandbox, and it just works (Linux64)...
[gcc (SUSE Linux) 4.6.2, kernel: 3.1.10-1.9-desktop]

But I only tested with the demoSandbox (statically linked); I see that there is something wrong with the shared library libNewton.so

If you change the makefile as you suggested, does it work then?
Code: Select all
-   gcc -shared -Wl,-soname,libNewton.so $? -o libNewton.so
+   sh -c "mkdir x; cd x; ar x ../libNewton.a"
+   gcc -shared -Wl,-soname,libNewton.so x/*.o -o libNewton.so
+   rm -r x


If I find time, I will hack together a demo (linked against the shared library) and test...
Julio currently doesn't have a Linux machine to test, so he probably won't be able to help...


I tried the most simple Newton program now:
#include "../../../source/newton/Newton.h"

int main() {
NewtonCreate();
return 0;
}


(Compiled with `gcc test.o -lNewton -L. -lstdc++ -lpthread`, using libNewton.a [other libs had more linker errors, so i did not try further])

Backtrace of that program:

Code: Select all
Reading symbols from /home/carli/sources/newton/coreLibrary_300/projets/linux64/test/a.out...(no debugging symbols found)...done.
(gdb) r
Starting program: /home/carli/sources/newton/coreLibrary_300/projets/linux64/test/a.out
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[New Thread 0x7ffff6fef700 (LWP 7218)]
[New Thread 0x7ffff67ee700 (LWP 7219)]

Program received signal SIGILL, Illegal instruction.
0x00000000004f53e2 in dgPolyhedraMassProperties::AddCGFace(int, dgVector const*) ()
(gdb) backtrace
#0  0x00000000004f53e2 in dgPolyhedraMassProperties::AddCGFace(int, dgVector const*) ()
#1  0x000000000050d849 in dgCollisionConvex::SetVolumeAndCG() ()
#2  0x000000000047aba4 in dgCollisionSphere::Init(float, dgMemoryAllocator*) ()
#3  0x000000000047b113 in dgCollisionSphere::dgCollisionSphere(dgMemoryAllocator*, unsigned int, float)
    ()
#4  0x000000000049b948 in dgWorld::dgWorld(dgMemoryAllocator*) ()
#5  0x00000000004133eb in Newton::Newton(float, dgMemoryAllocator*) ()
#6  0x0000000000407976 in NewtonCreate ()
#7  0x00000000004078dd in main ()


My CPU:
Code: Select all
$ cat /proc/cpuinfo
processor   : 0
vendor_id   : AuthenticAMD
cpu family   : 16
model      : 5
model name   : AMD Phenom(tm) II X4 840 Processor
stepping   : 3
microcode   : 0x10000b6
cpu MHz      : 800.000
cache size   : 512 KB
physical id   : 0
siblings   : 4
core id      : 0
cpu cores   : 4
apicid      : 0
initial apicid   : 0
fpu      : yes
fpu_exception   : yes
cpuid level   : 5
wp      : yes
flags      : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx mmxext fxsr_opt pdpe1gb rdtscp lm 3dnowext 3dnow constant_tsc rep_good nopl nonstop_tsc extd_apicid pni monitor cx16 popcnt lahf_lm cmp_legacy svm extapic cr8_legacy abm sse4a misalignsse 3dnowprefetch osvw ibs skinit wdt npt lbrv svm_lock nrip_save
bogomips   : 6429.18
TLB size   : 1024 4K pages
clflush size   : 64
cache_alignment   : 64
address sizes   : 48 bits physical, 48 bits virtual
power management: ts ttp tm stc 100mhzsteps hwpstate

processor   : 1
vendor_id   : AuthenticAMD
cpu family   : 16
model      : 5
model name   : AMD Phenom(tm) II X4 840 Processor
stepping   : 3
microcode   : 0x10000b6
cpu MHz      : 800.000
cache size   : 512 KB
physical id   : 0
siblings   : 4
core id      : 1
cpu cores   : 4
apicid      : 1
initial apicid   : 1
fpu      : yes
fpu_exception   : yes
cpuid level   : 5
wp      : yes
flags      : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx mmxext fxsr_opt pdpe1gb rdtscp lm 3dnowext 3dnow constant_tsc rep_good nopl nonstop_tsc extd_apicid pni monitor cx16 popcnt lahf_lm cmp_legacy svm extapic cr8_legacy abm sse4a misalignsse 3dnowprefetch osvw ibs skinit wdt npt lbrv svm_lock nrip_save
bogomips   : 6429.20
TLB size   : 1024 4K pages
clflush size   : 64
cache_alignment   : 64
address sizes   : 48 bits physical, 48 bits virtual
power management: ts ttp tm stc 100mhzsteps hwpstate

processor   : 2
vendor_id   : AuthenticAMD
cpu family   : 16
model      : 5
model name   : AMD Phenom(tm) II X4 840 Processor
stepping   : 3
microcode   : 0x10000b6
cpu MHz      : 800.000
cache size   : 512 KB
physical id   : 0
siblings   : 4
core id      : 2
cpu cores   : 4
apicid      : 2
initial apicid   : 2
fpu      : yes
fpu_exception   : yes
cpuid level   : 5
wp      : yes
flags      : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx mmxext fxsr_opt pdpe1gb rdtscp lm 3dnowext 3dnow constant_tsc rep_good nopl nonstop_tsc extd_apicid pni monitor cx16 popcnt lahf_lm cmp_legacy svm extapic cr8_legacy abm sse4a misalignsse 3dnowprefetch osvw ibs skinit wdt npt lbrv svm_lock nrip_save
bogomips   : 6429.19
TLB size   : 1024 4K pages
clflush size   : 64
cache_alignment   : 64
address sizes   : 48 bits physical, 48 bits virtual
power management: ts ttp tm stc 100mhzsteps hwpstate

processor   : 3
vendor_id   : AuthenticAMD
cpu family   : 16
model      : 5
model name   : AMD Phenom(tm) II X4 840 Processor
stepping   : 3
microcode   : 0x10000b6
cpu MHz      : 800.000
cache size   : 512 KB
physical id   : 0
siblings   : 4
core id      : 3
cpu cores   : 4
apicid      : 3
initial apicid   : 3
fpu      : yes
fpu_exception   : yes
cpuid level   : 5
wp      : yes
flags      : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx mmxext fxsr_opt pdpe1gb rdtscp lm 3dnowext 3dnow constant_tsc rep_good nopl nonstop_tsc extd_apicid pni monitor cx16 popcnt lahf_lm cmp_legacy svm extapic cr8_legacy abm sse4a misalignsse 3dnowprefetch osvw ibs skinit wdt npt lbrv svm_lock nrip_save
bogomips   : 6429.24
TLB size   : 1024 4K pages
clflush size   : 64
cache_alignment   : 64
address sizes   : 48 bits physical, 48 bits virtual
power management: ts ttp tm stc 100mhzsteps hwpstate

carli2
 
Posts: 157
Joined: Thu Nov 10, 2011 1:53 pm

Re: Patches for Linux Makefile

Postby carli2 » Sat Jun 09, 2012 4:57 pm

Ah,
my CPU does not support SSE4.1.
But I was not able to figure out which lines in the makefile to remove to get it working.
Code: Select all
-math-optimizations -fsingle-precision-constant -I../../source/core -I../../source/physics -I../../source/meshUtil -I../../source/ai -o ../../source/core/dgAABBPolygonSoup.o ../../source/core/dgAABBPolygonSoup.cpp
In file included from ../../source/core/dgTypes.h:138:0,
                 from ../../source/core/dgStdafx.h:25,
                 from ../../source/core/dgAABBPolygonSoup.cpp:28:
/usr/lib/gcc/x86_64-linux-gnu/4.6/include/pmmintrin.h:32:3: error: #error "SSE3 instruction set not enabled"
In file included from ../../source/core/dgTypes.h:140:0,
                 from ../../source/core/dgStdafx.h:25,
                 from ../../source/core/dgAABBPolygonSoup.cpp:28:
/usr/lib/gcc/x86_64-linux-gnu/4.6/include/smmintrin.h:32:3: error: #error "SSE4.1 instruction set not enabled"
In file included from ../../source/core/dgVector.h:28:0,
                 from ../../source/core/dgMatrix.h:28,
                 from ../../source/core/dgAABBPolygonSoup.cpp:32:
../../source/core/dgSimd_128.h: In member function ‘simd_128 simd_128::AddHorizontal() const’:
../../source/core/dgSimd_128.h:147:46: error: ‘_mm_hadd_ps’ was not declared in this scope
../../source/core/dgSimd_128.h: In member function ‘simd_128 simd_128::DotProduct(const simd_128&) const’:
../../source/core/dgSimd_128.h:162:55: error: ‘_mm_hadd_ps’ was not declared in this scope
make: *** [../../source/core/dgAABBPolygonSoup.o] Error 1
carli@Weltherrschaft:~/sources/newton/coreLibrary_300/projets/linux64$ vim makefile
carli@Weltherrschaft:~/sources/newton/coreLibrary_300/projets/linux64$ make -B
gcc -c -Wall -Wno-strict-aliasing -D_LINUX_VER -D_LINUX_VER_64 -O3 -fpic -mfpmath=sse -ffloat-store -ffast-math -freciprocal-math -funsafe-math-optimizations -fsingle-precision-constant -I../../source/core -I../../source/physics -I../../source/meshUtil -I../../source/ai -o ../../source/core/dgAABBPolygonSoup.o ../../source/core/dgAABBPolygonSoup.cpp
In file included from ../../source/core/dgTypes.h:138:0,
                 from ../../source/core/dgStdafx.h:25,
                 from ../../source/core/dgAABBPolygonSoup.cpp:28:
/usr/lib/gcc/x86_64-linux-gnu/4.6/include/pmmintrin.h:32:3: error: #error "SSE3 instruction set not enabled"
In file included from ../../source/core/dgTypes.h:140:0,
                 from ../../source/core/dgStdafx.h:25,
                 from ../../source/core/dgAABBPolygonSoup.cpp:28:
/usr/lib/gcc/x86_64-linux-gnu/4.6/include/smmintrin.h:32:3: error: #error "SSE4.1 instruction set not enabled"
In file included from ../../source/core/dgVector.h:28:0,
                 from ../../source/core/dgMatrix.h:28,
                 from ../../source/core/dgAABBPolygonSoup.cpp:32:
../../source/core/dgSimd_128.h: In member function ‘simd_128 simd_128::AddHorizontal() const’:
../../source/core/dgSimd_128.h:147:46: error: ‘_mm_hadd_ps’ was not declared in this scope
../../source/core/dgSimd_128.h: In member function ‘simd_128 simd_128::DotProduct(const simd_128&) const’:
../../source/core/dgSimd_128.h:162:55: error: ‘_mm_hadd_ps’ was not declared in this scope
make: *** [../../source/core/dgAABBPolygonSoup.o] Error 1
carli2
 
Posts: 157
Joined: Thu Nov 10, 2011 1:53 pm

Re: Patches for Linux Makefile

Postby Julio Jerez » Sat Jun 09, 2012 6:30 pm

I believe you an I hav eteh same problem.

My cpu is a older 32 bit pentium 4
and I do not think it even soppoty SSE 3.
I am tring to make the chnages so that it uses SSE, maybe SSE2 on Linux system

I am getting crash in thingh liek

float a = 1.0/ sqrtf (x)
and I beleive it is because of teh SSE4.1 option
I am tryi to get the 32 bit make file to a working state now
Julio Jerez
Moderator
Moderator
 
Posts: 12426
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: Patches for Linux Makefile

Postby Julio Jerez » Sat Jun 09, 2012 6:43 pm

I do not knwo what is wrong but even when usi x87 code, it does not run.
If only the Linux debug did not * so bad.
I do not know what is going on but I am seen problems I had never seen before.
Julio Jerez
Moderator
Moderator
 
Posts: 12426
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: Patches for Linux Makefile

Postby carli2 » Sun Jun 10, 2012 7:44 am

Julio Jerez wrote:I believe you an I hav eteh same problem.

My cpu is a older 32 bit pentium 4
and I do not think it even soppoty SSE 3.


Phenom does support SSE 2 as I wrote.
And it is not a linux-specific problem, it's CPU-specific.
Why do you use SSE intrinsics directly? The compiler vectorizes your code, and if not, write two-path-code.
carli2
 
Posts: 157
Joined: Thu Nov 10, 2011 1:53 pm

Next

Return to General Discussion

Who is online

Users browsing this forum: No registered users and 1 guest