mirror of
https://github.com/gcc-mirror/gcc.git
synced 2026-05-06 14:59:39 +02:00
[LRA]: Fix reg notes update
There is a typo in using dead_set instead of set in clear_sparseset_regnos and regnos_in_sparseset_p. This can result in wrong unused (stalled) notes and wrong or worse code generation by optimizations using unused notes after RA. gcc/ChangeLog: * lra-lives.cc (clear_sparseset_regnos, regnos_in_sparseset_p): Use set instead of dead_set.
This commit is contained in:
@@ -632,7 +632,7 @@ clear_sparseset_regnos (sparseset set, int regno, enum machine_mode mode)
|
||||
{
|
||||
if (regno >= FIRST_PSEUDO_REGISTER)
|
||||
{
|
||||
sparseset_clear_bit (dead_set, regno);
|
||||
sparseset_clear_bit (set, regno);
|
||||
return;
|
||||
}
|
||||
for (int last = end_hard_regno (mode, regno); regno < last; regno++)
|
||||
@@ -645,7 +645,7 @@ static bool
|
||||
regnos_in_sparseset_p (sparseset set, int regno, enum machine_mode mode)
|
||||
{
|
||||
if (regno >= FIRST_PSEUDO_REGISTER)
|
||||
return sparseset_bit_p (dead_set, regno);
|
||||
return sparseset_bit_p (set, regno);
|
||||
for (int last = end_hard_regno (mode, regno); regno < last; regno++)
|
||||
if (!sparseset_bit_p (set, regno))
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user