authorgravatar for alex@alexrp.comAlex Rønne Petersen <alex@alexrp.com> 2026-10-09 08:07:39+02:00
committergravatar for alex@alexrp.comAlex Rønne Petersen <alex@alexrp.com> 2026-10-10 08:36:07+02:00
loga3fe5cb793759d2b9526ac8b7ad96e30a08813d8
tree19e8b43cde8f94932da0357d3faeebf35bd0900b
parentcc410eaf341c7ad054cebcc010bb8e62fbc93098
signature Signed by SSH key SHA256:7B/LJ7bpR1eX8aCXSr4mtd5M45VMPKcx9zY8e95b5QM

test-standalone: remove zerolength_check

We don't need this anymore since our baseline CPU model for wasm is lime1.

3 files changed, 0 insertions(+), 54 deletions(-)

test/standalone/build.zig.zon-3
......@@ -138,9 +138,6 @@
138138 .strip_struct_init = .{
139139 .path = "strip_struct_init",
140140 },
141 .zerolength_check = .{
142 .path = "zerolength_check",
143 },
144141 .coff_dwarf = .{
145142 .path = "coff_dwarf",
146143 },
test/standalone/zerolength_check/build.zig deleted-27
......@@ -1,27 +0,0 @@
1const std = @import("std");
2
3pub fn build(b: *std.Build) void {
4 const test_step = b.step("test", "Test it");
5 b.default_step = test_step;
6
7 add(b, test_step, .debug);
8 add(b, test_step, .fast);
9 add(b, test_step, .small);
10 add(b, test_step, .safe);
11}
12
13fn add(b: *std.Build, test_step: *std.Build.Step, optimize: std.builtin.Optimize) void {
14 const unit_tests = b.addTest(.{ .root_module = b.createModule(.{
15 .root_source_file = b.path("src/main.zig"),
16 .target = b.resolveTargetQuery(.{
17 .os_tag = .wasi,
18 .cpu_arch = .wasm32,
19 .cpu_features_add = std.Target.wasm.featureSet(&.{.bulk_memory}),
20 }),
21 .optimize = optimize,
22 }) });
23
24 const run_unit_tests = b.addRunArtifact(unit_tests);
25 run_unit_tests.skip_foreign_checks = true;
26 test_step.dependOn(&run_unit_tests.step);
27}
test/standalone/zerolength_check/src/main.zig deleted-24
......@@ -1,24 +0,0 @@
1const std = @import("std");
2
3test {
4 const dest = foo();
5 const source = foo();
6
7 @memcpy(dest, source);
8 @memmove(dest, source);
9 @memset(dest, 4);
10 @memset(dest, undefined);
11
12 const dest2 = foo2();
13 @memset(dest2, 0);
14}
15
16fn foo() []u8 {
17 const ptr = comptime std.mem.alignBackward(usize, std.math.maxInt(usize), 1);
18 return @as([*]align(1) u8, @ptrFromInt(ptr))[0..0];
19}
20
21fn foo2() []u64 {
22 const ptr = comptime std.mem.alignBackward(usize, std.math.maxInt(usize), 1);
23 return @as([*]align(1) u64, @ptrFromInt(ptr))[0..0];
24}