Rollup merge of #141769 - bjorn3:codegen_metadata_module_rework, r=workingjubilee,saethlin

Move metadata object generation for dylibs to the linker code

This deduplicates some code between codegen backends and may in the future allow adding extra metadata that is only known at link time.

Prerequisite of https://github.com/rust-lang/rust/issues/96708.
This commit is contained in:
León Orell Valerian Liehr
2025-06-15 23:51:54 +02:00
committed by GitHub
19 changed files with 161 additions and 290 deletions

View File

@@ -215,13 +215,6 @@ pub struct Session {
pub invocation_temp: Option<String>,
}
#[derive(PartialEq, Eq, PartialOrd, Ord)]
pub enum MetadataKind {
None,
Uncompressed,
Compressed,
}
#[derive(Clone, Copy)]
pub enum CodegenUnits {
/// Specified by the user. In this case we try fairly hard to produce the