[pypy-svn] r68159 - pypy/trunk/pypy/jit/metainterp
arigo at codespeak.net
arigo at codespeak.net
Mon Oct 5 11:37:02 CEST 2009
Author: arigo
Date: Mon Oct 5 11:37:01 2009
New Revision: 68159
Modified:
pypy/trunk/pypy/jit/metainterp/resume.py
Log:
Improve dump_storage().
Modified: pypy/trunk/pypy/jit/metainterp/resume.py
==============================================================================
--- pypy/trunk/pypy/jit/metainterp/resume.py (original)
+++ pypy/trunk/pypy/jit/metainterp/resume.py Mon Oct 5 11:37:01 2009
@@ -179,7 +179,7 @@
storage.rd_consts = self.consts[:]
storage.rd_snapshot = None
if debug:
- dump_storage(storage)
+ dump_storage(storage, liveboxes)
return liveboxes
def _getboxindex(self, box):
@@ -314,7 +314,7 @@
# ____________________________________________________________
-def dump_storage(storage):
+def dump_storage(storage, liveboxes):
"For profiling only."
import os
from pypy.rlib import objectmodel
@@ -327,6 +327,9 @@
for const in storage.rd_consts:
os.write(fd, '\t"%s",\n' % (const.repr_rpython(),))
os.write(fd, '\t], [\n')
+ for box in liveboxes:
+ os.write(fd, '\t"%s",\n' % (box.repr_rpython(),))
+ os.write(fd, '\t], [\n')
if storage.rd_virtuals is not None:
for virtual in storage.rd_virtuals:
os.write(fd, '\t%s,\n' % (virtual.repr_rpython(),))
More information about the Pypy-commit
mailing list