Use floor and not udiv/sdiv

This commit is contained in:
Alex Beregszaszi 2017-07-03 21:31:23 +01:00
parent d4f5382f51
commit e5ca919672
1 changed files with 2 additions and 2 deletions

View File

@ -42,7 +42,7 @@ Notes:
The `SHR` instruction (logical shift right) pops 2 values from the stack, `arg1` and `arg2`, and pushes on the stack the first popped value `arg1` shifted to the right by the number of bits in the second popped value `arg2` with zero fill. The result is equal to
```
arg1 udiv 2^arg2
floor(arg1 / 2^arg2)
```
Notes:
@ -54,7 +54,7 @@ Notes:
The `SAR` instruction (arithmetic shift right) pops 2 values from the stack, `arg1` and `arg2`, and pushes on the stack the first popped value `arg1` shifted to the right by the number of bits in the second popped value `arg2` with sign extension. The result is equal to
```
arg1 sdiv 2^arg2
floor(arg1 / 2^arg2)
```
Notes: