[Bug tree-optimization/118933] New: Missed optimization: __builtin_unreachable() does not work as expected on std::vector data compared to raw pointer and length

2025-02-18 Thread nicula.iccc at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118933 Bug ID: 118933 Summary: Missed optimization: __builtin_unreachable() does not work as expected on std::vector data compared to raw pointer and length Product: gcc

[Bug tree-optimization/118657] Missed optimization (unreachable branch could be pruned after taking into account the possible values of a constexpr lookup table)

2025-01-26 Thread nicula.iccc at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118657 --- Comment #4 from Ionuț Nicula --- Note that my actual usecase with this kind of transformation is slightly more complex. Instead of having the lookup table filled with zeros (or any single value), it's filled with arbitrary values that satisf

[Bug tree-optimization/118657] New: Missed optimization (unreachable branch could be pruned after taking into account the possible values of a constexpr lookup table)

2025-01-25 Thread nicula.iccc at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118657 Bug ID: 118657 Summary: Missed optimization (unreachable branch could be pruned after taking into account the possible values of a constexpr lookup table) Product: gcc

[Bug tree-optimization/117852] New: Missed optimization/vectorization opportunity (bitwise-OR-ing into a bool accumulator)

2024-11-29 Thread nicula.iccc at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117852 Bug ID: 117852 Summary: Missed optimization/vectorization opportunity (bitwise-OR-ing into a bool accumulator) Product: gcc Version: 15.0 Status: UNCONFIRMED S

[Bug tree-optimization/117776] [12/13/14/15 Regression] Missed optimization/vectorization opportunity (adding a even/odd check to an accumulator)

2024-11-25 Thread nicula.iccc at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117776 --- Comment #7 from Ionuț Nicula --- I see that if I replace the condition with `n%3==0`, or `n>3`, the code is vectorized. So GCC is clearly capable of vectorizing this `accumulator += boolean` pattern.

[Bug tree-optimization/117776] [12/13/14/15 Regression] Missed optimization/vectorization opportunity (adding a even/odd check to an accumulator)

2024-11-25 Thread nicula.iccc at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117776 --- Comment #6 from Ionuț Nicula --- Good point, my previous title was too generic, while the actual problem seems to be very specific (i.e. related to the even/odd check, like you said).

[Bug tree-optimization/117776] New: Missed optimization/vectorization opportunity (adding a bool to an accumulator)

2024-11-25 Thread nicula.iccc at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117776 Bug ID: 117776 Summary: Missed optimization/vectorization opportunity (adding a bool to an accumulator) Product: gcc Version: 14.2.0 Status: UNCONFIRMED Severi