File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -696,8 +696,18 @@ void PMTopLevelManager::schedulePass(Pass *P) {
696696
697697 // HLSL Change - begin
698698 if (PI && !PI->isAnalysis () && this ->HLSLPrintAfterAll ) {
699+ class direct_stderr_stream : public raw_ostream {
700+ uint64_t current_pos () const override { return 0 ; }
701+ // / See raw_ostream::write_impl.
702+ void write_impl (const char *Ptr, size_t Size) override {
703+ fwrite (Ptr, Size, 1 , stderr);
704+ }
705+ };
706+
707+ static direct_stderr_stream stderr_stream;
708+
699709 Pass *PP = P->createPrinterPass (
700- errs () , std::string (" *** IR Dump After " ) + P->getPassName () + " (" + PI->getPassArgument () + " ) ***" );
710+ stderr_stream , std::string (" *** IR Dump After " ) + P->getPassName () + " (" + PI->getPassArgument () + " ) ***" );
701711 PP->assignPassManager (activeStack, getTopLevelPassManagerType ());
702712 }
703713 // HLSL Change - end
You can’t perform that action at this time.
0 commit comments