Skip to content

Commit

Permalink
enable -O3 opt level for active eth kernels
Browse files Browse the repository at this point in the history
  • Loading branch information
SeanNijjar committed Feb 19, 2025
1 parent c17e35a commit 815121e
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions tt_metal/jit_build/build.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -438,7 +438,7 @@ JitBuildActiveEthernet::JitBuildActiveEthernet(const JitBuildEnv& env, const Jit
case 0: {
this->target_name_ = "active_erisc";
this->cflags_ =
env_.cflags_ + "-Os " + "-fno-tree-loop-distribute-patterns "; // don't use memcpy for cpy loops
env_.cflags_ + "-O3 " + "-fno-tree-loop-distribute-patterns "; // don't use memcpy for cpy loops

this->defines_ +=
"-DCOMPILE_FOR_ERISC "
Expand All @@ -452,7 +452,7 @@ JitBuildActiveEthernet::JitBuildActiveEthernet(const JitBuildEnv& env, const Jit
} else {
this->srcs_.push_back("tt_metal/hw/firmware/src/active_erisck.cc");
}
this->lflags_ = env_.lflags_ + "-Os ";
this->lflags_ = env_.lflags_ + "-O3 ";

if (this->is_fw_) {
this->lflags_ +=
Expand All @@ -466,7 +466,7 @@ JitBuildActiveEthernet::JitBuildActiveEthernet(const JitBuildEnv& env, const Jit
}
case 1: {
this->target_name_ = "erisc";
this->cflags_ = env_.cflags_ + "-Os -fno-delete-null-pointer-checks ";
this->cflags_ = env_.cflags_ + "-O3 -fno-delete-null-pointer-checks ";

this->defines_ +=
"-DCOMPILE_FOR_ERISC "
Expand All @@ -489,7 +489,7 @@ JitBuildActiveEthernet::JitBuildActiveEthernet(const JitBuildEnv& env, const Jit
linker_str = "tt_metal/hw/toolchain/erisc-b0-kernel.ld ";
}
this->lflags_ = env_.lflags_ +
"-Os "
"-O3 "
"-L" +
env_.root_ +
"/tt_metal/hw/toolchain "
Expand Down

0 comments on commit 815121e

Please sign in to comment.