From: David Given Date: Fri, 13 Jan 2017 22:08:25 +0000 (+0100) Subject: Typo fix so that liveness is now calculated correctly again; remember to reset X-Git-Url: https://git.ndcode.org/public/gitweb.cgi?a=commitdiff_plain;h=51c5459ee8e6a775cf159b45ca5c3703a9f564a1;p=ack.git Typo fix so that liveness is now calculated correctly again; remember to reset the storage set on exit so we don't end up with bogus pointers after the heap is freed. --- diff --git a/mach/proto/mcg/pass_livevalueanalysis.c b/mach/proto/mcg/pass_livevalueanalysis.c index 4e83880fd..2b20cc18c 100644 --- a/mach/proto/mcg/pass_livevalueanalysis.c +++ b/mach/proto/mcg/pass_livevalueanalysis.c @@ -53,7 +53,7 @@ static void propagate_liveness(struct basicblock* bb) struct valueusage* usage = hit.value; if (usage->input) - set_remove(&known_live, value); + set_add(&known_live, value); } } } @@ -65,6 +65,7 @@ void pass_live_value_analysis(void) for (i=0; i