mirror of
https://github.com/zama-ai/concrete.git
synced 2026-02-08 19:44:57 -05:00
chore(tests): Add testing for gpu
This commit is contained in:
@@ -261,6 +261,13 @@ $(FIXTURE_CPU_DIR)/bug_report.yaml:
|
||||
|
||||
generate-cpu-tests: $(FIXTURE_CPU_DIR)/end_to_end_leveled.yaml $(FIXTURE_CPU_DIR)/end_to_end_apply_lookup_table.yaml $(FIXTURE_CPU_DIR)/end_to_end_linalg_apply_lookup_table.yaml $(FIXTURE_CPU_DIR)/bug_report.yaml
|
||||
|
||||
run-end-to-end-tests: build-end-to-end-tests generate-cpu-tests
|
||||
$(BUILD_DIR)/tools/concretelang/tests/end_to_end_tests/end_to_end_jit_test
|
||||
$(BUILD_DIR)/tools/concretelang/tests/end_to_end_tests/end_to_end_jit_encrypted_tensor
|
||||
$(BUILD_DIR)/tools/concretelang/tests/end_to_end_tests/end_to_end_jit_fhelinalg
|
||||
$(BUILD_DIR)/tools/concretelang/tests/end_to_end_tests/end_to_end_jit_lambda
|
||||
$(BUILD_DIR)/tools/concretelang/tests/end_to_end_tests/end_to_end_test --loop-parallelize --jit $(FIXTURE_CPU_DIR)/*.yaml
|
||||
|
||||
### end-to-end-tests GPU
|
||||
|
||||
FIXTURE_GPU_DIR=tests/end_to_end_fixture/tests_gpu
|
||||
@@ -277,7 +284,9 @@ $(FIXTURE_GPU_DIR)/end_to_end_linalg_apply_lookup_table.yaml: tests/end_to_end_f
|
||||
generate-gpu-tests: $(FIXTURE_GPU_DIR) $(FIXTURE_GPU_DIR)/end_to_end_apply_lookup_table.yaml $(FIXTURE_GPU_DIR)/end_to_end_linalg_apply_lookup_table.yaml
|
||||
|
||||
run-end-to-end-tests-gpu: build-end-to-end-test generate-gpu-tests
|
||||
$(BUILD_DIR)/tools/concretelang/tests/end_to_end_tests/end_to_end_test --emit-gpu-ops --library /tmp/concrete_compiler/gpu_tests/ $(FIXTURE_CPU_DIR)/*.yaml
|
||||
$(BUILD_DIR)/tools/concretelang/tests/end_to_end_tests/end_to_end_test \
|
||||
--emit-gpu-ops --batch-concrete-ops --library /tmp/concrete_compiler/gpu_tests/ \
|
||||
$(FIXTURE_GPU_DIR)/*.yaml
|
||||
|
||||
|
||||
## end-to-end-dataflow-tests
|
||||
|
||||
@@ -248,6 +248,11 @@ int main(int argc, char **argv) {
|
||||
"emit-gpu-ops",
|
||||
llvm::cl::desc("Set the emitGPUOps compilation options to run the tests"),
|
||||
llvm::cl::init(false));
|
||||
llvm::cl::opt<bool> batchConcreteOps(
|
||||
"batch-concrete-ops",
|
||||
llvm::cl::desc(
|
||||
"Set the batchConcreteOps compilation options to run the tests"),
|
||||
llvm::cl::init(false));
|
||||
|
||||
// Optimizer options
|
||||
llvm::cl::opt<bool> optimizerDisplay(
|
||||
@@ -275,7 +280,8 @@ int main(int argc, char **argv) {
|
||||
compilationOptions.loopParallelize = loopParallelize.getValue();
|
||||
compilationOptions.dataflowParallelize = dataflowParallelize.getValue();
|
||||
compilationOptions.emitGPUOps = emitGPUOps.getValue();
|
||||
compilationOptions.optimizerConfig.display = optimizerDisplay.getValue();
|
||||
compilationOptions.batchConcreteOps =
|
||||
compilationOptions.optimizerConfig.display = optimizerDisplay.getValue();
|
||||
|
||||
for (auto descFile : descriptionFiles) {
|
||||
auto desc = loadEndToEndDesc(descFile);
|
||||
|
||||
Reference in New Issue
Block a user