Created attachment 7508
First file: original test case
I have a ParseInt function which is able to parse either a integer or a hex
string (beginning with $). While parsing integers and hex numbers is really
similar, i put them into one function.
The test case is compiled from the following program:
static init
begin
var i: int = ParseInt('5', 0)
print(IntToStr(i))
end
I attached a second file which is the run after opt -O3.
As you see in block vergleich.i in line 54, %testpx.i is compared wether it is
smaller than 10.
In gleich.i, %textpx.i is compared wether it is greater than 9. %gleich.i's
predecessor is %vergleich2.i which predecessor is %vergleich.i
But %vergleich.i only branches into vergleich2.i when %testpx.i is smaller than
10, so it can never become greater than 9.
y.ll
(8814 bytes, application/octet-stream)z.ll
(6584 bytes, application/octet-stream)