boostorg / boostorg/boost

How to apply -O3 optimization while testing boost?

Open
#861 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
HTML
Stars
8.6k
Forks
1.9k
Avg merge
39m
Merged PRs (30d)
2

Description

I am currently working on verifying and testing boost for the QNX platform. For some reason, there are some issues with the powl function on the platform which causes a couple tests in Random package to fail. After some investigation we found using the -O3 flag fixes it in our test exes. But I am unable to apply the same to the build using "b2.exe".

The command that gets finally used to build is
b2 --hash link=static toolset=qcc variant=release target-os=qnx address-model=64 architecture=x86 abi=sysv binary-format=elf linkflags="-V8.3.0,gcc_ntox86_64_gpp" cxxflags="-Wc,-std=c++14 -Wc,-std=gnu++14 -Wc,-fstack-protector-strong -Wc,-ftemplate-depth=1024 -Wc,-march=core2 -Wc,-mfpmath=sse -Wc,-fno-rounding-math -Wc,-msse2 -Wc,-fno-builtin -Wc,-w -Wc,-O3 -V8.3.0,gcc_ntox86_64_gpp" linkflags="-lstdc++ -lsocket" testing.launcher=ax_rexec --without-python --without-mpi define=BOOST_NO_CXX11_STD_ALIGN define=BOOST_NO_CXX11_HDR_CODECVT define="__GXX_EXPERIMENTAL_CXX0X__=1" define="_GLIBCXX_USE_C99=1" define=BOOST_NO_CXX11_HDR_TYPE_TRAITS define=BOOST_NO_CXX17_HDR_FILESYSTEM define=BOOST_BIND_GLOBAL_PLACEHOLDERS define=BOOST_NO_CXX17_HDR_MEMORY_RESOURCE define=BOOST_NO_STD_WSTRING define=BOOST_NO_CXX11_HDR_TYPE_TRAITS

I also tried modifying the jamfile to use the -O3 flag in the following way:

project /boost/random/test
: requirements
msvc:_SCL_SECURE_NO_WARNINGS
gcc:"-O3"
qcc:"-O3"
q++:"-O3"
;

Please let me know what I am doing wrong in applying this to my build.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.