remove various workarounds for issues that are now fixed (#31567)

Reviewed-on: https://codeberg.org/ziglang/zig/pulls/31567
Reviewed-by: Andrew Kelley <andrew@ziglang.org>
Co-authored-by: squidy239 <sachabarsayuracko@gmail.com>
Co-committed-by: squidy239 <sachabarsayuracko@gmail.com>
This commit is contained in:
squidy239
2026-03-20 19:58:33 +01:00
committed by Andrew Kelley
parent 83c7aba127
commit 4c3877069d
11 changed files with 10 additions and 36 deletions
+1 -2
View File
@@ -420,8 +420,7 @@ pub fn log(x: f64) callconv(.c) f64 {
// maybe use fma as musl does
const r = (z - tab2[i].chi - tab2[i].clo) * invc;
// https://github.com/ziglang/zig/issues/18614
const kd: f64 = @floatFromInt(k);
const kd: f64 = k;
const w = kd * 0x1.62e42fefa3800p-1 + logc;
const hi = w + r;
const lo = w - hi + r + kd * 0x1.ef35793c76730p-45;
+2 -12
View File
@@ -9,11 +9,6 @@ const assert = std.debug.assert;
const windows = std.os.windows;
test "concurrent vs main prevents deadlock via oversubscription" {
if (true) {
// https://codeberg.org/ziglang/zig/issues/30141
return error.SkipZigTest;
}
var threaded: Io.Threaded = .init(std.testing.allocator, .{
.argv0 = .empty,
.environ = .empty,
@@ -37,19 +32,14 @@ test "concurrent vs main prevents deadlock via oversubscription" {
}
fn put(io: Io, queue: *Io.Queue(u8)) void {
queue.putOneUncancelable(io, 42);
queue.putOneUncancelable(io, 42) catch unreachable;
}
fn get(io: Io, queue: *Io.Queue(u8)) void {
assert(queue.getOneUncancelable(io) == 42);
assert(queue.getOneUncancelable(io) catch unreachable == 42);
}
test "concurrent vs concurrent prevents deadlock via oversubscription" {
if (true) {
// https://codeberg.org/ziglang/zig/issues/30141
return error.SkipZigTest;
}
var threaded: Io.Threaded = .init(std.testing.allocator, .{
.argv0 = .empty,
.environ = .empty,
+1 -4
View File
@@ -45,10 +45,7 @@ pub const MemoryPoolOptions = memory_pool.Options;
///
/// On many systems, the actual page size can only be determined at runtime
/// with `pageSize`.
pub const page_size_min: usize = std.options.page_size_min orelse (page_size_min_default orelse 1);
//`orelse 1` is a workaround for https://codeberg.org/ziglang/zig/issues/30842
//@compileError(@tagName(builtin.cpu.arch) ++ "-" ++ @tagName(builtin.os.tag) ++ " has unknown page_size_min; populate std.options.page_size_min"));
pub const page_size_min: usize = std.options.page_size_min orelse (page_size_min_default orelse @compileError(@tagName(builtin.cpu.arch) ++ "-" ++ @tagName(builtin.os.tag) ++ " has unknown page_size_min; populate std.options.page_size_min"));
/// comptime-known maximum page size of the target.
///
/// Targeting a system with a larger page size may require overriding
+1 -2
View File
@@ -482,8 +482,7 @@ pub fn FieldEnum(comptime T: type) type {
}
fn expectEqualEnum(expected: anytype, actual: @TypeOf(expected)) !void {
// TODO: https://github.com/ziglang/zig/issues/7419
// testing.expectEqual(@typeInfo(expected).@"enum", @typeInfo(actual).@"enum");
try testing.expectEqual(@typeInfo(expected).@"enum", @typeInfo(actual).@"enum");
try testing.expectEqual(
@typeInfo(expected).@"enum".tag_type,
@typeInfo(actual).@"enum".tag_type,
+1 -2
View File
@@ -736,8 +736,7 @@ pub fn markImportsExports(self: *Object, elf_file: *Elf) void {
const ref = self.resolveSymbol(@intCast(idx), elf_file);
const sym = elf_file.symbol(ref) orelse continue;
const file = sym.file(elf_file).?;
// https://github.com/ziglang/zig/issues/21678
if (@as(u16, @bitCast(sym.version_index)) == @as(u16, @bitCast(elf.Versym.LOCAL))) continue;
if (sym.version_index == elf.Versym.LOCAL) continue;
const vis: elf.STV = @enumFromInt(@as(u3, @truncate(sym.elfSym(elf_file).st_other)));
if (vis == .HIDDEN) continue;
if (file == .shared_object and !sym.isAbs(elf_file)) {
+1 -3
View File
@@ -281,9 +281,7 @@ pub fn parse(
else
.{ .VERSION = versyms[i].VERSION, .HIDDEN = false };
// https://github.com/ziglang/zig/issues/21678
//if (ver == .LOCAL) continue;
if (@as(u16, @bitCast(ver)) == 0) continue;
if (ver == elf.Versym.LOCAL) continue;
try nonlocal_esyms.ensureUnusedCapacity(gpa, 1);
try nonlocal_versyms.ensureUnusedCapacity(gpa, 1);
+1 -2
View File
@@ -693,8 +693,7 @@ pub fn markImportsExports(self: *ZigObject, elf_file: *Elf) void {
const ref = self.resolveSymbol(@intCast(i | global_symbol_bit), elf_file);
const sym = elf_file.symbol(ref) orelse continue;
const file = sym.file(elf_file).?;
// https://github.com/ziglang/zig/issues/21678
if (@as(u16, @bitCast(sym.version_index)) == @as(u16, @bitCast(elf.Versym.LOCAL))) continue;
if (sym.version_index == elf.Versym.LOCAL) continue;
const vis: elf.STV = @enumFromInt(@as(u3, @truncate(sym.elfSym(elf_file).st_other)));
if (vis == .HIDDEN) continue;
if (file == .shared_object and !sym.isAbs(elf_file)) {
+1 -2
View File
@@ -1372,8 +1372,7 @@ pub const VerneedSection = struct {
for (verneed.items[1..]) |ver| {
if (ver.shared_object == last.shared_object) {
// https://github.com/ziglang/zig/issues/21678
if (@as(u16, @bitCast(ver.version_index)) != @as(u16, @bitCast(last.version_index))) {
if (ver.version_index != last.version_index) {
last_vernaux = try vern.addVernaux(last_verneed, ver.versionString(elf_file), elf_file);
}
} else {
-5
View File
@@ -217,11 +217,6 @@ test "atomicrmw with ints" {
if (builtin.zig_backend == .stage2_spirv) return error.SkipZigTest;
if (builtin.zig_backend == .stage2_riscv64) return error.SkipZigTest;
if (builtin.zig_backend == .stage2_llvm and builtin.cpu.arch.isMIPS()) {
// https://github.com/ziglang/zig/issues/16846
return error.SkipZigTest;
}
try testAtomicRmwInts();
try comptime testAtomicRmwInts();
}
-1
View File
@@ -3,7 +3,6 @@ const std = @import("std");
test "@prefetch()" {
if (builtin.zig_backend == .stage2_spirv) return error.SkipZigTest;
if (builtin.zig_backend == .stage2_llvm and builtin.cpu.arch.isLoongArch()) return error.SkipZigTest; // https://github.com/llvm/llvm-project/issues/134624
var a: [2]u32 = .{ 42, 42 };
var a_len = a.len;
+1 -1
View File
@@ -74,7 +74,7 @@ pub fn testAll(b: *Build, build_opts: BuildOptions) *Step {
elf_step.dependOn(testImageBase(b, .{ .target = musl_target }));
elf_step.dependOn(testInitArrayOrder(b, .{ .target = musl_target }));
elf_step.dependOn(testLargeAlignmentExe(b, .{ .target = musl_target }));
// https://github.com/ziglang/zig/issues/17449
// https://codeberg.org/ziglang/zig/issues/31580
// elf_step.dependOn(testLargeBss(b, .{ .target = musl_target }));
elf_step.dependOn(testLinkingC(b, .{ .target = musl_target }));
elf_step.dependOn(testLinkingCpp(b, .{ .target = musl_target }));