about summary refs log tree commit diff
path: root/src/librustc_target
AgeCommit message (Collapse)AuthorLines
2018-08-12Do not generate assumes for plain integer castsSimonas Kazlauskas-1/+10
2018-08-11A few cleanups for fmt_macros, graphviz, apfloat, target, serialize and termljedrz-8/+4
2018-08-09targets: aarch64: Add bare-metal aarch64 targetAndre Richter-0/+48
A generic AArch64 target that can be used for writing bare-metal code for 64-bit ARM architectures.
2018-08-10Rollup merge of #53222 - ljedrz:cleanup_rustc_target, r=Mark-Simulacrumkennytm-50/+46
A few cleanups for rustc_target - remove redundant struct field names - shorten a self-assignment - prefer `unwrap_or_else` in case of function calls - collapse an `if` - collapse a double `map()` - match on dereferenced objects - consume `self` if it implements `Copy`
2018-08-09A few cleanups for rustc_targetljedrz-50/+46
2018-08-09[nll] librustc_target: enable feature(nll) for bootstrapmemoryruins-0/+1
2018-08-07Add aarch64-unknown-netbsd targetJonathan A. Kollasch-0/+32
2018-08-07set emit_debug_gdb_scripts: false for riscv32imac-unknown-none targetDan Callaghan-0/+1
Same as the other embedded targets, see: https://github.com/rust-lang/rust/pull/49728 This is a temporary workaround for #44993.
2018-08-05Remove unnecessary feature attributes that sneaked invarkor-2/+0
2018-08-01[RISCV] Disable c extension and atomic_cas.David Craven-1/+2
2018-08-01[RISCV] Add built-in target riscv32imac-unknown-none-elf.David Craven-0/+53
2018-08-01[RISCV] Implement call abi.David Craven-0/+62
2018-08-01Rollup merge of #52861 - ColinFinck:master, r=alexcrichtonPietro Albini-0/+106
Add targets for HermitCore (https://hermitcore.org) to the Rust compiler and port libstd to it. As a start, the port uses the simplest possible configuration (no jemalloc, abort on panic) and makes use of existing Unix-specific code wherever possible. It adds targets for x86_64 (current main HermitCore platform) and aarch64 (HermitCore platform under development). Together with the patches to "liblibc" (https://github.com/rust-lang/libc/pull/1048) and llvm (https://github.com/rust-lang/llvm/pull/122), this enables HermitCore applications to be written in Rust.
2018-07-30rustc_llvm: move to rustc_codegen_llvm::llvm.Irina Popa-5/+1
2018-07-30Add targets for HermitCore (https://hermitcore.org) to the Rust compiler and ↵Colin Finck-0/+106
port libstd to it. As a start, the port uses the simplest possible configuration (no jemalloc, abort on panic) and makes use of existing Unix-specific code wherever possible. It adds targets for x86_64 (current main HermitCore platform) and aarch64 (HermitCore platform under development). Together with the patches to "liblibc" and "llvm", this enables HermitCore applications to be written in Rust.
2018-07-29Sanity-check all constantsOliver Schneider-0/+2
2018-07-28Rollup merge of #52763 - petrhosek:fuchsia-triple, r=alexcrichtonkennytm-7/+7
Omit the vendor component in Fuchsia triple Previously, using unknown as the vendor value would lead to the same result, but with the multiarch runtimes support in Clang, the target is now used to locate the runtime libraries and so the format is important. The denormalized format with omitted vendor component is the format we use with Clang and should be using for Rust as well.
2018-07-27Auto merge of #52336 - ishitatsuyuki:dyn-rollup, r=Mark-Simulacrumbors-2/+0
Rollup of bare_trait_objects PRs All deny attributes were moved into bootstrap so they can be disabled with a line of config. Warnings for external tools are allowed and it's up to the tool's maintainer to keep it warnings free. r? @Mark-Simulacrum cc @ljedrz @kennytm
2018-07-26Omit the vendor component in Fuchsia triplePetr Hosek-7/+7
Previously, using unknown as the vendor value would lead to the same result, but with the multiarch runtimes support in Clang, the target is now used to locate the runtime libraries and so the format is important. The denormalized format with omitted vendor component is the format we use with Clang and should be using for Rust as well.
2018-07-26sparc ABI issue - structure returning from function is returnedPetr Sumbera-10/+1
in 64bit registers Fixes: #52638
2018-07-25Deny bare_trait_objects globallyTatsuyuki Ishi-2/+0
2018-07-23Change single char str patterns to charsljedrz-2/+2
2018-07-14Auto merge of #52032 - DiamondLovesYou:amdgpu-kernel-abi, r=alexcrichtonbors-0/+4
Add the `amdgpu-kernel` ABI. Technically, there are requirements imposed by the LLVM `AMDGPUTargetMachine` on functions with this ABI (eg, the return type must be void), but I'm unsure exactly where this should be enforced.
2018-07-13Add the `amdgpu-kernel` ABI.Richard Diamond-0/+4
Technically, there are requirements imposed by the LLVM `AMDGPUTargetMachine` on functions with this ABI (eg, the return type must be void), but I'm unsure exactly where this should be enforced.
2018-07-14Rollup merge of #52330 - jethrogb:jb/target-link-args, r=varkorkennytm-11/+15
Don't silently ignore invalid data in target spec This is technically a breaking change, but only because invalid data was previously silently being ignored.
2018-07-13Don't silently ignore invalid data in target specJethro Beekman-11/+15
2018-07-12Deny bare trait objects in librustc_target and libtestljedrz-1/+3
2018-07-10Upgrade to LLVM's master branch (LLVM 7)Alex Crichton-1/+1
This commit upgrades the main LLVM submodule to LLVM's current master branch. The LLD submodule is updated in tandem as well as compiler-builtins. Along the way support was also added for LLVM 7's new features. This primarily includes the support for custom section concatenation natively in LLD so we now add wasm custom sections in LLVM IR rather than having custom support in rustc itself for doing so. Some other miscellaneous changes are: * We now pass `--gc-sections` to `wasm-ld` * The optimization level is now passed to `wasm-ld` * A `--stack-first` option is passed to LLD to have stack overflow always cause a trap instead of corrupting static data * The wasm target for LLVM switched to `wasm32-unknown-unknown`. * The syntax for aligned pointers has changed in LLVM IR and tests are updated to reflect this. * The `thumbv6m-none-eabi` target is disabled due to an [LLVM bug][llbug] Nowadays we've been mostly only upgrading whenever there's a major release of LLVM but enough changes have been happening on the wasm target that there's been growing motivation for quite some time now to upgrade out version of LLD. To upgrade LLD, however, we need to upgrade LLVM to avoid needing to build yet another version of LLVM on the builders. The revision of LLVM in use here is arbitrarily chosen. We will likely need to continue to update it over time if and when we discover bugs. Once LLVM 7 is fully released we can switch to that channel as well. [llbug]: https://bugs.llvm.org/show_bug.cgi?id=37382
2018-07-06Auto merge of #51757 - nielx:fix/haiku-fixes, r=nagisabors-0/+2
Haiku: several smaller fixes to build and run rust on Haiku This PR combines three small patches that help Rust build and run on the Haiku platform. These patches do not intend to impact other platforms.
2018-07-06Auto merge of #51953 - japaric:atomic-load-store, r=alexcrichtonbors-4/+11
enable Atomic*.{load,store} for ARMv6-M / MSP430 closes #45085 as proposed in https://github.com/rust-lang/rust/issues/45085#issuecomment-384825434 this commit adds an `atomic_cas` target option and extends the `#[cfg(target_has_atomic)]` attribute to enable a subset of the `Atomic*` API on architectures that don't support atomic CAS natively, like MSP430 and ARMv6-M. r? @alexcrichton
2018-07-06Rollup merge of #51619 - mksully22:ppc64le_rust, r=alexcrichtonkennytm-0/+36
rust: add initial changes to support powerpc64le musl Initial changes to support rustc building on ppc64le with musl. A PR was also submitted to libc component https://github.com/rust-lang/libc/pull/1023 to add changes to libc musl definitions. A PR was submitted on Alpine https://github.com/alpinelinux/aports/pull/4549 with equivalent temporary patches for building on Alpine for now. As a verification test a github project was put together to build ppc64le versions of rustc, rust-stdlib, and cargo on Alpine, https://github.com/mksully22/ppc64le_alpine_rust_1.26.2
2018-07-05#[cfg(target_has_atomic_cas)] -> #[cfg(target_has_atomic = "cas")]Jorge Aparicio-2/+1
2018-07-05enable Atomic*.{load,store} for ARMv6-M / MSP430Jorge Aparicio-3/+11
closes #45085 this commit adds an `atomic_cas` target option and an unstable `#[cfg(target_has_atomic_cas)]` attribute to enable a subset of the `Atomic*` API on architectures that don't support atomic CAS natively, like MSP430 and ARMv6-M.
2018-07-05Auto merge of #51936 - japaric:rust-lld, r=alexcrichtonbors-0/+3
rename rustc's lld to rust-lld to not shadow the system installed LLD when linking with LLD. Before: - `-C linker=lld -Z linker-flavor=ld.lld` uses rustc's LLD - It's not possible to use a system installed LLD that's named `lld` With this commit: - `-C linker=rust-lld -Z linker-flavor=ld.lld` uses rustc's LLD - `-C linker=lld -Z linker-flavor=ld.lld` uses the system installed LLD we don't offer guarantees about the availability of LLD in the rustc sysroot so we can rename the tool as long as we don't break the wasm32-unknown-unknown target which depends on it. r? @alexcrichton we discussed this before
2018-07-03rust: add initial changes to support powerpc64le muslMike Sullivan-0/+36
amend powerpc64le_unknown_linux_musl.rs to fix copyright date
2018-07-01Auto merge of #51833 - wesleywiser:faster_large_constant_arrays, r=oli-obkbors-0/+13
Speed up compilation of large constant arrays This is a different approach to #51672 as suggested by @oli-obk. Rather than write each repeated value one-by-one, we write the first one and then copy its value directly into the remaining memory. With this change, the [toy program](https://github.com/rust-lang/rust/blob/c2f4744d2db4e162df824d0bd0b093ba4b351545/src/test/run-pass/mir_heavy_promoted.rs) goes from 63 seconds to 19 seconds on my machine. Edit: Inlining `Size::bytes()` saves an additional 6 seconds dropping the total time to 13 seconds on my machine. Edit2: Now down to 2.8 seconds. r? @oli-obk cc @nnethercote @eddyb
2018-06-29rename rustc's lld to rust-lldJorge Aparicio-0/+3
to not shadow the system installed LLD when linking with LLD. Before: - `-C linker=lld -Z linker-flavor=ld.lld` uses rustc's LLD - It's not possible to use a system installed LLD that's named `lld` With this commit: - `-C linker=rust-lld -Z linker-flavor=ld.lld` uses rustc's LLD - `-C linker=lld -Z linker-flavor=ld.lld` uses the system installed LLD
2018-06-28Explicitely disable WASM code generation for EmscriptenJan-Erik Rediger-1/+3
Emscripten changed the default behavior recently: https://github.com/kripken/emscripten/blob/bd050e64bb0d9952df1344b8ea9356252328ad83/ChangeLog.markdown#v1381-05172018 It now defaults to WebAssembly and requires an explicit flag to generate asm.js. WASM=0 is also valid for older emcc and thus doesn't break it. Closes #51856
2018-06-27Inline all methods on `abi::Size`Wesley Wiser-0/+12
This save 3 seconds on the test program.
2018-06-27Inline `abi::Size::bytes()`Wesley Wiser-0/+1
This save an additional 6 seconds on the test program.
2018-06-26migrate codebase to `..=` inclusive range patternsZack M. Davis-13/+13
These were stabilized in March 2018's #47813, and are the Preferred Way to Do It going forward (q.v. #51043).
2018-06-24Haiku: make it explicit that Haiku uses position independentNiels Sascha Reedijk-0/+2
executables on x86_64 With the switch to gcc 7 the linker scripts don't always explicitly add the `-pie` flag anymore. This creates build failures on x86_64. Interestingly enough, adding this flag on i686 will lead to executables that fail to run when ASLR is enabled, so let's keep it x86_64 only.
2018-05-31musl: don't use the included startfiles with -crt-staticJohannes Nixdorf-9/+21
This fixes (only for -crt-static) #36710.
2018-05-24Replace `ScalarKind` with `Primitive`Oliver Schneider-26/+63
2018-05-24Add constant for `Size::from_bytes(0)`Oliver Schneider-10/+12
2018-05-24Auto merge of #50930 - toidiu:ak-ordOutlivesPredicate, r=nikomatsakisbors-2/+2
implement Ord for OutlivesPredicate and other types It became necessary while implementing https://github.com/rust-lang/rust/pull/50070 to have `Ord` implemented for `OutlivesPredicate`. This PR implements `Ord` for `OutlivesPredicate` as well as other types needed for the implementation.
2018-05-24Rollup merge of #50864 - jakllsch:add-netbsd-arm-target-specs, r=alexcrichtonkennytm-0/+71
Add NetBSD/arm target specs
2018-05-24implement Ord for OutlivesPredicate and other typestoidiu-2/+2
2018-05-21Allow `Size` to be any valid `u64`Oliver Schneider-20/+23
2018-05-20Auto merge of #50813 - paoloteti:cortex-r, r=alexcrichtonbors-0/+42
Add target for Big-endian ARM Cortex-R4F/R5F MCUs The ARM Real-Time (ā€˜R’) profile provides high-performing processors for safety-critical environments. Cortex-R has ARM, Thumb instruction whereas Cortex-M makes use of Thumb only. CI/Dockerfile is intentionally in the `disabled` folder.