https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95731
Bug ID: 95731 Summary: Faiilure to optimize a >= 0 && b >= 0 to (a | b) >= 0 Product: gcc Version: 11.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: tree-optimization Assignee: unassigned at gcc dot gnu.org Reporter: gabravier at gmail dot com Target Milestone: --- bool f(int a, int b) { return a >= 0 && b >= 0; } This can be optimized to `return (a | b) >= 0;`. LLVM does this transformation, but GCC does not.