summary refs log tree commit diff
path: root/compiler/rustc_target/src/spec/mod.rs
AgeCommit message (Collapse)AuthorLines
2020-11-11Rollup merge of #78930 - petrochenkov:notlikeandroid, r=Mark-SimulacrumJonas Schievink-6/+0
rustc_taret: Remove `TargetOptions::is_like_android` This option was replaced by more specific options and is no longer used by the compiler.
2020-11-11rustc_target: Move target env "gnu" from `linux_base` to `linux_gnu_base`Vadim Petrochenkov-0/+1
2020-11-10rustc_taret: Remove `TargetOptions::is_like_android`Vadim Petrochenkov-6/+0
2020-11-10Rollup merge of #78875 - petrochenkov:cleantarg, r=Mark-SimulacrumJonas Schievink-68/+82
rustc_target: Further cleanup use of target options Follow up to https://github.com/rust-lang/rust/pull/77729. Implements items 2 and 4 from the list in https://github.com/rust-lang/rust/pull/77729#issue-500228243. The first commit collapses uses of `target.options.foo` into `target.foo`. The second commit renames some target options to avoid tautology: `target.target_endian` -> `target.endian` `target.target_c_int_width` -> `target.c_int_width` `target.target_os` -> `target.os` `target.target_env` -> `target.env` `target.target_vendor` -> `target.vendor` `target.target_family` -> `target.os_family` `target.target_mcount` -> `target.mcount` r? `@Mark-Simulacrum`
2020-11-09Add `#[cfg(panic = "...")]`David Hewitt-0/+8
2020-11-08rustc_target: Rename some target options to avoid tautologyVadim Petrochenkov-28/+36
`target.target_endian` -> `target.endian` `target.target_c_int_width` -> `target.c_int_width` `target.target_os` -> `target.os` `target.target_env` -> `target.env` `target.target_vendor` -> `target.vendor` `target.target_family` -> `target.os_family` `target.target_mcount` -> `target.mcount`
2020-11-08Collapse all uses of `target.options.foo` into `target.foo`Vadim Petrochenkov-40/+46
with an eye on merging `TargetOptions` into `Target`. `TargetOptions` as a separate structure is mostly an implementation detail of `Target` construction, all its fields logically belong to `Target` and available from `Target` through `Deref` impls.
2020-11-07rustc_target: Move `linker_flavor` from `Target` to `TargetOptions`Vadim Petrochenkov-11/+13
2020-11-07rustc_target: Move `target_vendor` from `Target` to `TargetOptions`Vadim Petrochenkov-11/+5
2020-11-07rustc_target: Move `target_env` from `Target` to `TargetOptions`Vadim Petrochenkov-5/+7
2020-11-07rustc_target: Move `target_os` from `Target` to `TargetOptions`Vadim Petrochenkov-4/+11
2020-11-07rustc_target: Move `target_endian` from `Target` to `TargetOptions`Vadim Petrochenkov-5/+6
2020-11-07rustc_target: Move `target_c_int_width` from `Target` to `TargetOptions`Vadim Petrochenkov-4/+18
2020-11-05Fix automatic_links warningsGuillaume Gomez-1/+1
2020-11-02add mipsel_unknown_none targetStephan-0/+1
2020-10-15Replace target.target with target and target.ptr_width with target.pointer_widthest31-4/+1
Preparation for a subsequent change that replaces rustc_target::config::Config with its wrapped Target. On its own, this commit breaks the build. I don't like making build-breaking commits, but in this instance I believe that it makes review easier, as the "real" changes of this PR can be seen much more easily. Result of running: find compiler/ -type f -exec sed -i -e 's/target\.target\([)\.,; ]\)/target\1/g' {} \; find compiler/ -type f -exec sed -i -e 's/target\.target$/target/g' {} \; find compiler/ -type f -exec sed -i -e 's/target.ptr_width/target.pointer_width/g' {} \; ./x.py fmt
2020-10-15Rename target_pointer_width to pointer_width and turn it into an u32est31-5/+10
Rename target_pointer_width to pointer_width because it is already member of the Target struct. The compiler supports only three valid values for target_pointer_width: 16, 32, 64. Thus it can safely be turned into an int. This means less allocations and clones as well as easier handling of the type.
2020-10-13Add a target option for selecting a DWARF versionAustin Shafer-0/+15
Certain platforms need to limit the DWARF version emitted (oxs, *bsd). This change adds a dwarf_version entry to the options that allows a platform to specify the dwarf version to use. By default this option is none and the default DWARF version is selected. Also adds an option for printing Option<u32> json keys
2020-10-10Auto merge of #77580 - petrochenkov:norestarg, r=matthewjasperbors-41/+14
rustc_target: Refactor away `TargetResult` Follow-up to https://github.com/rust-lang/rust/pull/77202. Construction of a built-in target is always infallible now, so `TargetResult` is no longer necessary. The second commit contains some further cleanup based on built-in target construction being infallible.
2020-10-08Implement the instruction_set attributexd009642-0/+7
2020-10-05rustc_target: Further simplify loading of built-in targetsVadim Petrochenkov-38/+13
using the fact that it is infallible. JSON roundtrip check on every rustc run is also removed, it's already performed by unit tests.
2020-10-05rustc_target: Refactor away `TargetResult`Vadim Petrochenkov-4/+2
Construction of a built-in target is always infallible now, so `TargetResult` is no longer necessary.
2020-09-14librustc_target: Initial support for riscv32gc_unknown_linux_gnuAlistair Francis-0/+1
Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
2020-08-30mv compiler to compiler/mark-0/+1793