Skip to content
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

Bug: Build error on Clang #8677

Closed
kaetemi opened this issue Jul 24, 2024 · 1 comment · Fixed by #8683
Closed

Bug: Build error on Clang #8677

kaetemi opened this issue Jul 24, 2024 · 1 comment · Fixed by #8683
Labels
bug-unconfirmed high severity Used to report high severity bugs in llama.cpp (Malfunctioning hinder important workflow)

Comments

@kaetemi
Copy link
Collaborator

kaetemi commented Jul 24, 2024

What happened?

[54/104] Building CXX object src/CMakeFiles/llama.dir/llama.cpp.o
FAILED: src/CMakeFiles/llama.dir/llama.cpp.o
/usr/bin/clang++ -DGGML_USE_CUDA -DLLAMA_BUILD -DLLAMA_SHARED -Dllama_EXPORTS -I/root/llama.cpp/src/. -I/root/llama.cpp/src/../include -I/root/llama.cpp/ggml/src/../include -O2 -O3 -DNDEBUG -fPIC -MD -MT src/CMakeFiles/llama.dir/llama.cpp.o -MF src/CMakeFiles/llama.dir/llama.cpp.o.d -o src/CMakeFiles/llama.dir/llama.cpp.o -c /root/llama.cpp/src/llama.cpp
/root/llama.cpp/src/llama.cpp:2660:11: error: call to implicitly-deleted default constructor of 'struct llama_grammar'
        , grammar()
          ^
/root/llama.cpp/src/./llama-grammar.h:9:32: note: default constructor of 'llama_grammar' is implicitly deleted because field 'rules' of const-qualified type 'const llama_grammar_rules' (aka 'const vector<vector<llama_grammar_element>>') would not be initialized
    const llama_grammar_rules  rules;
                               ^
/root/llama.cpp/src/llama.cpp:14045:38: warning: using floating point absolute value function 'fabs' when argument is of integer type [-Wabsolute-value]
                                f = -fabs(lctx.kv_self.cells[i].pos - pos);
                                     ^
/root/llama.cpp/src/llama.cpp:14045:38: note: use function 'std::abs' instead
                                f = -fabs(lctx.kv_self.cells[i].pos - pos);
                                     ^~~~
                                     std::abs
/root/llama.cpp/src/llama.cpp:14086:42: warning: using floating point absolute value function 'fabs' when argument is of integer type [-Wabsolute-value]
                                    f = -fabs(batch.pos[i] - batch.pos[j]);
                                         ^
/root/llama.cpp/src/llama.cpp:14086:42: note: use function 'std::abs' instead
                                    f = -fabs(batch.pos[i] - batch.pos[j]);
                                         ^~~~
                                         std::abs
2 warnings and 1 error generated.

Seems related to #8508

Name and Version

68504f0

What operating system are you seeing the problem on?

No response

Relevant log output

No response

@kaetemi kaetemi added bug-unconfirmed high severity Used to report high severity bugs in llama.cpp (Malfunctioning hinder important workflow) labels Jul 24, 2024
@ggerganov
Copy link
Owner

#8683 should fix

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug-unconfirmed high severity Used to report high severity bugs in llama.cpp (Malfunctioning hinder important workflow)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants