@@ -111,6 +111,11 @@ static llvm::cl::opt<bool> includeSourceInPayload(
111
111
" include-source" , llvm::cl::desc(" Write the input source into the payload" ),
112
112
llvm::cl::init(false ), llvm::cl::cat(qssc::config::getQSSCCategory()));
113
113
114
+ static llvm::cl::opt<bool >
115
+ bypassPipeline (" bypass-pipeline" , llvm::cl::desc(" Bypass the pipeline" ),
116
+ llvm::cl::init(false ),
117
+ llvm::cl::cat(qssc::config::getQSSCCategory()));
118
+
114
119
namespace {
115
120
enum InputType { NONE, QASM, MLIR, QOBJ };
116
121
} // anonymous namespace
@@ -449,8 +454,9 @@ static llvm::Error generateQEM_(qssc::hal::TargetSystem &target,
449
454
std::unique_ptr<qssc::payload::Payload> payload,
450
455
mlir::ModuleOp moduleOp,
451
456
llvm::raw_ostream *ostream) {
452
- if (auto err = target.addToPayload (moduleOp, *payload))
453
- return err;
457
+ if (!bypassPipeline)
458
+ if (auto err = target.addToPayload (moduleOp, *payload))
459
+ return err;
454
460
455
461
if (plaintextPayload)
456
462
payload->writePlain (*ostream);
@@ -667,7 +673,7 @@ compile_(int argc, char const **argv, std::string *outputString,
667
673
std::move (err));
668
674
669
675
// Run the pipeline.
670
- if (failed (pm.run (moduleOp)))
676
+ if (!bypassPipeline && failed (pm.run (moduleOp)))
671
677
return llvm::createStringError (llvm::inconvertibleErrorCode (),
672
678
" Problems running the compiler pipeline!" );
673
679
0 commit comments