build: enable SSE4.1+FMA+AVX for silicon_sse compilation unit

Was compiling with baseline SSE2 only. Now matches bone_sse target.
Free wins: packParticleColor 1.2x->4.6x, rotateMatByQuat 3.4x->4.0x,
normalizeVec3 1.1x->1.8x, mulMat3x4InPlace 1.4x->1.7x.
This commit is contained in:
MarcelineVQ
2026-03-17 00:27:48 -07:00
parent b27a987355
commit bad3126973
+6 -2
View File
@@ -106,7 +106,7 @@ pub fn build(b: *std.Build) void {
.name = "silicon_sse",
.root_module = b.createModule(.{
.root_source_file = b.path("src/silicon/silicon_sse.zig"),
.target = target,
.target = bone_sse_target, // SSE4.1+FMA+AVX, same as bone_sse
.optimize = .ReleaseFast,
}),
});
@@ -162,7 +162,11 @@ pub fn build(b: *std.Build) void {
.name = "bench_silicon_sse",
.root_module = b.createModule(.{
.root_source_file = b.path("src/silicon/silicon_sse.zig"),
.target = bench_target,
.target = b.resolveTargetQuery(.{
.cpu_arch = .x86,
.os_tag = .linux,
.cpu_features_add = std.Target.x86.featureSet(&.{ .sse, .sse2, .sse3, .sse4_1, .fma, .avx }),
}),
.optimize = .ReleaseFast,
}),
});