You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is a bug due to CMake scoping rules. Fixed that locally but as it is in a submodule (libutil) it needs to wait for #1085.
Thanks for that, it is actually significant (potentially) for performance
To be able to change the machine type would also be great. (eg. -march=native)
RTTR_OPTIMIZATION_TUNE has a default setting computed by the target architecture. For march this is not feasible as the code would not run on lower machines. Just use -DCMAKE_CXX_FLAGS=-march=native
gcc-7.3.0 had some serious codegen bugs, where it messed up with -march=native and another one where it mixed avx2 instructions into -march=native, regardless of the cpu. You might want to doublecheck if your distro has the fixes backported to gcc-7.4.0, not sure if they were fixed by upstream. gcc-8.3.0 has them all fixed.
cmake -DCMAKE_BUILD_TYPE=Release -DRTTR_ENABLE_OPTIMIZATIONS=ON -DRTTR_OPTIMIZATION_TUNE=native -DRTTR_OPTIMIZATION_VECTOR_EXT=AVX2 -DBUILD_TESTING=OFF ..
make
ps aux | grep mtune:
/usr/lib/gcc/x86_64-linux-gnu/7/cc1plus -quiet -I /root/s25client/libs/s25main -I /root/s25client/external/libsiedler2/include -I /root/s25client/external/libutil/include -I /root/s25client/external/libendian/include -I /root/s25client/external/libutil/nowide/include -I /root/s25client/external/liblobby/include -I /root/s25client/external/mygettext/include -I /root/s25client/libs/common/include -I /root/s25client/libs/rttrConfig/src -I /root/s25client/libs/libGamedata -I /root/s25client/build/external/glad/include -I /root/s25client/libs/driver/include -I /root/s25client/external/libutil/utfcpp/source -I /root/s25client/libs/libsamplerate/include -I /root/s25client/external/libsamplerate/src -I /root/s25client/build/external/libsamplerate -imultiarch x86_64-linux-gnu -D_GNU_SOURCE -D BOOST_NOWIDE_USE_FILESYSTEM -D HAVE_STRUCT_TIMESPEC -D NDEBUG -isystem /root/s25client/external/lua/include -isystem /root/s25client/external/kaguya/include /root/s25client/libs/s25main/nodeObjs/noGrainfield.cpp -quiet -dumpbase noGrainfield.cpp -mfpmath=sse -mavx2 -mtune=generic -march=x86-64 -auxbase-strip CMakeFiles/s25Main.dir/nodeObjs/noGrainfield.cpp.o -O3 -Wall -Wextra -Werror -pedantic-errors -Wcast-qual -Wdisabled-optimization -Wfloat-conversion -Wformat-nonliteral -Wformat-security -Wformat=2 -Winit-self -Wlogical-op -Wmissing-declarations -Wmissing-field-initializers -Wsuggest-attribute=format -Wmissing-include-dirs -Wsuggest-attribute=noreturn -Wpacked -Wparentheses -Wpedantic -Wpointer-arith -Wstrict-aliasing=2 -Wundef -Wunused -Wunused-parameter -Wwrite-strings -Wno-unknown-pragmas -Wctor-dtor-privacy -Wnoexcept -Woverloaded-virtual -Wstrict-null-sentinel -Wsuggest-override -Wno-maybe-uninitialized -Wno-error=suggest-override -Wredundant-decls -std=c++14 -fno-strict-aliasing -fstack-protector-strong -o /tmp/ccwIsGaQ.s
gcc version 7.4.0 (Ubuntu 7.4.0-1ubuntu1~18.04.1)
To be able to change the machine type would also be great. (eg. -march=native)
The text was updated successfully, but these errors were encountered: