@@ -375,31 +375,6 @@ class TargetMachine {
375375 // / with the new pass manager. Only affects the "default" AAManager.
376376 virtual void registerDefaultAliasAnalyses (AAManager &) {}
377377
378- // / Add passes to the specified pass manager to get the specified file
379- // / emitted. Typically this will involve several steps of code generation.
380- // / This method should return true if emission of this file type is not
381- // / supported, or false on success.
382- // / \p MMIWP is an optional parameter that, if set to non-nullptr,
383- // / will be used to set the MachineModuloInfo for this PM.
384- virtual bool
385- addPassesToEmitFile (PassManagerBase &, raw_pwrite_stream &,
386- raw_pwrite_stream *, CodeGenFileType,
387- bool /* DisableVerify*/ = true ,
388- MachineModuleInfoWrapperPass *MMIWP = nullptr ) {
389- return true ;
390- }
391-
392- // / Add passes to the specified pass manager to get machine code emitted with
393- // / the MCJIT. This method returns true if machine code is not supported. It
394- // / fills the MCContext Ctx pointer which can be used to build custom
395- // / MCStreamer.
396- // /
397- virtual bool addPassesToEmitMC (PassManagerBase &, MCContext *&,
398- raw_pwrite_stream &,
399- bool /* DisableVerify*/ = true ) {
400- return true ;
401- }
402-
403378 // / True if subtarget inserts the final scheduling pass on its own.
404379 // /
405380 // / Branch relaxation, which must happen after block placement, can
@@ -460,14 +435,14 @@ class LLVMTargetMachine : public TargetMachine {
460435 virtual TargetPassConfig *createPassConfig (PassManagerBase &PM);
461436
462437 // / Add passes to the specified pass manager to get the specified file
463- // / emitted. Typically this will involve several steps of code generation.
464- // / \p MMIWP is an optional parameter that, if set to non-nullptr,
465- // / will be used to set the MachineModuloInfo for this PM .
466- bool
467- addPassesToEmitFile (PassManagerBase &PM, raw_pwrite_stream &Out,
468- raw_pwrite_stream *DwoOut, CodeGenFileType FileType ,
469- bool DisableVerify = true ,
470- MachineModuleInfoWrapperPass *MMIWP = nullptr ) override ;
438+ // / emitted. Typically this will involve several steps of code generation.
439+ // / This method should return true if emission of this file type is not
440+ // / supported, or false on success .
441+ virtual bool addPassesToEmitFile (PassManagerBase &PM, MachineModuleInfo &MMI,
442+ raw_pwrite_stream &Out,
443+ raw_pwrite_stream *DwoOut,
444+ CodeGenFileType FileType ,
445+ bool DisableVerify = true ) ;
471446
472447 virtual Error buildCodeGenPipeline (ModulePassManager &, raw_pwrite_stream &,
473448 raw_pwrite_stream *, CodeGenFileType,
@@ -478,12 +453,10 @@ class LLVMTargetMachine : public TargetMachine {
478453 }
479454
480455 // / Add passes to the specified pass manager to get machine code emitted with
481- // / the MCJIT. This method returns true if machine code is not supported. It
482- // / fills the MCContext Ctx pointer which can be used to build custom
483- // / MCStreamer.
484- bool addPassesToEmitMC (PassManagerBase &PM, MCContext *&Ctx,
485- raw_pwrite_stream &Out,
486- bool DisableVerify = true ) override ;
456+ // / the MCJIT. This method returns true if machine code is not supported.
457+ virtual bool addPassesToEmitMC (PassManagerBase &PM, MachineModuleInfo &MMI,
458+ raw_pwrite_stream &Out,
459+ bool DisableVerify = true );
487460
488461 // / Returns true if the target is expected to pass all machine verifier
489462 // / checks. This is a stopgap measure to fix targets one by one. We will
0 commit comments