8000 Rollup of 8 pull requests by Centril · Pull Request #62937 · rust-lang/rust · GitHub
[go: up one dir, main page]

Skip to content

Rollup of 8 pull requests #62937

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 51 commits into from
Closed
Show file tree
Hide file tree
Changes from 2 commits
Commits
Show all changes
51 commits
Select commit Hold shift + click to select a range
8c050fc
rustc: compute `ty::layout::Niche`'s `available` on the fly.
eddyb Jul 11, 2019
dfbf464
rustc_target: move abi::Niche from rustc::ty::layout.
eddyb Jul 12, 2019
88eced5
rustc: precompute the largest Niche and store it in LayoutDetails.
eddyb Jul 15, 2019
bb9bf0c
Add riscv32i-unknown-none-elf target
Disasm Jul 18, 2019
b9784b1
Don't link mcjit/interpreter LLVM components
nikic Jul 20, 2019
c442dae
Ignore NLL migrate mode test in the Polonius compare-mode
lqd Jun 11, 2019
d4ca9a3
Ignore test issue-45983 in the polonius compare mode
lqd Jun 11, 2019
273bfd4
Ignore two-phase-reservation-sharing-interference-2.rs in Polonius co…
lqd Jun 11, 2019
63c837e
Ignore feature-gate-nll.rs in Polonius compare mode
lqd Jun 11, 2019
51c15fa
Ignore test issue-45696-scribble-on-boxed-borrow.rs in Polonius compa…
lqd Jun 11, 2019
ff350f8
Bless output of test ui/emit-artifact-notifications.rs for Polonius
lqd Jun 11, 2019
2824db1
Bless output of test save-analysis/emit-notifications.rs for Polonius
lqd Jun 11, 2019
9410104
Bless output of test nll/loan_ends_mid_block_pair.rs for Polonius
lqd Jun 11, 2019
6a7c15e
Bless output of test consts/promote_const_let.rs for Polonius
lqd Jun 12, 2019
c5a1bc1
Bless output of test nll/get_default.rs for Polonius
lqd Jun 12, 2019
292d5c1
Bless output of test generator/ref-escapes-but-not-over-yield.rs for …
lqd Jun 12, 2019
6fe5292
Bless output of test borrowck/borrowck-escaping-closure-error-2.rs f…
lqd Jun 28, 2019
7db61e7
Bless output of test borrowck/two-phase-surprise-no-conflict.rs for P…
lqd Jun 28, 2019
08c25b5
Bless output of test dropck/dropck_trait_cycle_checked.rs for Polonius
lqd Jun 28, 2019
9a82f52
Create a dedicated polonius test folder
lqd Jul 5, 2019
6d9a4f9
Polonius facts: kill loans on Call terminators and StorageDead
lqd Jul 15, 2019
0bd2b32
Bless output of test borrowck/promote-ref-mut-in-let-issue-46557.rs …
lqd Jul 15, 2019
ed1625f
Ignore test hrtb/issue-30786.rs in Polonius compare mode
lqd Jul 15, 2019
40e6b02
Bless output of test nll/return-ref-mut-issue-46557.rs for Polonius
lqd Jul 15, 2019
9bd9b0d
Add test extracted from rand, checking that StorageDead kills loans
lqd Jul 15, 2019
606f798
Rename test so that both "kills-loans" tests match names
lqd Jul 15, 2019
9e0fb6f
Make both polonius loans tests check-pass
lqd Jul 15, 2019
823ab42
Bless output of test unboxed-closures/unboxed-closures-failed-recursi…
lqd Jul 15, 2019
2f3e36f
Polonius: generate `killed` facts for assignments to projections
lqd Jul 16, 2019
d41e002
Add test checking various assignments are accepted in Polonius
lqd Jul 16, 2019
770129c
Add test to check that assignments to projections do not kill too man…
lqd Jul 16, 2019
c7f9a71
issue-46589 passes in Polonius and fails in NLL, duplicate it and man…
lqd Jul 16, 2019
c0eab36
Bless output of test nll/loan_ends_mid_block_pair.rs for Polonius, again
lqd Jul 16, 2019
e16bede
fix tidy
lqd Jul 16, 2019
4b33968
add support for hexagon-unknown-linux-musl
androm3da Aug 10, 2018
1aeadcc
Require a value for configure --debuginfo-level
cuviper Jul 23, 2019
9073127
Break dependencies between `syntax_ext` and some other crates
petrochenkov Jul 17, 2019
2ef11ad
Move proc macro server into libsyntax
petrochenkov Jul 18, 2019
0513819
Move test harness generation into libsyntax_ext
petrochenkov Jul 18, 2019
db70c0a
Merge `rustc_allocator` into `libsyntax_ext`
petrochenkov Jul 16, 2019
28e0824
Move standard library injection into libsyntax_ext
petrochenkov Jul 18, 2019
3418aa1
syntax_ext: `proc_macro_decls` -> `proc_macro_harness`
petrochenkov Jul 18, 2019
61b680b
Attempt to fix backtrace tests on i686-msvc
alexcrichton Jul 23, 2019
0eac668
Rollup merge of #62692 - eddyb:precompute-niches, r=oli-obk
Centril Jul 24, 2019
947a3a5
Rollup merge of #62736 - lqd:polonius_tests3, r=matthewjasper
Centril Jul 24, 2019
574274f
Rollup merge of #62771 - petrochenkov:depext, r=eddyb
Centril Jul 24, 2019
b14acf4
Rollup merge of #62784 - Disasm:riscv32i, r=estebank
Centril Jul 24, 2019
f79ffa3
Rollup merge of #62814 - androm3da:hexagon_19jul_2019, r=alexcrichton
Centril Jul 24, 2019
58674e0
Rollup merge of #62827 - nikic:llvm-components, r=alexcrichton
Centril Jul 24, 2019
06ee158
Rollup merge of #62897 - alexcrichton:fix-i686-msvc-tests, r=pietroal…
Centril Jul 24, 2019
4008cf1
Rollup merge of #62906 - cuviper:debuginfo-level, r=Mark-Simulacrum
Centril Jul 24, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/libcore/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,7 @@
#![feature(cmpxchg16b_target_feature)]
#![feature(rtm_target_feature)]
#![feature(f16c_target_feature)]
#![feature(hexagon_target_feature)]
#![feature(const_slice_len)]
#![feature(const_str_as_bytes)]
#![feature(const_str_len)]
Expand Down
3 changes: 3 additions & 0 deletions src/libpanic_unwind/gcc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,9 @@ const UNWIND_DATA_REG: (i32, i32) = (6, 7); // R6, R7
#[cfg(target_arch = "sparc64")]
const UNWIND_DATA_REG: (i32, i32) = (24, 25); // I0, I1

