[Bug tree-optimization/119917] [Optimization Opportunity] Inefficient code generation for multiplication overflow detection with explicit zero checks

2025-04-24 Thread a1343922569 at outlook dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119917 --- Comment #4 from Jin Haobo --- The latest clang (trunk version) has applied this optimization, including 8/16/32/64-bit situation. Link: https://godbolt.org/z/aTbqGTPex

[Bug tree-optimization/119917] [Optimization Opportunity] Inefficient code generation for multiplication overflow detection with explicit zero checks

2025-04-24 Thread a1343922569 at outlook dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119917 --- Comment #3 from Jin Haobo --- Thank you for your confirmation. I understand that the char/short cases are treated differently due to integer promotion. While I acknowledge that 8/16-bit unsigned integers undergo integer promotion which chang

[Bug tree-optimization/119917] [Optimization Opportunity] Inefficient code generation for multiplication overflow detection with explicit zero checks

2025-04-23 Thread a1343922569 at outlook dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119917 --- Comment #1 from Jin Haobo --- Created attachment 61192 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=61192&action=edit test.cpp source code test.cpp source code

[Bug c++/119917] New: [Optimization Opportunity] Inefficient code generation for multiplication overflow detection with explicit zero checks

2025-04-23 Thread a1343922569 at outlook dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119917 Bug ID: 119917 Summary: [Optimization Opportunity] Inefficient code generation for multiplication overflow detection with explicit zero checks Product: gcc Versi