[pypy-svn] r59206 - in pypy/dist/pypy: lang/gameboy translator/goal
cami at codespeak.net
cami at codespeak.net
Sat Oct 18 12:39:48 CEST 2008
Author: cami
Date: Sat Oct 18 12:39:47 2008
New Revision: 59206
Modified:
pypy/dist/pypy/lang/gameboy/timer.py
pypy/dist/pypy/translator/goal/targetgbprofiling.py
Log:
reverted previosly commited bug in gameboy timer
targetgbprofiling doesn't print anymore opcode numbers
Modified: pypy/dist/pypy/lang/gameboy/timer.py
==============================================================================
--- pypy/dist/pypy/lang/gameboy/timer.py (original)
+++ pypy/dist/pypy/lang/gameboy/timer.py Sat Oct 18 12:39:47 2008
@@ -156,5 +156,5 @@
pass
def get_time(self):
- return (time.time()*1000)
+ return int(time.time()*1000)
Modified: pypy/dist/pypy/translator/goal/targetgbprofiling.py
==============================================================================
--- pypy/dist/pypy/translator/goal/targetgbprofiling.py (original)
+++ pypy/dist/pypy/translator/goal/targetgbprofiling.py Sat Oct 18 12:39:47 2008
@@ -8,8 +8,7 @@
from pypy.lang.gameboy.interrupt import Interrupt
from pypy.lang.gameboy.profiling.profiling_cpu import ProfilingCPU
-
-
+PRINT_OPCODE_LABEL=False
def entry_point(argv=None):
typical = False
@@ -48,13 +47,19 @@
for i in range(0xFF):
if i not in forbidden and OP_CODES[i] is not None:
op_codes[0] = i
- print i, ":", run(op_codes, count)
+ if PRINT_OPCODE_LABEL:
+ print i, ":", run(op_codes, count)
+ else:
+ print run(op_codes, count)
def run_each_second_order(count):
op_codes = [0xCB]*2
for i in range(0xFF):
op_codes[1] = i
- print "0xCB :", i, ":" , run(op_codes, count)
+ if PRINT_OPCODE_LABEL:
+ print "0xCB :", i, ":" , run(op_codes, count)
+ else:
+ print run(op_codes, count)
def run_all_first_order(count):
print run(FIRST_ORDER_LIST, count)
More information about the Pypy-commit
mailing list