Skip to content

Commit 459d84d

Browse files
committed
Move some methods to WriteBackendMethods
1 parent 8e7a49f commit 459d84d

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

src/lib.rs

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -371,16 +371,6 @@ impl ExtraBackendMethods for GccCodegenBackend {
371371
self.lto_supported.load(Ordering::SeqCst),
372372
)
373373
}
374-
375-
fn target_machine_factory(
376-
&self,
377-
_sess: &Session,
378-
_opt_level: OptLevel,
379-
_features: &[String],
380-
) -> TargetMachineFactoryFn<Self> {
381-
// TODO(antoyo): set opt level.
382-
Arc::new(|_, _| ())
383-
}
384374
}
385375

386376
#[derive(Clone, Copy, PartialEq)]
@@ -429,6 +419,16 @@ impl WriteBackendMethods for GccCodegenBackend {
429419
type ModuleBuffer = ModuleBuffer;
430420
type ThinData = ();
431421

422+
fn target_machine_factory(
423+
&self,
424+
_sess: &Session,
425+
_opt_level: OptLevel,
426+
_features: &[String],
427+
) -> TargetMachineFactoryFn<Self> {
428+
// TODO(antoyo): set opt level.
429+
Arc::new(|_, _| ())
430+
}
431+
432432
fn optimize_and_codegen_fat_lto(
433433
cgcx: &CodegenContext,
434434
prof: &SelfProfilerRef,

0 commit comments

Comments
 (0)