Uh oh!
There was an error while loading. Please reload this page.
Enable building with gcc-14 - #101623
Conversation
Tagging subscribers to this area: @hoyosjs |
am11
commented
May 13, 2024
Updated gcc pipeline. gcc14 was picked up in the CI: |
kunalspathak
commented
Jun 14, 2024
@am11 - did you run into any compilation issues with gcc-14 that does not repro on gcc-12. E.g. https://dev.azure.com/dnceng-public/cbb18261-c48f-4abb-8651-8cdcb5474649/_apis/build/builds/706791/logs/284. It is not liking the presence of if/else inside staticconstexpr regMaskTP CreateFromRegNum(const regNumber reg, regMaskSmall mask)
{
#ifdef HAS_MORE_THAN_64_REGISTERS
if (reg < 64)
{
}
else
{
}
returnregMaskTP(mask, RBM_NONE);
#elsereturnregMaskTP(mask, RBM_NONE);
#endif
} |
It's pedantically requiring single return for std=c++11 conformance: staticconstexpr regMaskTP CreateFromRegNum(regNumber reg, regMaskSmall mask)
{
#ifdef HAS_MORE_THAN_64_REGISTERS
return (reg < 64) ? regMaskTP(mask, RBM_NONE) : regMaskTP(RBM_NONE, mask);
#elsereturnregMaskTP(mask, RBM_NONE);
#endif
}(with std=c++14, if/else works) C++11 page 140: https://open-std.org/jtc1/sc22/wg21/docs/papers/2012/n3337.pdf C++14 page 155: https://www.open-std.org/jtc1/sc22/wg21/docs/papers/2014/n4296.pdf |
kunalspathak
commented
Jun 14, 2024
hhm, how can i make my code work then in current scenario where we are on gcc-14 and in std=c++11 conformance? |
am11
commented
Jun 14, 2024
Have you tried the code provided above? |
kunalspathak
commented
Jun 14, 2024
sorry, earlier I missed that piece and was just staring at c++14 and c++11 conformance. Your suggestion works :) |
No description provided.