diff options
author | Andrew Waterman <andrew@sifive.com> | 2018-08-12 16:58:46 -0700 |
---|---|---|
committer | Andrew Waterman <andrew@sifive.com> | 2018-08-12 17:02:31 -0700 |
commit | 6fad4fb56922bb3d27a2862e3adc9fcd3106d8ec (patch) | |
tree | 5c495716ea55aa9f1a31cc071204bd8bbb97baba /src/m.tex | |
parent | b8bb0553a59da2f884605736d6a249af0e45ae1f (diff) | |
download | riscv-isa-manual-6fad4fb56922bb3d27a2862e3adc9fcd3106d8ec.zip riscv-isa-manual-6fad4fb56922bb3d27a2862e3adc9fcd3106d8ec.tar.gz riscv-isa-manual-6fad4fb56922bb3d27a2862e3adc9fcd3106d8ec.tar.bz2 |
Improve RV64 32x32->64 text; move to commentary
Diffstat (limited to 'src/m.tex')
-rw-r--r-- | src/m.tex | 13 |
1 files changed, 9 insertions, 4 deletions
@@ -60,10 +60,15 @@ with the less-significant words of the multiplicand (which are unsigned). MULW is an RV64 instruction that multiplies the lower 32 bits of the source registers, placing the sign-extension of the lower 32 bits of the result -into the destination register. In RV64, MUL can be used to obtain the upper -32 bits of the 64-bit product, but signed arguments must be proper 32-bit -signed values, whereas unsigned arguments must have their upper 32 bits -clear. +into the destination register. + +\begin{commentary} +In RV64, MUL can be used to obtain the upper 32 bits of the 64-bit product, +but signed arguments must be proper 32-bit signed values, whereas unsigned +arguments must have their upper 32 bits clear. If the +arguments are not known to be sign- or zero-extended, an alternative is to +shift both arguments left by 32 bits, then use MULH[[S]U]. +\end{commentary} \section{Division Operations} |