You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
According to the reference, reserved registers such as rbx may be allocated into the register class "reg".
If the pointer to the cpu maker name gets put into rbx, the following asm is emitted.
pushrbxcpuid ;rbx is replaced with part of the cpu maker namemov[rbx],ebx ;rbx is not a valid pointer UNDEFINED BEHAVIOR;...
This bug should be fixed and a warning should be put in to prevent people from making similar mistakes. An example fix would be using explicit input operands and warning against using automatic integer/pointer register assignment when using rbx(64-bit), esi(32-bit) or rbp in asm.