BC.cond

Branch consistent conditionally

This instruction branches conditionally to a label at a PC-relative offset, with a hint that this branch will behave very consistently and is very unlikely to change direction.

Encoding: 19-bit signed PC-relative branch offset

Variants: FEAT_HBC (ARMv8.8)

313029282726252423222120191817161514131211109876543210
010101001
imm19o0cond

BC.<cond> <label>

Decoding algorithm

if !IsFeatureImplemented(FEAT_HBC) then EndOfDecode(Decode_UNDEF);
constant bits(64) offset = SignExtend(imm19:'00', 64);
constant bits(4) condition = cond;

Operation

constant boolean branch_conditional = TRUE;
if ConditionHolds(condition) then
    BranchTo(PC64 + offset, BranchType_DIR, branch_conditional);
else
    BranchNotTaken(BranchType_DIR, branch_conditional);

Explanations

<cond>: <label>: Is the program label to be conditionally branched to. Its offset from the address of this instruction, in the range +/-1MB, is encoded as "imm19" times 4.