Skip to content

Commit

Permalink
[orca] Skip unnecessary call and avoid error condition (#2674)
Browse files Browse the repository at this point in the history
The `resetExecutionContext` was previosuly a no-op, except forresetting the context, since no 'qubits` are involved in this job.
Recent changes check for presence of qubits and flag errors accordingly. This change removes the invocation of that function. We reset the context in next line anyway.

Signed-off-by: Pradnya Khalate <[email protected]>
  • Loading branch information
khalatepradnya authored Mar 1, 2025
1 parent 9ae03a5 commit 9d20c53
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions runtime/cudaq/platform/orca/OrcaRemoteRESTQPU.h
Original file line number Diff line number Diff line change
Expand Up @@ -108,11 +108,10 @@ class OrcaRemoteRESTQPU : public cudaq::QPU {
cudaq::getExecutionManager()->setExecutionContext(contexts[tid]);
}

/// @brief Overrides resetExecutionContext to forward to the ExecutionManager
/// @brief Overrides resetExecutionContext
void resetExecutionContext() override {
cudaq::info("OrcaRemoteRESTQPU::resetExecutionContext QPU {}", qpu_id);
auto tid = std::hash<std::thread::id>{}(std::this_thread::get_id());
cudaq::getExecutionManager()->resetExecutionContext();
contexts[tid] = nullptr;
contexts.erase(tid);
}
Expand Down

0 comments on commit 9d20c53

Please sign in to comment.