-
Notifications
You must be signed in to change notification settings - Fork 91
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
Replaced the visitation mechanism to be switch
-based.
#56
Conversation
5bcd0e3
to
a9312be
Compare
556eb86
to
8ab157d
Compare
The current C++11 implementation using a chain of ternary operators gets optimized nicely under Clang >= 4.0, but does not work well for any GCC. Clang 3.9: https://travis-ci.org/mpark/variant/jobs/474776453
Clang 4.0: https://travis-ci.org/mpark/variant/jobs/474776455
GCC 4.9: https://travis-ci.org/mpark/variant/jobs/474776437
GCC 8: https://travis-ci.org/mpark/variant/jobs/474776448
|
The current C++14/17 implementation of recursive
GCC 8: https://travis-ci.org/mpark/variant/jobs/474776450
GCC >= 7 perform well compared to the manual jump table, but it does not GCC 6: https://travis-ci.org/mpark/variant/jobs/474776444
GCC < 7 produces a jump table of size 32 (our |
Follow-up on the current C++14/17 implementation with regards to GCC >= 7. I was concerned that the non-inlined recursive GCC 8: https://travis-ci.org/mpark/variant/jobs/475164795
This is also roughly the case for GCC < 7. GCC 6: https://travis-ci.org/mpark/variant/jobs/475164789
It seems safe to me to proceed with the current implementation, for C++14/17. |
6e309e3
to
1c6cf97
Compare
I've reverted the C++11 implementation to be the manual jump table approach, The following is the full matrix of the benchmarks for |
Follow-up to #52
CC @quicknir