Skip to content

Commit

Permalink
[build system] disable fortify hardening for verilated.nix
Browse files Browse the repository at this point in the history
Also remove `--output-split`. It's no longer nedded.
  • Loading branch information
FanShupei committed Jul 10, 2024
1 parent 85895b5 commit d6fbfa5
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion nix/t1/verilated.nix
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ stdenv.mkDerivation {
${lib.optionalString enable-trace "--trace-fst"} \
--timing \
--threads 8 \
--output-split 2048 \
-O3 \
--cc TestBench
Expand Down Expand Up @@ -53,4 +52,9 @@ stdenv.mkDerivation {
runHook postInstall
'';

# nix fortify hardening add `-O2` gcc flag,
# we'd like verilator to controll optimization flags, so disable it.
# `-O2` will make gcc build time in verilating extremely long
hardeningDisable = [ "fortify" ];
}

0 comments on commit d6fbfa5

Please sign in to comment.