[pypy-issue] [issue1362] assert error (happens on one machine but not another??)

Jeff Wu tracker at bugs.pypy.org
Fri Jan 11 08:59:00 CET 2013


New submission from Jeff Wu <jeffwu at mit.edu>:

Hi guys.  I'm using the translator toolchain on an interpreter I built.  It works 
great on my computer (OS X 10.8, Python 2.7.3) but won't work on the EC2 instance 
(Ubuntu, tried both Python 2.7.2, the default, and 2.7.3).  Instead, it gives the 
error below.  Where is the discrepancy likely to be coming from?  What does the 
error mean?  Sorry for the noobishness, and any help is appreciated! 
                                             
(The beginning has been omitted)
...
[platform:execute] gcc /tmp/usession-release-2.0-beta-1-12/platcheck_17.o -pthread 
-lrt -o /tmp/usession-release-2.0-beta-1-12/platcheck_17
[platform:execute] gcc -c -O3 -pthread -fomit-frame-pointer -Wall -Wno-unused 
/tmp/usession-release-2.0-beta-1-12/platcheck_18.c -o /tmp/usession-release-2.0-
beta-1-12/platcheck_18.o
[platform:execute] gcc /tmp/usession-release-2.0-beta-1-12/platcheck_18.o -pthread 
-lrt -o /tmp/usession-release-2.0-beta-1-12/platcheck_18
[platform:execute] gcc -c -O3 -pthread -fomit-frame-pointer -Wall -Wno-unused 
/tmp/usession-release-2.0-beta-1-12/platcheck_19.c -o /tmp/usession-release-2.0-
beta-1-12/platcheck_19.o
[platform:execute] gcc /tmp/usession-release-2.0-beta-1-12/platcheck_19.o -pthread 
-lrt -o /tmp/usession-release-2.0-beta-1-12/platcheck_19
[platform:execute] gcc -c -O3 -pthread -fomit-frame-pointer -Wall -Wno-unused 
/tmp/usession-release-2.0-beta-1-12/platcheck_20.c -o /tmp/usession-release-2.0-
beta-1-12/platcheck_20.o
[platform:execute] gcc /tmp/usession-release-2.0-beta-1-12/platcheck_20.o -pthread 
-lrt -o /tmp/usession-release-2.0-beta-1-12/platcheck_20
[platform:execute] gcc -c -O3 -pthread -fomit-frame-pointer -Wall -Wno-unused 
/tmp/usession-release-2.0-beta-1-12/platcheck_21.c -o /tmp/usession-release-2.0-
beta-1-12/platcheck_21.o
[platform:execute] gcc /tmp/usession-release-2.0-beta-1-12/platcheck_21.o -pthread 
-lrt -o /tmp/usession-release-2.0-beta-1-12/platcheck_21
.+++++++++++++++************************%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%####
###################################
[annrpython:WARNING] <FunctionGraph of (engine.traces:210)EvalNode.unevaluate at 
0x992b46c> block at 233 op=3/ no precise annotation supplied for 
iter(SomePBC(can_be_None=True, const=None, subset_of=None),)
.+++++++++++++++************************%
[annrpython:WARNING] <FunctionGraph of (engine.xrp:171)categorical_XRP.prob at 
0x99e128c> block at 0 op=1/ no precise annotation supplied for 
iter(SomePBC(can_be_None=True, const=None, subset_of=None),)
.+++++++++++++++*******************
[annrpython:WARNING] <FunctionGraph of (engine.xrp:171)categorical_XRP.prob at 
0x99e128c> block at 0 op=1/ no precise annotation supplied for 
iter(SomePBC(can_be_None=True, const=None, subset_of=None),)
.+++++++++++++++************************%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%####
###################################################################%#%%%**********
***
[translation:info] RTyping...
.+++++++++++++++************************%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%####
###################################################################%#%%%**********
****
++++++++++++++********************%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
[rtyper] specializing: 200 / 3231 blocks   (6%)
++++++++++++++********************%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%####
####################################################################%%%%%%%*******
****
+++++++++++*******************%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%###%%%%####
################################################################
[rtyper] specializing: 600 / 4864 blocks   (12%)
+++++++++++*******************%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%###%%%%
[rtyper] specializing: 900 / 5255 blocks   (17%)
+++++++++++*******************%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%###%%%%####
########
[rtyper] specializing: 1300 / 5580 blocks   (23%)
+++++++++++*******************%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
[rtyper] specializing: 1700 / 5858 blocks   (29%)
+++++++++++*******************%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%###%%%%####
######################################################
[rtyper] specializing: 2200 / 6397 blocks   (34%)
+++++
[rtyper] specializing: 2300 / 6413 blocks   (35%)
[rtyper] specializing: 2600 / 6413 blocks   (40%)
+
[rtyper] specializing: 2900 / 6413 blocks   (45%)
++++++
[rtyper] specializing: 3300 / 6439 blocks   (51%)
[rtyper] specializing: 3700 / 6439 blocks   (57%)
[rtyper] specializing: 4000 / 6439 blocks   (62%)
++
[rtyper] specializing: 4400 / 6447 blocks   (68%)
[rtyper] specializing: 4800 / 6447 blocks   (74%)
+
[rtyper] specializing: 5100 / 6452 blocks   (79%)
[rtyper] specializing: 5500 / 6452 blocks   (85%)
++
[rtyper] specializing: 5900 / 6463 blocks   (91%)
[rtyper] specializing: 6300 / 6463 blocks   (97%)
[rtyper] -=- specialized 6463 blocks -=-
+++++++++++*************
[rtyper] specializing: 6500 / 6689 blocks   (97%)
[rtyper] -=- specialized 226 more blocks -=-
[rtyper] -=- specialized 2 more blocks -=-
+++
[rtyper] -=- specialized 7 more blocks -=-
[translation:info] lltype back-end optimisations...
[backendopt:inlining] phase with threshold factor: 32.4
[backendopt:inlining] heuristic: 
pypy.translator.backendopt.inline.inlining_heuristic
+++++++++++*******************%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%###%%%%####
##################################################################%%%%%%%%%%%%****
****
+++++++++*****************%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%#############
################################################################%%%%%%%%%%%%%%%%%*
****
+++++++****************%%%%##%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%##########
##################################################################%%%%%%%%%%%%%%%%
%***
+++++****************%%%%%%##%%%%%%%%%%%%%%%##%%%%%%%%%%%%%%%%%%%%%#%#############
#######################################################################%#%%%%%%%%%
%%%*
++++***************%%%%%%%%%%#%###%%%%%%%%%%%#####################################
#######################################################################%#%%%%%%%%%
%%%%
+++**************%%%%
[backendopt:inlining] inlined 3229 callsites.
[backendopt:malloc] starting malloc removal
+++**************%%%%%%%%%%%%%%%##################################################
#####################################################################%%%%%%%%%%%%%
%%%%
++*************%%%%%%%%%%%%%%%%###################################################
######################################################################%%#%%%%%%%%%
%%%%
+*************%%%%%%
[backendopt:malloc] removed 1214 simple mallocs in total
[backendopt:mergeifblocks] starting to merge if blocks
+*
[translation:info] inserting stack checks...
+*
[rtyper] specializing: 6700 / 6705 blocks   (99%)
[rtyper] -=- specialized 7 more blocks -=-
[translation:info] inserted 45 stack checks.
[translation:info] Creating database for generating c source...
+**********
[rtyper] -=- specialized 25 more blocks -=-
+*************%%%%%%%%%%%%%%%%####################################################
########################################################################%%%%%%%%%%
%%%%
*************%%%%%%%%%%###########################################################
####################################################
[rtyper] specializing: 6800 / 8176 blocks   (83%)
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gctypelayout.GCData object 
at 0xaf0238c> has no attribute 'root_stack_top'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gctypelayout.GCData object 
at 0xaf0238c> has no attribute 'root_stack_base'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gc.minimark.MiniMarkGC 
object at 0xaf02e8c> has no attribute 'young_objects_with_light_finalizers'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gc.minimark.MiniMarkGC 
object at 0xaf02e8c> has no attribute 'young_rawmalloced_objects'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gc.minimark.MiniMarkGC 
object at 0xaf02e8c> has no attribute 'rawmalloced_total_size'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gc.minimark.MiniMarkGC 
object at 0xaf02e8c> has no attribute 'next_major_collection_initial'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gc.minimark.MiniMarkGC 
object at 0xaf02e8c> has no attribute 'old_objects_with_light_finalizers'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gc.minimark.MiniMarkGC 
object at 0xaf02e8c> has no attribute '_debug_pending'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gc.minimark.MiniMarkGC 
object at 0xaf02e8c> has no attribute '_list_rpy'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gc.minimark.MiniMarkGC 
object at 0xaf02e8c> has no attribute 'tmpstack'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gc.minimark.MiniMarkGC 
object at 0xaf02e8c> has no attribute '_callback2_arg4'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gc.minimark.MiniMarkGC 
object at 0xaf02e8c> has no attribute '_debug_seen'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gc.minimark.MiniMarkGC 
object at 0xaf02e8c> has no attribute 'finalizer_lock_count'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gc.minimark.MiniMarkGC 
object at 0xaf02e8c> has no attribute '_callback2_arg3'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gc.minimark.MiniMarkGC 
object at 0xaf02e8c> has no attribute 'nursery_objects_shadows'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gc.minimark.MiniMarkGC 
object at 0xaf02e8c> has no attribute 'young_objects_with_weakrefs'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gc.minimark.MiniMarkGC 
object at 0xaf02e8c> has no attribute 'old_objects_with_weakrefs'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gc.minimark.MiniMarkGC 
object at 0xaf02e8c> has no attribute 'next_major_collection_threshold'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gc.minimark.MiniMarkGC 
object at 0xaf02e8c> has no attribute 'old_rawmalloced_objects'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gc.minimark.MiniMarkGC 
object at 0xaf02e8c> has no attribute 'objects_to_trace'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gc.minimark.MiniMarkGC 
object at 0xaf02e8c> has no attribute 'objects_with_finalizers'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gc.minimark.MiniMarkGC 
object at 0xaf02e8c> has no attribute '_count_rpy'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gc.minimark.MiniMarkGC 
object at 0xaf02e8c> has no attribute '_callback2_arg0'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gc.minimark.MiniMarkGC 
object at 0xaf02e8c> has no attribute '_callback2_arg1'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gc.minimark.MiniMarkGC 
object at 0xaf02e8c> has no attribute '_callback2_arg2'
[rtyper:WARNING] prebuilt instance <pypy.rpython.memory.gc.minimark.MiniMarkGC 
object at 0xaf02e8c> has no attribute 'run_finalizers'
*************%%%%%%%%%%############################
[rtyper] specializing: 7300 / 8282 blocks   (88%)
*************%%%%
[rtyper] specializing: 7800 / 8291 blocks   (94%)
*************%%%
[rtyper] specializing: 8200 / 8310 blocks   (98%)
[rtyper] -=- specialized 1580 more blocks -=-
**********
[platform:execute] gcc -c -O3 -pthread -fomit-frame-pointer -Wall -Wno-unused 
/tmp/usession-release-2.0-beta-1-12/platcheck_22.c -o /tmp/usession-release-2.0-
beta-1-12/platcheck_22.o
[platform:execute] gcc /tmp/usession-release-2.0-beta-1-12/platcheck_22.o -pthread 
-lrt -o /tmp/usession-release-2.0-beta-1-12/platcheck_22
[platform:execute] gcc -c -O3 -pthread -fomit-frame-pointer -Wall -Wno-unused 
/tmp/usession-release-2.0-beta-1-12/platcheck_23.c -o /tmp/usession-release-2.0-
beta-1-12/platcheck_23.o
[platform:execute] gcc /tmp/usession-release-2.0-beta-1-12/platcheck_23.o -pthread 
-lrt -o /tmp/usession-release-2.0-beta-1-12/platcheck_23
[platform:execute] gcc -c -O3 -pthread -fomit-frame-pointer -Wall -Wno-unused 
/tmp/usession-release-2.0-beta-1-12/platcheck_24.c -o /tmp/usession-release-2.0-
beta-1-12/platcheck_24.o
[platform:execute] gcc /tmp/usession-release-2.0-beta-1-12/platcheck_24.o -pthread 
-lrt -o /tmp/usession-release-2.0-beta-1-12/platcheck_24
*****
[Timer] Timings:
[Timer] annotate                       --- 17.6 s
[Timer] rtype_lltype                   --- 41.0 s
[Timer] backendopt_lltype              --- 23.6 s
[Timer] stackcheckinsertion_lltype     ---  0.3 s
[Timer] database_c                     --- 15.2 s
[Timer] =========================================
[Timer] Total:                         --- 97.8 s
[translation:ERROR] Error:
[translation:ERROR]  Traceback (most recent call last):
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/translator/goal/translate.py", line 303, in main
[translation:ERROR]     drv.proceed(goals)
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/translator/driver.py", line 771, in proceed
[translation:ERROR]     return self._execute(goals, task_skip = 
self._maybe_skip())
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/translator/tool/taskengine.py", line 116, in _execute
[translation:ERROR]     res = self._do(goal, taskcallable, *args, **kwds)
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/translator/driver.py", line 283, in _do
[translation:ERROR]     res = func()
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/translator/driver.py", line 486, in task_database_c
[translation:ERROR]     database = cbuilder.build_database()
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/translator/c/genc.py", line 150, in build_database
[translation:ERROR]     sandbox=self.config.translation.sandbox)
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/translator/c/database.py", line 62, in __init__
[translation:ERROR]     self.gctransformer = self.gcpolicy.gettransformer()
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/translator/c/gc.py", line 436, in gettransformer
[translation:ERROR]     return 
shadowstack.ShadowStackFrameworkGCTransformer(self.db.translator)
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/rpython/memory/gctransform/framework.py", line 480, in __init__
[translation:ERROR]     annhelper.finish()   # at this point, annotate all mix-
level helpers
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/rpython/annlowlevel.py", line 240, in finish
[translation:ERROR]     self.finish_rtype()
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/rpython/annlowlevel.py", line 290, in finish_rtype
[translation:ERROR]     rtyper.specialize_more_blocks()
[translation:ERROR]    File "/root/pypy-pypy-07e08e9c885c/pypy/rpython/rtyper.py", 
line 281, in specialize_more_blocks
[translation:ERROR]     annmixlevel.finish()
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/rpython/annlowlevel.py", line 239, in finish
[translation:ERROR]     self.finish_annotate()
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/rpython/annlowlevel.py", line 258, in finish_annotate
[translation:ERROR]     ann.complete_helpers(self.policy)
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/annotation/annrpython.py", line 124, in complete_helpers
[translation:ERROR]     self.complete()
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/annotation/annrpython.py", line 195, in complete
[translation:ERROR]     self.processblock(graph, block)
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/annotation/annrpython.py", line 340, in processblock
[translation:ERROR]     self.flowin(graph, block)
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/annotation/annrpython.py", line 399, in flowin
[translation:ERROR]     self.consider_op(block, i)
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/annotation/annrpython.py", line 593, in consider_op
[translation:ERROR]     resultcell = consider_meth(*argcells)
[translation:ERROR]    File "<91-codegen /root/pypy-pypy-
07e08e9c885c/pypy/annotation/annrpython.py:633>", line 3, in 
consider_op_simple_call
[translation:ERROR]     return arg.simple_call(*args)
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/annotation/unaryop.py", line 164, in simple_call
[translation:ERROR]     return obj.call(getbookkeeper().build_args("simple_call", 
args_s))
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/annotation/unaryop.py", line 717, in call
[translation:ERROR]     return bookkeeper.pbc_call(pbc, args)
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/annotation/bookkeeper.py", line 664, in pbc_call
[translation:ERROR]     results.append(desc.pycall(schedule, args, 
s_previous_result, op))
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/annotation/description.py", line 299, in pycall
[translation:ERROR]     result = schedule(graph, inputcells)
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/annotation/bookkeeper.py", line 660, in schedule
[translation:ERROR]     return self.annotator.recursivecall(graph, whence, 
inputcells)
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/annotation/annrpython.py", line 286, in recursivecall
[translation:ERROR]     self.addpendingblock(graph, graph.startblock, inputcells)
[translation:ERROR]    File "/root/pypy-pypy-
07e08e9c885c/pypy/annotation/annrpython.py", line 178, in addpendingblock
[translation:ERROR]     assert annmodel.unionof(s_oldarg, s_newarg) == s_oldarg
[translation:ERROR]  AssertionError: <
[translation:ERROR] Occurred processing the following simple_call:
[translation:ERROR]       (KeyError getting at the binding!)
[translation:ERROR]  v826 = simple_call((function str_from_buffer), raw_buf_0, 
gc_buf_0, v824, v825)
[translation:ERROR] In <FunctionGraph of 
(pypy.rpython.module.ll_os:890)os_read_llimpl at 0xb0340ac>:
[translation:ERROR] Happened at file /root/pypy-pypy-
07e08e9c885c/pypy/rpython/module/ll_os.py line 900
[translation:ERROR]
[translation:ERROR] ==>                 return rffi.str_from_buffer(raw_buf, 
gc_buf, count, got)
[translation:ERROR]
[translation:ERROR] Known variable annotations:
[translation:ERROR]  raw_buf_0 = SomePtr(ll_ptrtype=<* Array of Char >)
[translation:ERROR]  gc_buf_0 = SomePtr(const=<* None>, ll_ptrtype=<* GcStruct 
rpy_string { hash, chars }>)
[translation:ERROR]  v824 = SomeInteger(knowntype=int, nonneg=True, 
unsigned=False)
[translation:ERROR]  v825 = SomeInteger(knowntype=int, nonneg=True, 
unsigned=False)>
[translation:ERROR] Processing block:
[translation:ERROR]  block at 178 is a <class 
'pypy.objspace.flow.flowcontext.SpamBlock'>
[translation:ERROR]  in (pypy.rpython.module.ll_os:890)os_read_llimpl
[translation:ERROR]  containing the following operations:
[translation:ERROR]        v826 = simple_call((function str_from_buffer), 
raw_buf_0, gc_buf_0, v824, v825)
[translation:ERROR]  --end--
[translation] start debugger...
> /root/pypy-pypy-07e08e9c885c/pypy/annotation/annrpython.py(178)addpendingblock()
-> assert annmodel.unionof(s_oldarg, s_newarg) == s_oldarg
(Pdb+)

----------
messages: 5144
nosy: pypy-issue, wuthefwasthat
priority: bug
status: unread
title: assert error (happens on one machine but not another??)

________________________________________
PyPy bug tracker <tracker at bugs.pypy.org>
<https://bugs.pypy.org/issue1362>
________________________________________


More information about the pypy-issue mailing list