#[cfg(target_arch = "hexagon")]
const UNWIND_DATA_REG: (i32, i32) = (0, 1); // R0, R1

// The following code is based on GCC's C and C++ personality routines. For reference, see:
// https://github.com/gcc-mirror/gcc/blob/master/libstdc++-v3/libsupc++/eh_personality.cc
// https://github.com/gcc-mirror/gcc/blob/trunk/libgcc/unwind-c.c
Expand Down
2 changes: 1 addition & 1 deletion src/librustc_codegen_llvm/llvm_util.rs
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ const X86_WHITELIST: &[(&str, Option<Symbol>)] = &[

const HEXAGON_WHITELIST: &[(&str, Option<Symbol>)] = &[
("hvx", Some(sym::hexagon_target_feature)),
("hvx-double", Some(sym::hexagon_target_feature)),
("hvx-length128b", Some(sym::hexagon_target_feature)),
];

const POWERPC_WHITELIST: &[(&str, Option<Symbol>)] = &[
Expand Down
36 changes: 36 additions & 0 deletions src/librustc_target/spec/hexagon_unknown_linux_musl.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
use crate::spec::{LinkerFlavor, Target, TargetResult, LinkArgs};

pub fn target() -> TargetResult {
let mut base = super::linux_musl_base::opts();
base.cpu = "hexagonv60".to_string();
base.max_atomic_width = Some(32);
// FIXME: HVX length defaults are per-CPU
base.features = "-small-data,+hvx-length128b".to_string();

base.crt_static_default = false;
base.atomic_cas = true;
base.has_rpath = true;
base.linker_is_gnu = false;
base.dynamic_linking = true;
base.executables = true;

base.pre_link_args = LinkArgs::new();
base.post_link_args = LinkArgs::new();

Ok(Target {
llvm_target: "hexagon-unknown-linux-musl".to_string(),
target_endian: "little".to_string(),
target_pointer_width: "32".to_string(),
target_c_int_width: "32".to_string(),
data_layout: concat!("e-m:e-p:32:32:32-a:0-n16:32-i64:64:64-i32:32",
":32-i16:16:16-i1:8:8-f32:32:32-f64:64:64-v32",
":32:32-v64:64:64-v512:512:512-v1024:1024:1024-v2048",
":2048:2048").to_string(),
arch: "hexagon".to_string(),
target_os: "linux".to_string(),
target_env: "musl".to_string(),
target_vendor: "unknown".to_string(),
linker_flavor: LinkerFlavor::Gcc,
options: base,
})
}
1 change: 1 addition & 0 deletions src/librustc_target/spec/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -368,6 +368,7 @@ supported_targets! {
("i586-unknown-linux-musl", i586_unknown_linux_musl),
("mips-unknown-linux-musl", mips_unknown_linux_musl),
("mipsel-unknown-linux-musl", mipsel_unknown_linux_musl),
("hexagon-unknown-linux-musl", hexagon_unknown_linux_musl),

("mips-unknown-linux-uclibc", mips_unknown_linux_uclibc),
("mipsel-unknown-linux-uclibc", mipsel_unknown_linux_uclibc),
Expand Down
5 changes: 5 additions & 0 deletions src/libstd/env.rs
Original file line number Diff line number Diff line change
Expand Up @@ -975,6 +975,11 @@ mod arch {
pub const ARCH: &str = "wasm32";
}

#[cfg(target_arch = "hexagon")]
mod arch {
pub const ARCH: &'static str = "hexagon";
}

#[cfg(test)]
mod tests {
use super::*;
Expand Down
56 changes: 56 additions & 0 deletions src/libstd/os/linux/raw.rs
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,62 @@ mod arch {
}
}

#[cfg(target_arch = "hexagon")]
mod arch {
use crate::os::raw::{c_long, c_int, c_longlong, culonglong};

#[stable(feature = "raw_ext", since = "1.1.0")] pub type blkcnt_t = c_longlong;
#[stable(feature = "raw_ext", since = "1.1.0")] pub type blksize_t = c_long;
#[stable(feature = "raw_ext", since = "1.1.0")] pub type ino_t = c_ulonglong;
#[stable(feature = "raw_ext", since = "1.1.0")] pub type nlink_t = c_uint;
#[stable(feature = "raw_ext", since = "1.1.0")] pub type off_t = c_longlong;
#[stable(feature = "raw_ext", since = "1.1.0")] pub type time_t = c_long;

#[repr(C)]
#[derive(Clone)]
#[stable(feature = "raw_ext", since = "1.1.0")]
pub struct stat {
#[stable(feature = "raw_ext", since = "1.1.0")]
pub st_dev: ::dev_t,
#[stable(feature = "raw_ext", since = "1.1.0")]
pub st_ino: ::c_ulonglong,
#[stable(feature = "raw_ext", since = "1.1.0")]
pub st_mode: ::c_uint,
#[stable(feature = "raw_ext", since = "1.1.0")]
pub st_nlink: ::c_uint,
#[stable(feature = "raw_ext", since = "1.1.0")]
pub st_uid: ::c_uint,
#[stable(feature = "raw_ext", since = "1.1.0")]
pub st_gid: ::c_uint,
#[stable(feature = "raw_ext", since = "1.1.0")]
pub st_rdev: ::c_ulonglong,
#[stable(feature = "raw_ext", since = "1.1.0")]
pub __pad1: ::c_ulong,
#[stable(feature = "raw_ext", since = "1.1.0")]
pub st_size: ::c_longlong,
#[stable(feature = "raw_ext", since = "1.1.0")]
pub st_blksize: ::blksize_t,
#[stable(feature = "raw_ext", since = "1.1.0")]
pub __pad2: ::c_int,
#[stable(feature = "raw_ext", since = "1.1.0")]
pub st_blocks: ::blkcnt_t,
#[stable(feature = "raw_ext", since = "1.1.0")]
pub st_atime: ::time_t,
#[stable(feature = "raw_ext", since = "1.1.0")]
pub st_atime_nsec: ::c_long,
#[stable(feature = "raw_ext", since = "1.1.0")]
pub st_mtime: ::time_t,
#[stable(feature = "raw_ext", since = "1.1.0")]
pub st_mtime_nsec: ::c_long,
#[stable(feature = "raw_ext", since = "1.1.0")]
pub st_ctime: ::time_t,
#[stable(feature = "raw_ext", since = "1.1.0")]
pub st_ctime_nsec: ::c_long,
#[stable(feature = "raw_ext", since = "1.1.0")]
pub __pad3: [::c_int;2],
}
}

#[cfg(any(target_arch = "mips64",
target_arch = "s390x",
target_arch = "sparc64"))]
Expand Down
2 changes: 2 additions & 0 deletions src/libstd/os/raw/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
#[doc(include = "os/raw/char.md")]
#[cfg(any(all(target_os = "linux", any(target_arch = "aarch64",
target_arch = "arm",
target_arch = "hexagon",
target_arch = "powerpc",
target_arch = "powerpc64",
target_arch = "s390x")),
Expand All @@ -34,6 +35,7 @@
#[doc(include = "os/raw/char.md")]
#[cfg(not(any(all(target_os = "linux", any(target_arch = "aarch64",
target_arch = "arm",
target_arch = "hexagon",
target_arch = "powerpc",
target_arch = "powerpc64",
target_arch = "s390x")),
Expand Down
3 changes: 2 additions & 1 deletion src/libstd/sys_common/alloc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@ use crate::ptr;
target_arch = "powerpc",
target_arch = "powerpc64",
target_arch = "asmjs",
target_arch = "wasm32")))]
target_arch = "wasm32",
target_arch = "hexagon")))]
pub const MIN_ALIGN: usize = 8;
#[cfg(all(any(target_arch = "x86_64",
target_arch = "aarch64",
Expand Down
3 changes: 3 additions & 0 deletions src/libunwind/libunwind.rs
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,9 @@ pub const unwinder_private_data_size: usize = 2;
#[cfg(target_os = "emscripten")]
pub const unwinder_private_data_size: usize = 20;

#[cfg(all(target_arch = "hexagon", target_os = "linux"))]
pub const unwinder_private_data_size: usize = 35;

#[repr(C)]
pub struct _Unwind_Exception {
pub exception_class: _Unwind_Exception_Class,
Expand Down
0