This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

ARM MUL instruction

Still more instruction things giving me head ache.

This time it's the MUL-instruction.

What the heck means:

Multiply multiplies two register values. The least significant 32 bits of the result are written to the destination

register. These 32 bits do not depend on whether the source register values are considered to be signed values or

unsigned values.

(The bolded part)

Parents
  • In other words, the result is not valid in the case overflow in the 32 bit range.

    So it's basically unsigned?

    It's still mystery for me, though, what this:

    if x<N-1> == '1' then result = result - 2^N;

    in the pseudocode of SInt(bits(N) x) is supposed to mean.

    '2^N - result' would be 2's complement, but 'result - 2^N' should be negative of that.

    I.e. result (or - -result)

Reply
  • In other words, the result is not valid in the case overflow in the 32 bit range.

    So it's basically unsigned?

    It's still mystery for me, though, what this:

    if x<N-1> == '1' then result = result - 2^N;

    in the pseudocode of SInt(bits(N) x) is supposed to mean.

    '2^N - result' would be 2's complement, but 'result - 2^N' should be negative of that.

    I.e. result (or - -result)

Children
No data