Opened 11 years ago
Closed 11 years ago
#1894 closed defect (fixed)
NVTT OptimalOptions.cmake assumes x86_64 implies athlon64
Reported by: | Francis Herne | Owned by: | leper |
---|---|---|---|
Priority: | Should Have | Milestone: | Alpha 15 |
Component: | Build & Packages | Keywords: | |
Cc: | Patch: |
Description (last modified by )
As in summary; libraries/source/nvtt/src/cmake/OptimalOptions.cmake contains the section copied below. This prevents pyrogenesis from starting after compilation on my Pentium D processor, as -march=athlon64 is not valid. Removing the '-march=athlon64', or the entire section, resoves the problem.
Thanks to those on IRC! :-)
IF(NV_SYSTEM_PROCESSOR STREQUAL "x86_64") SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -march=athlon64") #SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -march=athlon64 -msse3") ENDIF(NV_SYSTEM_PROCESSOR STREQUAL "x86_64")
Change History (8)
follow-up: 2 comment:1 by , 11 years ago
Description: | modified (diff) |
---|
follow-up: 3 comment:2 by , 11 years ago
Replying to historic_bruno:
This should be reported upstream as well: http://code.google.com/p/nvidia-texture-tools/issues/list
And it has been: Issue 188
comment:3 by , 11 years ago
Replying to historic_bruno:
Replying to historic_bruno:
This should be reported upstream as well: http://code.google.com/p/nvidia-texture-tools/issues/list
And it has been: Issue 188
By me (some time ago), in response to your first comment ;-)
comment:4 by , 11 years ago
Milestone: | Backlog → Alpha 14 |
---|
comment:5 by , 11 years ago
Milestone: | Alpha 14 → Alpha 15 |
---|
Unsure whether it's best to remove the -march
option or set it to native
(which may still break cross compiling), but it only affects a few people so I'm bumping it to A15.
comment:6 by , 11 years ago
Using -march=native may help here but the risulting binaries won't work on any other CPU, leading for sure to other bug reports difficult to identify (all Linux distribution will break, also it won't fix #1994). Also there is no point in using native only on nvtt (which it's not a critical component for end user performance), while 0ad itself and other libs are not using it. Who want to use native and other system specific features can enable them theirself (see Gentoo users), anyway this usually leads to very small performance gain, especially on 64 bit platforms where the base CPU is not so old as the 386 on 32 bit.
So I'd really won't use native and suggest to remove the -march as soon as possible.
This should be reported upstream as well: http://code.google.com/p/nvidia-texture-tools/issues/list