opt: Start optimizing dead code a bit

If a condition is always zero/non-zero we can omit the
then or else code.  This is complicated a bit by having to
deal with labels that might make such code reachable without
us yet knowing during parsing.
This commit is contained in:
Michael Matz
2016-09-19 18:38:12 +02:00
parent b303a00ce0
commit 31c7ea0165
4 changed files with 182 additions and 2 deletions

View File

@ -0,0 +1,18 @@
timeout=2
timeout=1
boo
yeah
twice
once
twice
SEtwice
SEonce
SEtwice
twice2
once2
twice2
twice3
once3
twice3
caseok
caseok2