Skip to content

Commit

Permalink
make : fix missing -O3 (#8143)
Browse files Browse the repository at this point in the history
  • Loading branch information
slaren authored Jun 26, 2024
1 parent f2d48ff commit c7ab7b6
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -148,12 +148,6 @@ ifndef UNAME_M
UNAME_M := $(shell uname -m)
endif

MK_CFLAGS += -O3
MK_CXXFLAGS += -O3
ifndef LLAMA_DEBUG
MK_NVCCFLAGS += -O3
endif # LLAMA_DEBUG

# In GNU make default CXX is g++ instead of c++. Let's fix that so that users
# of non-gcc compilers don't have to provide g++ alias or wrapper.
DEFCC := cc
Expand Down Expand Up @@ -312,7 +306,10 @@ ifdef LLAMA_DEBUG
MK_CPPFLAGS += -D_GLIBCXX_ASSERTIONS
endif
else
MK_CPPFLAGS += -DNDEBUG
MK_CPPFLAGS += -DNDEBUG
MK_CFLAGS += -O3
MK_CXXFLAGS += -O3
MK_NVCCFLAGS += -O3
endif

ifdef LLAMA_SANITIZE_THREAD
Expand Down

0 comments on commit c7ab7b6

Please sign in to comment.