https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88271

--- Comment #1 from Daniel Fruzynski <bugzi...@poradnik-webmastera.com> ---
I checked that in simple case when bit shift is used in "if", it is optimized:

[code]
void f();
void g();

void test(int n)
{
    if (n << 1)
        f();
    else
        g();
}
[/code]

[asm]
test(int):
        add     edi, edi
        je      .L2
        jmp     f()
.L2:
        jmp     g()
[/asm]

Reply via email to