Closed ms178 closed 2 months ago
This was driving me insane. This is a test that simply verifies that an expression is not constant, so it does not really care for the values of the expression. But it turns out, newer LLVM sees the non_constant_expr
value being used as divisor in a previous test, and thus rightfully deduces that it cannot be 0 and thus optimizes the expression into a constant.
Now fixed in: https://github.com/c-util/c-stdaux/commit/6bc45c0f6e14df97bb4869d8202cf5d020c97fa8
This has no impact on dbus-broker
, but merely affects the test-suite.
Thanks a lot!
Trying to build dbus-broker 36 with Clang 18.1.3 from https://mirrors.edge.kernel.org/pub/tools/llvm/ on CachyOS with super conservative cflags, I see the following test failure. I've seen this with Clang and some older dbus-broker revisions for a while now. Everything works fine when using GCC 13.2.1 instead. CPU is Intel Haswell-EP.