D-Programming-Language/dmd — pull request #2841 by yebblies (2013-11-21 05:54:24+00:00)
Title: Issue 11565 - [Optimizer] Zeroes out the higher 32bits of register in ?: expression

This:
```d
uint cond10703(uint val)
{
return val ? uint.max : 0;
}
```
becomes
```
_D5testx9cond10703FmZm PROC
push rbp ; 0000 _ 55
mov rbp, rsp ; 0001 _ 48: 8B. EC
cmp rcx, 1 ; 0004 _ 48: 83. F9, 01
sbb rax, rax ; 0008 _ 48: 19. C0
not eax ; 000B _ F7. D0
pop rbp ; 000D _ 5D
ret ; 000E _ C3
_D5testx9cond10703FmZm ENDP
```
Which is missing the REX_W prefix on the `not`.

https://d.puremagic.com/issues/show_bug.cgi?id=11565