c++11 cannot use designated initializers

This commit is contained in:
netrunnereve 2023-07-29 14:36:33 -04:00
parent dc9b9f3272
commit 49580fe816
2 changed files with 9 additions and 10 deletions

View file

@ -372,11 +372,10 @@ bool check_mat_mul(
#define NUM_PERMUTATIONS (4*3*2*1) #define NUM_PERMUTATIONS (4*3*2*1)
int main(int argc, const char ** argv) { int main(int argc, const char ** argv) {
struct ggml_init_params params = { struct ggml_init_params params;
.mem_size = 128*1024*1024, params.mem_size = 128*1024*1024;
.mem_buffer = NULL, params.mem_buffer = NULL;
.no_alloc = false, params.no_alloc = false;
};
int64_t ne[4]; int64_t ne[4];

View file

@ -118,11 +118,11 @@ void set_element(struct ggml_tensor * t, int idx, float value) {
} }
int main(void) { int main(void) {
struct ggml_init_params params = { struct ggml_init_params params;
.mem_size = 1024*1024*1024, params.mem_size = 1024*1024*1024;
.mem_buffer = NULL, params.mem_buffer = NULL;
.no_alloc = false, params.no_alloc = false;
};
struct ggml_context * ctx = ggml_init(params); struct ggml_context * ctx = ggml_init(params);
int64_t ne1[4] = {4, 128, 1, 1}; int64_t ne1[4] = {4, 128, 1, 1};