EMSBA

Extended multiply-subtract to the accumulator [V2.01.00 or later]

EMSBA

Extended Multiply-SuBtract to Accumulator


[Syntax]

EMSBA src, src2, Adest

 

[Operation]

signed 72bit tmp;

tmp = (signed long) src * (signed long) src2;

Adest = Adest - tmp;

 

[Function]

This instruction multiplies src by src2, and subtracts the result to the value in the accumulator (ACC). The result of subtraction is stored in ACC. src and src2 are treated as signed integers. You can assemble assembly-language code that includes this instruction if you have specified the assembler option -isa with selection of the instruction set of the RXv2 or a later version.

 

[Instruction Format]

Syntax

Operand

Code Size

(Byte)

src

src2

Adest

EMSBA src, src2, Adest

Rs

Rs2

A0, A1

3

Note

Specify A0 (ACC0) or A1 (ACC1) as Adest.

 

[Flag Change]

This instruction does not affect the states of flags.

 

[Description Example]

EMSBA R1, R2, A1