Commit 0ee8729c authored by Jayke Meijer's avatar Jayke Meijer

Fixed calculation of optimizations.

parent 14c963e2
This diff is collapsed.
This diff is collapsed.
...@@ -63,6 +63,6 @@ def optimize(statements, verbose=0): ...@@ -63,6 +63,6 @@ def optimize(statements, verbose=0):
print 'After global optimization: %d' % g print 'After global optimization: %d' % g
print 'After basic blocks optimization: %d' % b print 'After basic blocks optimization: %d' % b
print 'Optimization: %d (%d%%)' \ print 'Optimization: %d (%d%%)' \
% (b - o, int((b - o) / float(o) * 100)) % (o - b, int((o - b) / float(b) * 100))
return opt_blocks return opt_blocks
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment