authorgravatar for hi@mihaelm.commihael <hi@mihaelm.com> 2026-03-20 20:45:22+01:00
committergravatar for hi@mihaelm.commihael <hi@mihaelm.com> 2026-04-02 23:54:19+02:00
logbd1dc8948f6093a13f1ac887b71fb71466b24f9e
tree118779f54a06139fc122ab39e36147c4842b9170
parent245c160a7b97e1dc8e0fd04e706d7abb36ac9f0c
signaturebadge-check Signed by SSH key SHA256:aoFoShdYLdrqMichqKXSSieTKUfACUIDJHsKc4V2tQg

`libzigc/math`: Remove straggler `rint` file in vendored MinGW

Seems like it was missed when implementing `rint`. This was checked by running: ``` $ ./build/stage3/bin/zig build -p stage4 -Denable-llvm -Dno-lib $ stage4/bin/zig build test-libc -Dlibc-test-path=<LIBC-TEST-PATH> -Dtest-filter=rint -fqemu -fwasmtime --summary line Build Summary: 2209/2209 steps succeeded ```

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

lib/c/math.zig+1-1
......@@ -49,6 +49,7 @@ comptime {
4949 }
5050
5151 if (builtin.target.isMinGW() or builtin.target.isMuslLibC()) {
52 symbol(&rint, "rint");
5253 symbol(&rintf, "rintf");
5354 }
5455
......@@ -81,7 +82,6 @@ comptime {
8182 if (builtin.target.isMuslLibC()) {
8283 symbol(&copysign, "copysign");
8384 symbol(&copysignf, "copysignf");
84 symbol(&rint, "rint");
8585 }
8686
8787 symbol(&copysignl, "copysignl");
lib/libc/mingw/math/arm64/rint.c deleted-12
......@@ -1,12 +0,0 @@
1/**
2 * This file has no copyright assigned and is placed in the Public Domain.
3 * This file is part of the mingw-w64 runtime package.
4 * No warranty is given; refer to the file DISCLAIMER.PD within this package.
5 */
6#include <math.h>
7
8double rint (double x) {
9 double retval = 0.0;
10 __asm__ __volatile__ ("frintx %d0, %d1\n\t" : "=w" (retval) : "w" (x));
11 return retval;
12}
src/libs/mingw.zig-1
......@@ -995,7 +995,6 @@ const mingw32_arm32_src = [_][]const u8{
995995
996996const mingw32_arm64_src = [_][]const u8{
997997 // mingwex
998 "math" ++ path.sep_str ++ "arm64" ++ path.sep_str ++ "rint.c",
999998 "math" ++ path.sep_str ++ "arm64" ++ path.sep_str ++ "sincos.S",
1000999};
10011000