MCPcopy Create free account
hub / github.com/QuEST-Kit/QuEST / assertMatrixDeploysEnabledByEnv

Function assertMatrixDeploysEnabledByEnv

quest/src/core/validation.cpp:1800–1809  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1798}
1799
1800void assertMatrixDeploysEnabledByEnv(int isDistrib, int isGpuAccel, int isMultithread, QuESTEnv env, const char* caller) {
1801
1802 // cannot deploy to backend not already enabled by the environment
1803 if (!env.isDistributed)
1804 assertThat(isDistrib == 0 || isDistrib == modeflag::USE_AUTO, report::NEW_DISTRIB_MATRIX_IN_NON_DISTRIB_ENV, caller);
1805 if (!env.isGpuAccelerated)
1806 assertThat(isGpuAccel == 0 || isGpuAccel == modeflag::USE_AUTO, report::NEW_GPU_MATRIX_IN_NON_GPU_ACCEL_ENV, caller);
1807 if (!env.isMultithreaded)
1808 assertThat(isMultithread == 0 || isMultithread == modeflag::USE_AUTO, report::NEW_MULTITHREAD_MATRIX_IN_NON_MULTITHREAD_ENV, caller);
1809}
1810
1811void assertMatrixNonEmpty(int numQubits, const char* caller) {
1812

Callers 1

Calls 1

assertThatFunction · 0.85

Tested by

no test coverage detected