Module ImportFrom alias ImportFrom alias ClassDef bases NameLoad body Assign NameStore Dict FunctionDef arguments args NameParam defaults body Assign NameStore Call NameLoad keyword TupleLoad Str AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Import alias alias Assign NameStore AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assert CompareIs NameLoad NameLoad Assert CompareIs AttributeLoad NameLoad attr AttributeLoad NameLoad attr Assert CompareIs AttributeLoad NameLoad attr AttributeLoad NameLoad attr Assert CompareIs AttributeLoad NameLoad attr AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Import alias alias Assign NameStore AttributeLoad AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assert CompareIs NameLoad NameLoad decorator_list decorator_list ClassDef bases NameLoad body Pass decorator_list ClassDef bases NameLoad body Assign NameStore Dict Str NameLoad decorator_list ClassDef bases NameLoad body FunctionDef arguments args NameParam NameParam defaults body Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Return CompareEq AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr decorator_list decorator_list ClassDef bases NameLoad body FunctionDef arguments args NameParam NameParam NameParam NameParam defaults body Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr BinOpAdd BinOpAdd Call NameLoad NameLoad Call NameLoad BinOpBitAnd NameLoad Num Call NameLoad BinOpBitAnd BinOpRShift NameLoad Num Num decorator_list FunctionDef arguments args NameParam NameParam defaults body Return CompareEq SubscriptLoad AttributeLoad NameLoad attr Slice BinOpSub NameLoad Num NameLoad AttributeLoad NameLoad attr decorator_list decorator_list ClassDef bases NameLoad body Assign NameStore Dict FunctionDef arguments args NameParam defaults body Assign NameStore Call NameLoad keyword TupleLoad Str AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr NameLoad ImportFrom alias Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr FunctionDef arguments args NameParam NameParam defaults vararg body If CompareIs NameLoad NameLoad body Assign NameStore ListLoad Return BinOpAdd NameLoad ListLoad TupleLoad NameLoad NameLoad decorator_list Assign AttributeStore NameLoad attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr ListLoad Str Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign AttributeStore NameLoad attr SubscriptLoad NameLoad Index Str Assign AttributeStore NameLoad attr SubscriptLoad NameLoad Index Str Assign AttributeStore NameLoad attr SubscriptLoad NameLoad Index Str Assign AttributeStore NameLoad attr Call NameLoad NameLoad AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body ImportFrom alias Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults body Assign AttributeStore NameLoad attr Num Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Assert CompareEq AttributeLoad NameLoad attr Call NameLoad AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults vararg body Assign NameStore AttributeLoad NameLoad attr Assert CompareEq SubscriptLoad NameLoad Index AttributeLoad NameLoad attr TupleLoad NameLoad NameLoad AugAssignAdd AttributeStore NameLoad attr Num decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr ListLoad Str Assign TupleStore NameStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore AttributeLoad AttributeLoad NameLoad attr attr Assign NameStore AttributeLoad AttributeLoad NameLoad attr attr Expr Call AttributeLoad NameLoad attr NameLoad Assign NameStore AttributeLoad NameLoad attr Expr Call NameLoad Str Expr Call NameLoad Str AttributeLoad NameLoad attr Expr Call NameLoad Str AttributeLoad NameLoad attr Expr Call NameLoad Str Call NameLoad Str NameLoad Expr Call NameLoad Str Call NameLoad Str NameLoad NameLoad Expr Call NameLoad Str Call NameLoad Str NameLoad NameLoad Expr Call NameLoad Str Call NameLoad Str NameLoad Call NameLoad NameLoad AttributeLoad NameLoad attr Num NameLoad Expr Call NameLoad Str Call NameLoad Str Num Expr Call NameLoad Str Call NameLoad Str NameLoad Expr Call NameLoad Str Call NameLoad Str NameLoad NameLoad Expr Call NameLoad Str Call NameLoad Str NameLoad NameLoad Expr Call NameLoad Str Call NameLoad Str NameLoad Call NameLoad NameLoad AttributeLoad NameLoad attr Num NameLoad Expr Call NameLoad AttributeLoad NameLoad attr Call NameLoad Str Num Expr Call NameLoad Str AttributeLoad NameLoad attr NameLoad Expr Call NameLoad Str AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr ListLoad Str Assign TupleStore NameStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore AttributeLoad AttributeLoad NameLoad attr attr Assign NameStore AttributeLoad AttributeLoad NameLoad attr attr Expr Call AttributeLoad NameLoad attr NameLoad Assign NameStore AttributeLoad NameLoad attr Expr Call NameLoad Str Expr Call NameLoad Str AttributeLoad NameLoad attr Expr Call NameLoad Str AttributeLoad NameLoad attr Expr Call NameLoad Str Call NameLoad Str NameLoad Expr Call NameLoad Str Call NameLoad Str NameLoad NameLoad Expr Call NameLoad Str Call NameLoad Str NameLoad NameLoad Expr Call NameLoad Str Call NameLoad Str NameLoad Call NameLoad NameLoad AttributeLoad NameLoad attr BinOpAdd Num BinOpLShift Num Num NameLoad Expr Call NameLoad Str Call NameLoad Str Expr Call NameLoad Str Call NameLoad Str NameLoad Expr Call NameLoad Str Call NameLoad Str NameLoad NameLoad Expr Call NameLoad Str Call NameLoad Str NameLoad NameLoad Expr Call NameLoad Str Call NameLoad Str NameLoad Call NameLoad NameLoad AttributeLoad NameLoad attr Num NameLoad Expr Call NameLoad AttributeLoad NameLoad attr Call NameLoad Str Num Expr Call NameLoad Str AttributeLoad NameLoad attr NameLoad Expr Call NameLoad Str AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr ListLoad Str Assign TupleStore NameStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore AttributeLoad AttributeLoad NameLoad attr attr Assign NameStore AttributeLoad AttributeLoad NameLoad attr attr Expr Call AttributeLoad NameLoad attr NameLoad Assign NameStore AttributeLoad NameLoad attr Expr Call NameLoad Str Expr Call NameLoad Str AttributeLoad NameLoad attr Expr Call NameLoad Str AttributeLoad NameLoad attr Expr Call NameLoad Str Call NameLoad Str NameLoad Expr Call NameLoad Str Call NameLoad Str NameLoad NameLoad Expr Call NameLoad Str Call NameLoad Str NameLoad NameLoad Expr Call NameLoad Str Call NameLoad Str NameLoad Call NameLoad NameLoad AttributeLoad NameLoad attr Num NameLoad Expr Call NameLoad AttributeLoad NameLoad attr Call NameLoad Str Num Expr Call NameLoad Str Call NameLoad Str NameLoad Expr Call NameLoad Str Call NameLoad Str NameLoad NameLoad Expr Call NameLoad Str Call NameLoad Str NameLoad NameLoad Expr Call NameLoad Str Call NameLoad Str NameLoad Call NameLoad NameLoad AttributeLoad NameLoad attr Num NameLoad Expr Call NameLoad AttributeLoad NameLoad attr Call NameLoad Str Num Expr Call NameLoad Str AttributeLoad NameLoad attr NameLoad Expr Call NameLoad Str AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr decorator_list decorator_list ClassDef bases NameLoad body Assign NameStore Str decorator_list ClassDef bases NameLoad body Assign NameStore Dict Str NameLoad Assign NameStore Str decorator_list
N/A pypy.conftest gettestobjspace py.test skip BaseAppTestPicklePrerequisites N/A object N/A N/A OPTIONS N/A setup_class N/A N/A cls N/A N/A N/A space N/A gettestobjspace usemodules N/A _stackless N/A cls OPTIONS N/A N/A cls space space N/A test_pickle_switch_function N/A N/A object N/A N/A N/A _stackless pickle N/A sw N/A N/A N/A _stackless coroutine switch im_func N/A dump N/A N/A pickle dumps sw N/A res N/A N/A pickle loads dump N/A N/A res sw N/A N/A N/A res func_code N/A sw func_code N/A N/A N/A res func_doc N/A sw func_doc N/A N/A N/A res func_globals N/A sw func_globals N/A test_pickle_switch_function_code N/A N/A object N/A N/A N/A _stackless pickle N/A sw N/A N/A N/A N/A _stackless coroutine switch im_func func_code N/A dump N/A N/A pickle dumps sw N/A res N/A N/A pickle loads dump N/A N/A res sw N/A N/A AppTestPicklePrerequisites N/A BaseAppTestPicklePrerequisites N/A N/A N/A AppTestPicklePrerequisitesBuiltinShortcut N/A BaseAppTestPicklePrerequisites N/A N/A OPTIONS N/A objspace.std.builtinshortcut True N/A FrameCheck N/A object N/A __init__ N/A N/A self name N/A N/A N/A N/A self name name N/A __eq__ N/A N/A self frame N/A N/A N/A N/A N/A N/A frame pycode co_name N/A self name N/A N/A BytecodeCheck N/A object N/A __init__ N/A N/A self code op arg N/A N/A N/A N/A self code code N/A N/A self op N/A N/A N/A chr op N/A chr N/A arg 255 N/A chr N/A N/A arg 8 255 N/A __eq__ N/A N/A self pos N/A N/A N/A N/A N/A N/A self code N/A N/A pos 3 pos N/A self op N/A N/A BaseTestReconstructFrameChain N/A object N/A N/A OPTIONS N/A setup_class N/A N/A cls N/A N/A N/A space N/A gettestobjspace usemodules N/A _stackless N/A cls OPTIONS N/A N/A cls space space pypy.rlib rstack N/A N/A cls old_resume_state_create N/A rstack resume_state_create tr N/A N/A prevstate label N/A args N/A N/A N/A prevstate None N/A N/A prevstate N/A N/A N/A prevstate N/A N/A label args N/A N/A N/A rstack resume_state_create tr N/A w_opmap N/A N/A space appexec N/A ():
        import opcode

        return opcode.opmap
         N/A opmap N/A N/A space unwrap w_opmap N/A N/A cls CALL_FUNCTION N/A opmap N/A CALL_FUNCTION N/A N/A cls CALL_FUNCTION_VAR N/A opmap N/A CALL_FUNCTION_VAR N/A N/A cls CALL_METHOD N/A opmap N/A CALL_METHOD N/A N/A cls callmethod N/A getattr cls N/A cls callmethod_label N/A teardown_class N/A N/A cls N/A N/A pypy.rlib rstack N/A N/A rstack resume_state_create N/A cls old_resume_state_create N/A start N/A N/A self w_coro N/A N/A N/A N/A self i 0 N/A N/A self frame_to_check N/A w_coro frame N/A N/A w_coro frame None N/A end N/A N/A self N/A N/A N/A N/A N/A self i N/A len N/A self frame_to_check N/A check_entry N/A N/A self label N/A args N/A N/A frame N/A self frame_to_check N/A N/A N/A frame N/A N/A self i N/A label args N/A N/A self i 1 N/A test_two_frames_simple N/A N/A self N/A N/A N/A space N/A self space N/A w_res N/A N/A space appexec N/A ():
        import _stackless as stackless
        import pickle

        main = stackless.coroutine.getcurrent()
        d = {'main': main}        

        exec """
def f():
    g(1)

def g(x):
    main.switch()
""" in d
        f = d['f']
        g = d['g']

        co = stackless.coroutine()
        co.bind(f)
        co.switch()

        s = pickle.dumps(co)
        co = pickle.loads(s)

        return co, f, g
         N/A N/A w_co w_f w_g N/A N/A space viewiterable w_res N/A ec N/A N/A space getexecutioncontext N/A fcode N/A N/A w_f code co_code N/A gcode N/A N/A w_g code co_code N/A N/A N/A self start w_co N/A e N/A self check_entry N/A N/A e yield_current_frame_to_caller_1 N/A N/A e coroutine__bind N/A w_co costate N/A N/A e appthunk N/A w_co costate N/A N/A e execute_frame N/A FrameCheck f ec N/A N/A e dispatch N/A FrameCheck f fcode ec N/A N/A e handle_bytecode N/A FrameCheck f fcode ec N/A N/A e dispatch_call N/A FrameCheck f fcode N/A BytecodeCheck fcode N/A self CALL_FUNCTION 1 ec N/A N/A e CALL_FUNCTION N/A FrameCheck f 1 N/A N/A e execute_frame N/A FrameCheck g ec N/A N/A e dispatch N/A FrameCheck g gcode ec N/A N/A e handle_bytecode N/A FrameCheck g gcode ec N/A N/A e dispatch_call N/A FrameCheck g gcode N/A BytecodeCheck gcode N/A self callmethod 0 ec N/A N/A e N/A self callmethod_label N/A FrameCheck g 0 N/A N/A e w_switch N/A w_co costate space N/A N/A e coroutine_switch N/A w_co costate N/A N/A N/A self end N/A test_two_frames_stararg N/A N/A self N/A N/A N/A space N/A self space N/A w_res N/A N/A space appexec N/A ():
        import _stackless as stackless
        import pickle
        
        main = stackless.coroutine.getcurrent()
        d = {'main': main}        

        exec """        
def f():
    g(4, 3, d=2, *(1,))

def g(a, b, c, d):
    main.switch()
""" in d
        f = d['f']
        g = d['g']    

        co = stackless.coroutine()
        co.bind(f)
        co.switch()

        s = pickle.dumps(co)
        co = pickle.loads(s)

        return co, f, g
         N/A N/A w_co w_f w_g N/A N/A space viewiterable w_res N/A ec N/A N/A space getexecutioncontext N/A fcode N/A N/A w_f code co_code N/A gcode N/A N/A w_g code co_code N/A N/A N/A self start w_co N/A e N/A self check_entry N/A N/A e yield_current_frame_to_caller_1 N/A N/A e coroutine__bind N/A w_co costate N/A N/A e appthunk N/A w_co costate N/A N/A e execute_frame N/A FrameCheck f ec N/A N/A e dispatch N/A FrameCheck f fcode ec N/A N/A e handle_bytecode N/A FrameCheck f fcode ec N/A N/A e dispatch_call N/A FrameCheck f fcode N/A BytecodeCheck fcode N/A self CALL_FUNCTION_VAR N/A 2 N/A 1 8 ec N/A N/A e call_function N/A FrameCheck f N/A N/A e execute_frame N/A FrameCheck g ec N/A N/A e dispatch N/A FrameCheck g gcode ec N/A N/A e handle_bytecode N/A FrameCheck g gcode ec N/A N/A e dispatch_call N/A FrameCheck g gcode N/A BytecodeCheck gcode N/A self callmethod 0 ec N/A N/A e N/A self callmethod_label N/A FrameCheck g 0 N/A N/A e w_switch N/A w_co costate space N/A N/A e coroutine_switch N/A w_co costate N/A N/A N/A self end N/A test_two_frames_method N/A N/A self N/A N/A N/A space N/A self space N/A w_res N/A N/A space appexec N/A ():
        import _stackless as stackless
        import pickle
        import new, sys

        mod = new.module('mod')
        sys.modules['mod'] = mod
        
        main = stackless.coroutine.getcurrent()
        d = {'main': main}        

        exec """                
def f():
    a = A()
    a.m(1)

def g(_, x):
    main.switch()

class A(object):
    m = g
""" in d
        f = d['f']
        g = d['g']
        A = d['A']

        # to make pickling work
        mod.A = A
        A.__module__ = 'mod'

        co = stackless.coroutine()
        co.bind(f)
        co.switch()

        s = pickle.dumps(co)
        co = pickle.loads(s)

        return co, f, g
         N/A N/A w_co w_f w_g N/A N/A space viewiterable w_res N/A ec N/A N/A space getexecutioncontext N/A fcode N/A N/A w_f code co_code N/A gcode N/A N/A w_g code co_code N/A N/A N/A self start w_co N/A e N/A self check_entry N/A N/A e yield_current_frame_to_caller_1 N/A N/A e coroutine__bind N/A w_co costate N/A N/A e appthunk N/A w_co costate N/A N/A e execute_frame N/A FrameCheck f ec N/A N/A e dispatch N/A FrameCheck f fcode ec N/A N/A e handle_bytecode N/A FrameCheck f fcode ec N/A N/A e dispatch_call N/A FrameCheck f fcode N/A BytecodeCheck fcode N/A self callmethod 1 ec N/A N/A e N/A self callmethod_label N/A FrameCheck f 1 N/A N/A e execute_frame N/A FrameCheck g ec N/A N/A e dispatch N/A FrameCheck g gcode ec N/A N/A e handle_bytecode N/A FrameCheck g gcode ec N/A N/A e dispatch_call N/A FrameCheck g gcode N/A BytecodeCheck gcode N/A self callmethod 0 ec N/A N/A e N/A self callmethod_label N/A FrameCheck g 0 N/A N/A e w_switch N/A w_co costate space N/A N/A e coroutine_switch N/A w_co costate N/A N/A N/A self end N/A N/A TestReconstructFrameChain N/A BaseTestReconstructFrameChain N/A N/A callmethod_label CALL_FUNCTION N/A TestReconstructFrameChain_CALL_METHOD N/A BaseTestReconstructFrameChain N/A N/A OPTIONS N/A objspace.opcodes.CALL_METHOD True N/A callmethod_label CALL_METHOD N/A