2020-08-28 03:58:48 +00:00
|
|
|
[package]
|
|
|
|
name = "rustc_codegen_ssa"
|
|
|
|
version = "0.0.0"
|
2021-09-19 16:49:55 +00:00
|
|
|
edition = "2021"
|
2020-08-28 03:58:48 +00:00
|
|
|
|
|
|
|
[lib]
|
|
|
|
test = false
|
|
|
|
|
|
|
|
[dependencies]
|
|
|
|
bitflags = "1.2.1"
|
2021-07-13 08:58:50 +00:00
|
|
|
cc = "1.0.69"
|
2022-03-04 17:54:28 +00:00
|
|
|
itertools = "0.10.1"
|
2020-08-28 03:58:48 +00:00
|
|
|
tracing = "0.1"
|
|
|
|
libc = "0.2.50"
|
2021-04-21 20:02:54 +00:00
|
|
|
jobserver = "0.1.22"
|
2021-04-23 22:33:09 +00:00
|
|
|
tempfile = "3.2"
|
2022-07-14 17:13:52 +00:00
|
|
|
thorin-dwp = "0.3"
|
2020-08-28 03:58:48 +00:00
|
|
|
pathdiff = "0.2.0"
|
2022-05-06 15:20:42 +00:00
|
|
|
serde_json = "1.0.59"
|
Use object crate for .rustc metadata generation
We already use the object crate for generating uncompressed .rmeta
metadata object files. This switches the generation of compressed
.rustc object files to use the object crate as well. These have
slightly different requirements in that .rmeta should be completely
excluded from any final compilation artifacts, while .rustc should
be part of shared objects, but not loaded into memory.
The primary motivation for this change is #90326: In LLVM 14, the
current way of setting section flags (and in particular, preventing
the setting of SHF_ALLOC) will no longer work. There are other ways
we could work around this, but switching to the object crate seems
like the most elegant, as we already use it for .rmeta, and as it
makes this independent of the codegen backend. In particular, we
don't need separate handling in codegen_llvm and codegen_gcc.
codegen_cranelift should be able to reuse the implementation as
well, though I have omitted that here, as it is not based on
codegen_ssa.
This change mostly extracts the existing code for .rmeta handling
to allow using it for .rustc as well, and adjust the codegen
infrastructure to handle the metadata object file separately: We
no longer create a backend-specific module for it, and directly
produce the compiled module instead.
This does not fix #90326 by itself yet, as .llvmbc will need to be
handled separately.
2021-12-02 11:24:25 +00:00
|
|
|
snap = "1"
|
2022-06-26 22:48:55 +00:00
|
|
|
smallvec = { version = "1.8.1", features = ["union", "may_dangle"] }
|
2021-07-30 19:18:14 +00:00
|
|
|
regex = "1.4"
|
2020-08-28 03:58:48 +00:00
|
|
|
|
|
|
|
rustc_serialize = { path = "../rustc_serialize" }
|
2021-12-03 14:24:05 +00:00
|
|
|
rustc_arena = { path = "../rustc_arena" }
|
2020-08-28 03:58:48 +00:00
|
|
|
rustc_ast = { path = "../rustc_ast" }
|
|
|
|
rustc_span = { path = "../rustc_span" }
|
|
|
|
rustc_middle = { path = "../rustc_middle" }
|
|
|
|
rustc_apfloat = { path = "../rustc_apfloat" }
|
|
|
|
rustc_attr = { path = "../rustc_attr" }
|
|
|
|
rustc_symbol_mangling = { path = "../rustc_symbol_mangling" }
|
2021-05-24 22:34:12 +00:00
|
|
|
rustc_data_structures = { path = "../rustc_data_structures" }
|
2020-08-28 03:58:48 +00:00
|
|
|
rustc_errors = { path = "../rustc_errors" }
|
|
|
|
rustc_fs_util = { path = "../rustc_fs_util" }
|
|
|
|
rustc_hir = { path = "../rustc_hir" }
|
|
|
|
rustc_incremental = { path = "../rustc_incremental" }
|
|
|
|
rustc_index = { path = "../rustc_index" }
|
|
|
|
rustc_macros = { path = "../rustc_macros" }
|
2021-09-24 16:15:36 +00:00
|
|
|
rustc_metadata = { path = "../rustc_metadata" }
|
2020-11-14 15:48:54 +00:00
|
|
|
rustc_query_system = { path = "../rustc_query_system" }
|
2020-08-28 03:58:48 +00:00
|
|
|
rustc_target = { path = "../rustc_target" }
|
|
|
|
rustc_session = { path = "../rustc_session" }
|
2022-07-14 21:42:47 +00:00
|
|
|
rustc_const_eval = { path = "../rustc_const_eval" }
|
2021-05-07 16:57:22 +00:00
|
|
|
|
|
|
|
[dependencies.object]
|
2022-06-01 22:16:00 +00:00
|
|
|
version = "0.29.0"
|
2021-05-07 16:57:22 +00:00
|
|
|
default-features = false
|
2021-04-22 18:53:33 +00:00
|
|
|
features = ["read_core", "elf", "macho", "pe", "unaligned", "archive", "write"]
|