Site Tools


Sidebar

Smart Card Solution

User Manual

JavaCard API Samples

Java Card Specification

Knowledge Sharing

javacard:jcvm:7.5.35_if_acmp_cond

7.5.35 if_acmp<cond>

Branch if reference comparison succeeds.

Format

if_acmp

branch

Forms

if_acmpeq = 104 (0x68) if_acmpne = 105 (0x69)

Stack

…, value1, value2 → …

Description

Both value1 and value2 must be of type reference. They are both popped from the operand stack and compared. The results of the comparisons are as follows:

  • eq succeeds if and only if value1 = value2
  • ne succeeds if and only if value1 value2

If the comparison succeeds, branch is used as signed 8-bit offset, and execution proceeds at that offset from the address of the opcode of this if_acmp instruction. The target address must be that of an opcode of an instruction within the method that contains this if_acmp instruction.

Otherwise, execution proceeds at the address of the instruction following this if_acmp instruction.

javacard/jcvm/7.5.35_if_acmp_cond.txt · Last modified: 2017/05/13 04:11 (external edit)