File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change 71
71
# note: adding -fno-inline fixes the tests when using MTL_SHADER_VALIDATION=1
72
72
# note: unfortunately, we have to call it default.metallib instead of ggml.metallib
73
73
# ref: https://github.com/ggerganov/whisper.cpp/issues/1720
74
- set (XC_FLAGS -fno-fast-math -fno-inline -g )
74
+ # note: adding -g causes segmentation fault during compile
75
+ #set(XC_FLAGS -fno-fast-math -fno-inline -g)
76
+ set (XC_FLAGS -fno-fast-math -fno-inline )
75
77
else ()
76
78
set (XC_FLAGS -O3 )
77
79
endif ()
90
92
add_custom_command (
91
93
OUTPUT ${CMAKE_RUNTIME_OUTPUT_DIRECTORY} /default.metallib
92
94
COMMAND xcrun -sdk macosx metal ${XC_FLAGS} -c ${CMAKE_RUNTIME_OUTPUT_DIRECTORY} /ggml-metal.metal -o - |
93
- xcrun -sdk macosx metallib - -o ${CMAKE_RUNTIME_OUTPUT_DIRECTORY} /default.metallib
95
+ xcrun -sdk macosx metallib - -o ${CMAKE_RUNTIME_OUTPUT_DIRECTORY} /default.metallib
94
96
COMMAND rm -f ${CMAKE_RUNTIME_OUTPUT_DIRECTORY} /ggml-common.h
95
97
COMMAND rm -f ${CMAKE_RUNTIME_OUTPUT_DIRECTORY} /ggml-metal.metal
96
98
DEPENDS ggml-metal.metal ${METALLIB_COMMON}
You can’t perform that action at this time.
0 commit comments