Did I find the right examples for you? yes no

All Samples(0)  |  Call(0)  |  Derive(0)  |  Import(0)

src/s/y/Sypy-HEAD/jit/metainterp/pyjitpl.py   Sypy(Download)
    def opimpl_guard_class(self, orgpc, box):
        clsbox = self.cls_of_box(box)
        if not self.metainterp.heapcache.is_class_known(box):
            self.generate_guard(rop.GUARD_CLASS, box, [clsbox], resumepc=orgpc)
            self.metainterp.heapcache.class_now_known(box)
    def opimpl_raise(self, orgpc, exc_value_box):
        # xxx hack
        clsbox = self.cls_of_box(exc_value_box)
        self.generate_guard(rop.GUARD_CLASS, exc_value_box, [clsbox],
                            resumepc=orgpc)
        elif opnum == rop.GUARD_FALSE:     # a goto_if_not that stops jumping
            pass
        elif opnum == rop.GUARD_VALUE or opnum == rop.GUARD_CLASS:
            pass        # the pc is already set to the *start* of the opcode
        elif (opnum == rop.GUARD_NONNULL or

src/p/l/plexnet-HEAD/third_party/generic/pypy/pypy/jit/metainterp/pyjitpl.py   plexnet(Download)
    def opimpl_instanceof(self, objbox, typedescr):
        frame = self.metainterp.framestack[-1]
        clsbox = self.cls_of_box(objbox)
        if isinstance(objbox, Box):
            self.generate_guard(frame.pc, rop.GUARD_CLASS, objbox, [clsbox])
    def opimpl_oosend(self, pc, methdescr, varargs):
        objbox = varargs[0]
        clsbox = self.cls_of_box(objbox)
        if isinstance(objbox, Box):
            self.generate_guard(pc, rop.GUARD_CLASS, objbox, [clsbox])
    def opimpl_guard_class(self, pc, box):
        clsbox = self.cls_of_box(box)
        if isinstance(box, Box):
            self.generate_guard(pc, rop.GUARD_CLASS, box, [clsbox])
        self.make_result_box(clsbox)

src/s/y/Sypy-HEAD/jit/metainterp/blackhole.py   Sypy(Download)
            pass
        #
        elif opnum == rop.GUARD_VALUE or opnum == rop.GUARD_CLASS:
            # Produced by guard_class(), xxx_guard_value(), or a few other
            # opcodes like switch().  The pc is at the start of the opcode

src/s/y/Sypy-HEAD/jit/metainterp/optimizeopt/optimizer.py   Sypy(Download)
            op = ResOperation(rop.GUARD_NONNULL, [box], None)
            guards.append(op)
            op = ResOperation(rop.GUARD_CLASS, [box, self.known_class], None)
            guards.append(op)
        else:

src/s/y/Sypy-HEAD/jit/metainterp/optimizeopt/virtualstate.py   Sypy(Download)
            op = ResOperation(rop.GUARD_NONNULL, [box], None)
            extra_guards.append(op)
            op = ResOperation(rop.GUARD_CLASS, [box, self.known_class], None)
            extra_guards.append(op)
            return

src/s/y/Sypy-HEAD/jit/backend/test/runner_test.py   Sypy(Download)
    def test_passing_guard_class(self):
        t_box, T_box = self.alloc_instance(self.T)
        #null_box = ConstPtr(lltype.cast_opaque_ptr(llmemory.GCREF, lltype.nullptr(T)))
        self.execute_operation(rop.GUARD_CLASS, [t_box, T_box], 'void')
        assert not self.guard_failed
    def test_failing_guard_class(self):
        t_box, T_box = self.alloc_instance(self.T)
        u_box, U_box = self.alloc_instance(self.U)
        null_box = self.null_instance()
        for opname, args in [(rop.GUARD_CLASS, [t_box, U_box]),
                             (rop.GUARD_CLASS, [u_box, T_box]),

src/s/y/Sypy-HEAD/jit/backend/test/test_ll_random.py   Sypy(Download)
 
for i in range(2):
    OPERATIONS.append(GuardClassOperation(rop.GUARD_CLASS))
    OPERATIONS.append(CallOperation(rop.CALL))
    OPERATIONS.append(RaisingCallOperation(rop.CALL))

src/p/l/plexnet-HEAD/third_party/generic/pypy/pypy/jit/backend/test/runner_test.py   plexnet(Download)
    def test_passing_guard_class(self):
        t_box, T_box = self.alloc_instance(self.T)
        #null_box = ConstPtr(lltype.cast_opaque_ptr(llmemory.GCREF, lltype.nullptr(T)))
        self.execute_operation(rop.GUARD_CLASS, [t_box, T_box], 'void')
        assert not self.guard_failed
    def test_failing_guard_class(self):
        t_box, T_box = self.alloc_instance(self.T)
        u_box, U_box = self.alloc_instance(self.U)        
        #null_box = ConstPtr(lltype.cast_opaque_ptr(llmemory.GCREF, lltype.nullptr(T)))
        for opname, args in [(rop.GUARD_CLASS, [t_box, U_box]),
                             (rop.GUARD_CLASS, [u_box, T_box]),

src/p/l/plexnet-HEAD/third_party/generic/pypy/pypy/jit/backend/test/test_ll_random.py   plexnet(Download)
 
for i in range(2):
    OPERATIONS.append(GuardClassOperation(rop.GUARD_CLASS))
    OPERATIONS.append(CallOperation(rop.CALL))
    OPERATIONS.append(RaisingCallOperation(rop.CALL))