authorgravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2019-04-10 16:29:10-04:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2019-04-10 16:29:10-04:00
log52934851f2b7a5cb28a08beafa1ec1aa24a3a4cb
tree01152f14d06a9f6c0e25c585ffdb4837041059fb
parentaff2e47821aaad5cac74ed8a3cac2e72283b594b
signaturelock-open Commit is signed but in an unrecognized format.

compiler_rt: `@divTrunc` rather than `@divFloor` in muloti4


1 files changed, 2 insertions(+), 3 deletions(-)

std/special/compiler_rt/muloti4.zig+2-3
......@@ -1,4 +1,3 @@
1const udivmod = @import("udivmod.zig").udivmod;
21const builtin = @import("builtin");
32const compiler_rt = @import("../compiler_rt.zig");
43
......@@ -33,11 +32,11 @@ pub extern fn __muloti4(a: i128, b: i128, overflow: *c_int) i128 {
3332 }
3433
3534 if (sa == sb) {
36 if (abs_a > @divFloor(max, abs_b)) {
35 if (abs_a > @divTrunc(max, abs_b)) {
3736 overflow.* = 1;
3837 }
3938 } else {
40 if (abs_a > @divFloor(min, -abs_b)) {
39 if (abs_a > @divTrunc(min, -abs_b)) {
4140 overflow.* = 1;
4241 }
4342 }