We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cudaq::exp_pauli
Currently using exp_pauli on quantum devices fails with the following error:
exp_pauli
loc("tmp.cpp":26:5): error: failed to legalize operation 'quake.exp_pauli' // -----// IR Dump After BasisConversionPass Failed (basis-conversion) ('builtin.module' operation) //----- // module attributes {llvm.data_layout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128", llvm.triple = "x86_64-unknown-linux-gnu", quake.mangled_name_map = {__nvqpp__mlirgen__function_test_state_param._Z16test_state_paramN5cudaq10pauli_wordE = "_Z16test_state_paramN5cudaq10pauli_wordE"}} { func.func @__nvqpp__mlirgen__function_test_state_param._Z16test_state_paramN5cudaq10pauli_wordE() attributes {"cudaq-entrypoint", "cudaq-kernel", no_this} { %cst = arith.constant 1.000000e+00 : f64 %cst_0 = arith.constant 1.5707963267948966 : f64 %c2_i64 = arith.constant 2 : i64 %0 = cc.address_of @cstr.585900 : !cc.ptr<!llvm.array<3 x i8>> %1 = cc.cast %0 : (!cc.ptr<!llvm.array<3 x i8>>) -> !cc.ptr<i8> %2 = cc.stdvec_init %1, %c2_i64 : (!cc.ptr<i8>, i64) -> !cc.charspan %3 = quake.alloca !quake.veq<2> %4 = quake.extract_ref %3[0] : (!quake.veq<2>) -> !quake.ref quake.ry (%cst_0) %4 : (f64, !quake.ref) -> () quake.exp_pauli %cst, %3, %2 : (f64, !quake.veq<2>, !cc.charspan) -> () return } llvm.mlir.global private constant @cstr.585900("XY\00") {addr_space = 0 : i32} } terminate called after throwing an instance of 'std::runtime_error' what(): Remote rest platform Quake lowering failed. Aborted
Implement a compiler pass that converts the expression to gates similar to: https://github.com/NVIDIA/cuda-quantum/blob/main/runtime/nvqir/CircuitSimulator.h#L135
The text was updated successfully, but these errors were encountered:
annagrin
Successfully merging a pull request may close this issue.
Required prerequisites
Describe the feature
Description
Currently using
exp_pauli
on quantum devices fails with the following error:Suggestion
Implement a compiler pass that converts the expression to gates similar to:
https://github.com/NVIDIA/cuda-quantum/blob/main/runtime/nvqir/CircuitSimulator.h#L135
The text was updated successfully, but these errors were encountered: