You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@minux Looking at https://github.com/golang/go/blob/master/src/runtime/vlrt.go, it seems like there should be. int64div and int64mod both just call a common dodiv function that calculates (quotient, remainder), and then they return the appropriate value. So they seem like they should be roughly identical in cost.
The int64div form also costs 48 extra bytes of 386 instructions and 52 extra bytes of arm instructions compared to just calling int64mod.
Compiling:
for 386 or arm compiles as
even though we're not able to do anything to optimize the
* 1e9
multiplication. We might as well just callruntime.int64mod
.The text was updated successfully, but these errors were encountered: