Search in sources :

Example 1 with InstanceOfQuickNode

use of com.oracle.truffle.espresso.nodes.quick.InstanceOfQuickNode in project graal by oracle.

the class BytecodeNode method quickenInstanceOf.

private int quickenInstanceOf(VirtualFrame frame, int top, int curBCI, int opcode) {
    if (StaticObject.isNull(peekObject(frame, top - 1))) {
        // Skip resolution.
        putInt(frame, top - 1, 0);
        return -Bytecodes.stackEffectOf(opcode);
    }
    CompilerDirectives.transferToInterpreterAndInvalidate();
    assert opcode == INSTANCEOF;
    BaseQuickNode quick = tryPatchQuick(curBCI, () -> new InstanceOfQuickNode(resolveType(CHECKCAST, readCPI(curBCI)), top, curBCI));
    return quick.execute(frame) - Bytecodes.stackEffectOf(opcode);
}
Also used : InstanceOfQuickNode(com.oracle.truffle.espresso.nodes.quick.InstanceOfQuickNode) BaseQuickNode(com.oracle.truffle.espresso.nodes.quick.BaseQuickNode)

Aggregations

BaseQuickNode (com.oracle.truffle.espresso.nodes.quick.BaseQuickNode)1 InstanceOfQuickNode (com.oracle.truffle.espresso.nodes.quick.InstanceOfQuickNode)1