Struct rustc_codegen_llvm::LlvmCodegenBackend [−][src]
pub struct LlvmCodegenBackend(());
Tuple Fields
0: ()
Implementations
Trait Implementations
fn codegen_crate<'tcx>(
&self,
tcx: TyCtxt<'tcx>,
metadata: EncodedMetadata,
need_metadata_module: bool
) -> Box<dyn Any>
fn join_codegen(
&self,
ongoing_codegen: Box<dyn Any>,
sess: &Session
) -> Result<(CodegenResults, FxHashMap<WorkProductId, WorkProduct>), ErrorReported>
fn join_codegen(
&self,
ongoing_codegen: Box<dyn Any>,
sess: &Session
) -> Result<(CodegenResults, FxHashMap<WorkProductId, WorkProduct>), ErrorReported>
This is called on the returned Box<dyn Any>
from codegen_backend
Read more
fn link(
&self,
sess: &Session,
codegen_results: CodegenResults,
outputs: &OutputFilenames
) -> Result<(), ErrorReported>
fn link(
&self,
sess: &Session,
codegen_results: CodegenResults,
outputs: &OutputFilenames
) -> Result<(), ErrorReported>
This is called on the returned Box<dyn Any>
from join_codegen
Read more
If this plugin provides additional builtin targets, provide the one enabled by the options here. Be careful: this is called before init() is called. Read more
The metadata loader used to load rlib and dylib metadata. Read more
fn write_compressed_metadata<'tcx>(
&self,
tcx: TyCtxt<'tcx>,
metadata: &EncodedMetadata,
llvm_module: &mut ModuleLlvm
)
fn codegen_allocator<'tcx>(
&self,
tcx: TyCtxt<'tcx>,
module_llvm: &mut ModuleLlvm,
module_name: &str,
kind: AllocatorKind,
has_alloc_error_handler: bool
)
fn compile_codegen_unit(
&self,
tcx: TyCtxt<'_>,
cgu_name: Symbol
) -> (ModuleCodegen<ModuleLlvm>, u64)
fn compile_codegen_unit(
&self,
tcx: TyCtxt<'_>,
cgu_name: Symbol
) -> (ModuleCodegen<ModuleLlvm>, u64)
This generates the codegen unit and returns it along with
a u64
giving an estimate of the unit’s processing cost. Read more
fn target_machine_factory(
&self,
sess: &Session,
optlvl: OptLevel
) -> TargetMachineFactoryFn<Self>
type Module = ModuleLlvm
type ModuleBuffer = ModuleBuffer
type TargetMachine = &'static mut TargetMachine
type ThinBuffer = ThinBuffer
fn run_link(
cgcx: &CodegenContext<Self>,
diag_handler: &Handler,
modules: Vec<ModuleCodegen<Self::Module>>
) -> Result<ModuleCodegen<Self::Module>, FatalError>
fn run_link(
cgcx: &CodegenContext<Self>,
diag_handler: &Handler,
modules: Vec<ModuleCodegen<Self::Module>>
) -> Result<ModuleCodegen<Self::Module>, FatalError>
Merge all modules into main_module and returning it
fn run_fat_lto(
cgcx: &CodegenContext<Self>,
modules: Vec<FatLTOInput<Self>>,
cached_modules: Vec<(SerializedModule<Self::ModuleBuffer>, WorkProduct)>
) -> Result<LtoModuleCodegen<Self>, FatalError>
fn run_fat_lto(
cgcx: &CodegenContext<Self>,
modules: Vec<FatLTOInput<Self>>,
cached_modules: Vec<(SerializedModule<Self::ModuleBuffer>, WorkProduct)>
) -> Result<LtoModuleCodegen<Self>, FatalError>
Performs fat LTO by merging all modules into a single one and returning it for further optimization. Read more
fn run_thin_lto(
cgcx: &CodegenContext<Self>,
modules: Vec<(String, Self::ThinBuffer)>,
cached_modules: Vec<(SerializedModule<Self::ModuleBuffer>, WorkProduct)>
) -> Result<(Vec<LtoModuleCodegen<Self>>, Vec<WorkProduct>), FatalError>
fn run_thin_lto(
cgcx: &CodegenContext<Self>,
modules: Vec<(String, Self::ThinBuffer)>,
cached_modules: Vec<(SerializedModule<Self::ModuleBuffer>, WorkProduct)>
) -> Result<(Vec<LtoModuleCodegen<Self>>, Vec<WorkProduct>), FatalError>
Performs thin LTO by performing necessary global analysis and returning two lists, one of the modules that need optimization and another for modules that can simply be copied over from the incr. comp. cache. Read more
unsafe fn optimize(
cgcx: &CodegenContext<Self>,
diag_handler: &Handler,
module: &ModuleCodegen<Self::Module>,
config: &ModuleConfig
) -> Result<(), FatalError>
unsafe fn optimize_thin(
cgcx: &CodegenContext<Self>,
thin: &mut ThinModule<Self>
) -> Result<ModuleCodegen<Self::Module>, FatalError>
unsafe fn codegen(
cgcx: &CodegenContext<Self>,
diag_handler: &Handler,
module: ModuleCodegen<Self::Module>,
config: &ModuleConfig
) -> Result<CompiledModule, FatalError>
fn run_lto_pass_manager(
cgcx: &CodegenContext<Self>,
module: &ModuleCodegen<Self::Module>,
config: &ModuleConfig,
thin: bool
) -> Result<(), FatalError>
Auto Trait Implementations
impl RefUnwindSafe for LlvmCodegenBackend
impl Unpin for LlvmCodegenBackend
impl UnwindSafe for LlvmCodegenBackend
Blanket Implementations
Mutably borrows from an owned value. Read more
Layout
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...)
attributes. Please see the Rust Reference’s “Type Layout” chapter for details on type layout guarantees.
Size: 0 bytes