-
Notifications
You must be signed in to change notification settings - Fork 959
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Illegal instruction on Intel sandy bridge #29
Labels
build
build related issues
Comments
Try to make this change to src/CMakeLists.txt and see if it fixes the issue: diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index da46be3..c40ca97 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -30,7 +30,7 @@ if (${CMAKE_SYSTEM_PROCESSOR} MATCHES "arm" OR ${CMAKE_SYSTEM_PROCESSOR} MATCHES
#set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -mcpu=apple-m1")
else()
message(STATUS "x86 detected")
- set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -mavx -mavx2 -mfma -mf16c")
+ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -march=native")
endif() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Following the instructions on the readme, I get all the way to running the model. Then
./bin/gpt-2 -m models/gpt-2-117M/ggml-model.bin -p "This is an example"
gives me this output:main: seed = 1677652321
gpt2_model_load: loading model from 'models/gpt-2-117M/ggml-model.bin'
gpt2_model_load: n_vocab = 50257
gpt2_model_load: n_ctx = 1024
gpt2_model_load: n_embd = 768
gpt2_model_load: n_head = 12
gpt2_model_load: n_layer = 12
gpt2_model_load: f16 = 1
gpt2_model_load: ggml ctx size = 311.12 MB
Illegal instruction (core dumped)
According to everything I had read, my processor should support all of the required instruction sets. I have installed libmkl-avx21 and tried make clean/make all. Specs are i7 2600k and Ubuntu 22.04
The text was updated successfully, but these errors were encountered: