Skip to content

Commit

Permalink
address an uninitialized warning and change from read_local to ge_loc…
Browse files Browse the repository at this point in the history
…al in fast_sym
  • Loading branch information
solomonik committed Jun 4, 2018
1 parent 145fa36 commit dfa4306
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions src/contraction/contraction.cxx
Expand Up @@ -475,6 +475,7 @@ namespace CTF_int {
assert(0);
}
}
idx_self_A = 0, idx_self_B = 0, idx_self_C=0;
/* Put all weigh indices in back, w ut all contraction indices up front, put A indices in front for C */
idx_ctr = 0, idx_no_ctr_A = 0, idx_no_ctr_B = 0, idx_weigh = 0;
for (i=0; i<num_tot; i++){
Expand Down
4 changes: 2 additions & 2 deletions studies/fast_sym.cxx
Expand Up @@ -40,14 +40,14 @@ int fast_sym(int const n,
int64_t size;
srand48(173*rank);

A.read_local(&size, &indices, &values);
A.get_local_data(&size, &indices, &values);
for (i=0; i<size; i++){
values[i] = drand48();
}
A.write(size, indices, values);
free(indices);
delete [] values;
B.read_local(&size, &indices, &values);
B.get_local_data(&size, &indices, &values);
for (i=0; i<size; i++){
values[i] = drand48();
}
Expand Down

0 comments on commit dfa4306

Please sign in to comment.