within configuration.nix would enable CPU optimization for the whole system. It however isn’t the case anymore, gcc.arch and gcc.tune have been, from as far as I can tell, discontinued.
How would one set CPU flags for the C compiler within NixOS 22.11? From reading about it I think
nixpkgs.localSystem = {
cpu = "cpufamily";
system = "x86_64-linux";
};
}
Would work but I can’t quite tell.
Can you please confirm the information I have found?
With these flags the build did start to run, but from what I could see with ps none of the invocations of gcc actually had the march or mtune flags set as I’d expect. I interrupted the build and have given up on this for the time being.
I would be very interested to hear if you figure out a solution to this, especially if you get the micro-architecture feature level build working.