[−][src]Trait rustc_codegen_ssa::traits::ExtraBackendMethods

pub trait ExtraBackendMethods: CodegenBackend + WriteBackendMethods + Sized + Send + Sync {
    pub fn new_metadata(&self, sess: TyCtxt<'_>, mod_name: &str) -> Self::Module;
pub fn write_compressed_metadata<'tcx>(
        &self,
        tcx: TyCtxt<'tcx>,
        metadata: &EncodedMetadata,
        llvm_module: &mut Self::Module
    );
pub fn codegen_allocator<'tcx>(
        &self,
        tcx: TyCtxt<'tcx>,
        mods: &mut Self::Module,
        kind: AllocatorKind,
        has_alloc_error_handler: bool
    );
pub fn compile_codegen_unit(
        &self,
        tcx: TyCtxt<'_>,
        cgu_name: Symbol
    ) -> (ModuleCodegen<Self::Module>, u64);
pub fn target_machine_factory(
        &self,
        sess: &Session,
        opt_level: OptLevel
    ) -> Arc<dyn Fn() -> Result<Self::TargetMachine, String> + Send + Sync>;
pub fn target_cpu<'b>(&self, sess: &'b Session) -> &'b str;
pub fn tune_cpu<'b>(&self, sess: &'b Session) -> Option<&'b str>; }

Required methods

pub fn new_metadata(&self, sess: TyCtxt<'_>, mod_name: &str) -> Self::Module[src]

pub fn write_compressed_metadata<'tcx>(
    &self,
    tcx: TyCtxt<'tcx>,
    metadata: &EncodedMetadata,
    llvm_module: &mut Self::Module
)
[src]

pub fn codegen_allocator<'tcx>(
    &self,
    tcx: TyCtxt<'tcx>,
    mods: &mut Self::Module,
    kind: AllocatorKind,
    has_alloc_error_handler: bool
)
[src]

pub fn compile_codegen_unit(
    &self,
    tcx: TyCtxt<'_>,
    cgu_name: Symbol
) -> (ModuleCodegen<Self::Module>, u64)
[src]

This generates the codegen unit and returns it along with a u64 giving an estimate of the unit's processing cost.

pub fn target_machine_factory(
    &self,
    sess: &Session,
    opt_level: OptLevel
) -> Arc<dyn Fn() -> Result<Self::TargetMachine, String> + Send + Sync>
[src]

pub fn target_cpu<'b>(&self, sess: &'b Session) -> &'b str[src]

pub fn tune_cpu<'b>(&self, sess: &'b Session) -> Option<&'b str>[src]

Loading content...

Implementors

Loading content...