search for: bldizk

Displaying 2 results from an estimated 2 matches for "bldizk".

2018 Nov 26
2
BUGS in code generated for target i386-win32
...oes NOT create prolog/epilog here, so it CLEARLY knows that "argument" is held in ECX and "polynomial" in EDX ... as documented for __fastcall JFTR: Clang (like MSVC too) knows VERY well which registers are used (clobbered) in an __asm block. See <https://godbolt.org/z/blDIzK>, which proves your assumption WRONG! > The compiler has actually inlined that function as you said, then > noticed this lack of use and decided to completely eliminate the > lfsr variable. 1. see above! 2. add "__declspec(noinline)" to the function definition ... and...
2018 Nov 26
3
BUGS in code generated for target i386-win32
Hi @ll, LLVM/clang generates wrong code for the following program (see <https://godbolt.org/z/UZrrkG>): --- sample.c --- unsigned __fastcall lfsr32(unsigned argument, unsigned polynomial) { __asm { add ecx, ecx ; ecx = argument << 1 sbb eax, eax ; eax = CF ? -1 : 0 and eax, edx ; eax = CF ? polynomial : 0 xor eax, ecx ; eax = (argument <<