demonstrate crash
This commit is contained in:
parent
ebea708561
commit
70f836e267
3 changed files with 11 additions and 2 deletions
|
@ -682,6 +682,9 @@ endif()
|
||||||
add_library(ggml OBJECT
|
add_library(ggml OBJECT
|
||||||
ggml.cpp
|
ggml.cpp
|
||||||
ggml.h
|
ggml.h
|
||||||
|
print.hpp
|
||||||
|
ggml-internal.hpp
|
||||||
|
llama-internal.hpp
|
||||||
ggml-alloc.cpp
|
ggml-alloc.cpp
|
||||||
ggml-alloc.h
|
ggml-alloc.h
|
||||||
ggml-backend.cpp
|
ggml-backend.cpp
|
||||||
|
|
|
@ -287,7 +287,6 @@ int main(int argc, char ** argv) {
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
print_fields(*ctx);
|
print_fields(*ctx);
|
||||||
print_fields(*ctx_guidance);
|
|
||||||
//print_fields(session_tokens);
|
//print_fields(session_tokens);
|
||||||
// debug message about similarity of saved session, if applicable
|
// debug message about similarity of saved session, if applicable
|
||||||
size_t n_matching_session_tokens = 0;
|
size_t n_matching_session_tokens = 0;
|
||||||
|
@ -376,6 +375,10 @@ int main(int argc, char ** argv) {
|
||||||
for (int i = 0; i < (int) guidance_inp.size(); i++) {
|
for (int i = 0; i < (int) guidance_inp.size(); i++) {
|
||||||
LOG_TEE("%6d -> '%s'\n", guidance_inp[i], llama_token_to_piece(ctx, guidance_inp[i]).c_str());
|
LOG_TEE("%6d -> '%s'\n", guidance_inp[i], llama_token_to_piece(ctx, guidance_inp[i]).c_str());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
print_fields(*ctx_guidance);
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (params.n_keep > 0) {
|
if (params.n_keep > 0) {
|
||||||
|
|
|
@ -438,7 +438,7 @@ REFL_FIELD( logits_all )
|
||||||
//REFL_FIELD( work_buffer)
|
//REFL_FIELD( work_buffer)
|
||||||
REFL_FIELD( buf_compute)
|
REFL_FIELD( buf_compute)
|
||||||
REFL_FIELD( buf_alloc)
|
REFL_FIELD( buf_alloc)
|
||||||
REFL_FIELD( alloc )
|
//REFL_FIELD( alloc )
|
||||||
|
|
||||||
#ifdef GGML_USE_METAL
|
#ifdef GGML_USE_METAL
|
||||||
REFL_FIELD( ctx_metal )
|
REFL_FIELD( ctx_metal )
|
||||||
|
@ -552,6 +552,7 @@ struct hidden : refl::attr::usage::field {};
|
||||||
// // A generic function to print out the fields of any object
|
// // A generic function to print out the fields of any object
|
||||||
template<typename T>
|
template<typename T>
|
||||||
void print_fields(const T& t) {
|
void print_fields(const T& t) {
|
||||||
|
//return;
|
||||||
// // Get the type descriptor of the object
|
// // Get the type descriptor of the object
|
||||||
constexpr auto type = refl::reflect<T>();
|
constexpr auto type = refl::reflect<T>();
|
||||||
|
|
||||||
|
@ -571,8 +572,10 @@ void print_fields(const T& t) {
|
||||||
auto member1 = member(t);
|
auto member1 = member(t);
|
||||||
//if(member1){
|
//if(member1){
|
||||||
std::cout << "Auto:" << member.name <<"\n";
|
std::cout << "Auto:" << member.name <<"\n";
|
||||||
|
//if(member1){
|
||||||
print_fields(member1);
|
print_fields(member1);
|
||||||
//}
|
//}
|
||||||
|
//}
|
||||||
//else {
|
//else {
|
||||||
//std::cout << "NULL:" << member.name <<"\n";
|
//std::cout << "NULL:" << member.name <<"\n";
|
||||||
//}
|
//}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue