| 429 | |
| 430 | |
| 431 | extern "C" void setDiagMatr(DiagMatr out, qcomp* in) { |
| 432 | validate_matrixFields(out, __func__); |
| 433 | validate_matrixNewElemsPtrNotNull(in, __func__); |
| 434 | |
| 435 | // overwrite CPU memory |
| 436 | cpu_copyArray(out.cpuElems, in, out.numElems); |
| 437 | |
| 438 | // overwrite GPU elements; validation gauranteed to pass |
| 439 | syncDiagMatr(out); |
| 440 | } |
| 441 | |
| 442 | |
| 443 | extern "C" void setFullStateDiagMatr(FullStateDiagMatr out, qindex startInd, qcomp* in, qindex numElems) { |
no test coverage detected