1    /*
2     * Check to see if a cast from one class to another is allowed.
3     */
4    /* check-cast vAA, class//BBBB */
5    EXPORT_PC
6    FETCH    w0, 1                      // w0<- BBBB
7    lsr      w1, wINST, #8              // w1<- AA
8    VREG_INDEX_TO_ADDR x1, w1           // w1<- &object
9    ldr      x2, [xFP, #OFF_FP_METHOD]  // w2<- method
10    mov      x3, xSELF                  // w3<- self
11    bl       MterpCheckCast             // (index, &obj, method, self)
12    PREFETCH_INST 2
13    cbnz     w0, MterpPossibleException
14    ADVANCE  2
15    GET_INST_OPCODE ip                  // extract opcode from rINST
16    GOTO_OPCODE ip                      // jump to next instruction
17