std.Target.CpuFeatures is now a struct with both CPU and feature set
Previously it was a tagged union which was one of: * baseline * a specific CPU * a set of features Now, it's possible to have a CPU but also modify the CPU's feature set on top of that. This is closer to what LLVM does. This is more correct because Zig's notion of CPUs (and LLVM's) is not exact CPU models. For example "skylake" is not one very specific model; there are several different pieces of hardware that match "skylake" that have different feature sets enabled.
This commit is contained in:
@@ -8581,7 +8581,7 @@ Buf *codegen_generate_builtin_source(CodeGen *g) {
|
||||
stage2_cpu_features_get_builtin_str(g->zig_target->cpu_features, &ptr, &len);
|
||||
buf_append_mem(contents, ptr, len);
|
||||
} else {
|
||||
buf_append_str(contents, ".baseline;\n");
|
||||
buf_append_str(contents, "arch.getBaselineCpuFeatures();\n");
|
||||
}
|
||||
}
|
||||
if (g->libc_link_lib != nullptr && g->zig_target->glibc_version != nullptr) {
|
||||
|
||||
Reference in New Issue
Block a user