• Russ Cox's avatar
    6c, 6g, 6l: add MOVQL to make truncation explicit · e530d6a1
    Russ Cox authored
    Without an explicit signal for a truncation, copy propagation
    will sometimes propagate a 32-bit truncation and end up
    overwriting uses of the original 64-bit value.
    
    The case that arose in practice is in C but I believe
    that the same could plausibly happen in Go.
    The main reason we didn't run into the same in Go
    is that I (perhaps incorrectly?) drop MOVL AX, AX
    during gins, so the truncation was never generated, so
    it didn't confuse the optimizer.
    
    Fixes #1315.
    Fixes #3488.
    
    R=ken2
    CC=golang-dev
    https://golang.org/cl/6002043
    e530d6a1
Name
Last commit
Last update
..
6.out.h Loading commit data...
Makefile Loading commit data...
asm.c Loading commit data...
doc.go Loading commit data...
l.h Loading commit data...
list.c Loading commit data...
mkenam Loading commit data...
obj.c Loading commit data...
optab.c Loading commit data...
pass.c Loading commit data...
prof.c Loading commit data...
span.c Loading commit data...