• Austin Clements's avatar
    cmd/compile: don't compact liveness maps in place · bdb65da0
    Austin Clements authored
    Currently Liveness.compact rewrites the Liveness.livevars slice in
    place. However, we're about to add register maps, which we'll want to
    track in livevars, but compact independently from the stack maps.
    Hence, this CL modifies Liveness.compact to consume Liveness.livevars
    and produce a new slice of deduplicated stack maps. This is somewhat
    clearer anyway because it avoids potential confusion over how
    Liveness.livevars is indexed.
    
    Passes toolstash -cmp.
    
    For #24543.
    
    Change-Id: I7093fbc71143f8a29e677aa30c96e501f953ca2b
    Reviewed-on: https://go-review.googlesource.com/108498
    Run-TryBot: Austin Clements <austin@google.com>
    TryBot-Result: Gobot Gobot <gobot@golang.org>
    Reviewed-by: default avatarDavid Chase <drchase@google.com>
    bdb65da0
plive.go 35.3 KB