lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

Em seg., 7 de dez. de 2020 às 09:07, Xmilia Hermit <> escreveu:

Maybe also take a look at gcc.
x86-x64 gcc 10.2 (-O2):

        mov     eax, 10

f(unsigned int):
        cmp     edi, -10
        sbb     eax, eax
        and     eax, 10

I would say in this case f(int) is faster.

It seems to me that someone forgot to apply the same optimization for "unsigned int", into gcc code.
What leads to the conclusion, where are these modern compilers really?
Clang 11.0 is not a modern compiler?

Ranier Vilela