good in general, but bad nested loops
Matthew Fluet
mfluet@intertrust.com
Tue, 10 Jul 2001 18:20:29 -0700 (PDT)
Here's what's currently spy-ed in the tight loop for nestedloop.sml (the
older one, not the one Steve wrote today) under my current version of the
backend:
0x804aea0: cmp $0x0,%edx
0x804aea3: je 0x804b0ec
0x804aea9: dec %edx
0x804aeaa: jo 0x804b104
0x804aeb0: inc %ebx
0x804aeb1: jo 0x804b114
0x804aeb7: jmp 0x804aea0
And with -detect-overflow false:
0x804aaba: cmp $0x0,%ebp
0x804aabd: je 0x804ad48
0x804aac3: dec %ebp
0x804aac4: inc %edx
0x804aac5: jmp 0x804aaba
Can't ask for much better than that (except turning the cmp to a tstl).