diff options
Diffstat (limited to 'ir/mem2reg.c')
| -rw-r--r-- | ir/mem2reg.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ir/mem2reg.c b/ir/mem2reg.c index a1a4132..0bd78ca 100644 --- a/ir/mem2reg.c +++ b/ir/mem2reg.c @@ -262,7 +262,7 @@ mem2reg(struct function *fn) } goto Next; } - if (!ndef) /* slot is read from but never written to */ + if (!ndef && instrnuse[var] > 0) /* slot is read from but never written to */ goto Next; qsort(instruse[var], instrnuse[var], sizeof *instruse[var], cmpuse); |