-
Notifications
You must be signed in to change notification settings - Fork 38.8k
build with -fstack-reuse=none #15983
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
@jamesob any chance you can benchmark? |
|
@gmaxwell yep, running now. |
|
Performance came back negligibly different, though I'm not totally sure this PR worked for me as intended. I double-checked to see if Wed 8 20:32 james/.bitcoinperf/fad88bd6c9f85e6e7f8fb66a94aa75c67d26b7d8
$ grep -R 'fstack-reuse' .
./autom4te.cache/output.0:{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C++ compiler accepts -fstack-reuse=none" >&5
./autom4te.cache/output.0:$as_echo_n "checking whether C++ compiler accepts -fstack-reuse=none... " >&6; }
./autom4te.cache/output.0: CXXFLAGS="$CXXFLAGS -fstack-reuse=none"
./autom4te.cache/output.0: HARDENED_CXXFLAGS="$HARDENED_CXXFLAGS -fstack-reuse=none"
./autom4te.cache/traces.0:m4trace:configure.ac:737: -1- AX_CHECK_COMPILE_FLAG([-fstack-reuse=none], [HARDENED_CXXFLAGS="$HARDENED_CXXFLAGS -fstack-reuse=none"])In any case, here's the bench data: 1905-buildStackReuseNone vs. master (absolute)
1905-buildStackReuseNone vs. master (relative)
|
|
It should be supported for all versions of gcc we support: https://gcc.gnu.org/onlinedocs/gcc-4.8.0/gcc/Code-Gen-Options.html I had to run Also, the results of the micro benchmarks would be useful. |
|
See for example, how it is picked up on trusty: https://travis-ci.org/bitcoin/bitcoin/jobs/529914026#L2522 |
|
ryanofsky
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
utACK fad88bd6c9f85e6e7f8fb66a94aa75c67d26b7d8. Not tested, but config file change looks right and should do what's described.
fad88bd to
fae91e3
Compare
ryanofsky
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
utACK fae91e3b19627cba63f05caa18eb990888684036. Just new comment added.
fae91e3 to
faf38bc
Compare
|
The following sections might be updated with supplementary metadata relevant to reviewers and maintainers. ConflictsReviewers, this pull request conflicts with the following ones:
If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first. |
faf38bc build with -fstack-reuse=none (MarcoFalke) Pull request description: All versions of gcc that we commonly use for building are subject to bug https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90348. To work around that, set `-fstack-reuse=none` for all builds. See #15959 (comment) This option does not exist for clang https://clang.llvm.org/docs/ClangCommandLineReference.html#target-independent-compilation-options, but it does for gcc https://gcc.gnu.org/onlinedocs/gcc/Code-Gen-Options.html ACKs for commit faf38b: Tree-SHA512: f5597583402d31ea7b89ac358a6f4a537bbb82a1dde2bd41bac65ee0fd88c7af75ee4c24c6b8eed6b139bf4dbf07ab2987f8fc30fb3eab179cd2d753a8a2a47d
Github-Pull: bitcoin#15983 Rebased-From: faf38bc
58e291c Add test for GCC bug 90348 (Pieter Wuille) Pull request description: This adds a test for GCC bug 90348 (https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90348), using a test case extracted from our own `sha256d64` test in crypto_tests.cpp, which was failing on some platforms. This is based on top of bitcoin#15983 to make sure the bug doesn't trigger (it does in some Travis configurations without it). ACKs for commit 58e291: Tree-SHA512: 4dc9084e92dd143a53930e42bb68e33d922a2a2b891406b259d3a0bed4511dcc49e7447a7a8e4eb793a26e3eacb188ca293b71e0e061f9b3230f8e7fcfd29525
|
Included for backport in #16035. |
|
@fanquake What about 17.2? |
|
@MarcoFalke I'll do that now so it's not forgotten. |
Github-Pull: bitcoin#15983 Rebased-From: faf38bc
|
Done in #16163. |
… case b5a4abe Add test for GCC bug 90348 (Pieter Wuille) 05fb9f7 build with -fstack-reuse=none (MarcoFalke) Pull request description: Backports: * [build with -fstack-reuse=none](#15983) * [Add test for GCC bug 90348](#15985) b5a4abe has been modified to replace the `setup_common.h` with `test_bitcoin.h` include. ACKs for commit b5a4ab: Empact: ACK b5a4abe by review of the linked PRs, the GCC bug and option, and visual inspection/comparison of the ported code laanwj: Code review + relevancy for backport ACK b5a4abe Tree-SHA512: cdfdc6e2f208e8dc6a8a86cd7a7ed0f2a6f96604a0663efc970f580f693c1975353341fa8434b23de3cb681e03c6918e3342178752ed595d16a0ec50db913266
Github-Pull: bitcoin#15983 Rebased-From: faf38bc
Github-Pull: bitcoin#15983 Rebased-From: faf38bc
faf38bc build with -fstack-reuse=none (MarcoFalke) Pull request description: All versions of gcc that we commonly use for building are subject to bug https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90348. To work around that, set `-fstack-reuse=none` for all builds. See bitcoin#15959 (comment) This option does not exist for clang https://clang.llvm.org/docs/ClangCommandLineReference.html#target-independent-compilation-options, but it does for gcc https://gcc.gnu.org/onlinedocs/gcc/Code-Gen-Options.html ACKs for commit faf38b: Tree-SHA512: f5597583402d31ea7b89ac358a6f4a537bbb82a1dde2bd41bac65ee0fd88c7af75ee4c24c6b8eed6b139bf4dbf07ab2987f8fc30fb3eab179cd2d753a8a2a47d
faf38bc build with -fstack-reuse=none (MarcoFalke) Pull request description: All versions of gcc that we commonly use for building are subject to bug https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90348. To work around that, set `-fstack-reuse=none` for all builds. See bitcoin#15959 (comment) This option does not exist for clang https://clang.llvm.org/docs/ClangCommandLineReference.html#target-independent-compilation-options, but it does for gcc https://gcc.gnu.org/onlinedocs/gcc/Code-Gen-Options.html ACKs for commit faf38b: Tree-SHA512: f5597583402d31ea7b89ac358a6f4a537bbb82a1dde2bd41bac65ee0fd88c7af75ee4c24c6b8eed6b139bf4dbf07ab2987f8fc30fb3eab179cd2d753a8a2a47d
58e291c Add test for GCC bug 90348 (Pieter Wuille) Pull request description: This adds a test for GCC bug 90348 (https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90348), using a test case extracted from our own `sha256d64` test in crypto_tests.cpp, which was failing on some platforms. This is based on top of bitcoin#15983 to make sure the bug doesn't trigger (it does in some Travis configurations without it). ACKs for commit 58e291: Tree-SHA512: 4dc9084e92dd143a53930e42bb68e33d922a2a2b891406b259d3a0bed4511dcc49e7447a7a8e4eb793a26e3eacb188ca293b71e0e061f9b3230f8e7fcfd29525
58e291c Add test for GCC bug 90348 (Pieter Wuille) Pull request description: This adds a test for GCC bug 90348 (https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90348), using a test case extracted from our own `sha256d64` test in crypto_tests.cpp, which was failing on some platforms. This is based on top of bitcoin#15983 to make sure the bug doesn't trigger (it does in some Travis configurations without it). ACKs for commit 58e291: Tree-SHA512: 4dc9084e92dd143a53930e42bb68e33d922a2a2b891406b259d3a0bed4511dcc49e7447a7a8e4eb793a26e3eacb188ca293b71e0e061f9b3230f8e7fcfd29525

All versions of gcc that we commonly use for building are subject to bug https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90348. To work around that, set
-fstack-reuse=nonefor all builds. See #15959 (comment)This option does not exist for clang https://clang.llvm.org/docs/ClangCommandLineReference.html#target-independent-compilation-options, but it does for gcc https://gcc.gnu.org/onlinedocs/gcc/Code-Gen-Options.html