Rollup merge of #117338 - workingjubilee:asmjs-meets-thanatos, r=b-naber
Remove asmjs Fulfills [MCP 668](https://github.com/rust-lang/compiler-team/issues/668). `asmjs-unknown-emscripten` does not work as-specified, and lacks essential upstream support for generating asm.js, so it should not exist at all.
This commit is contained in:
commit
ca3a02836e
@ -990,11 +990,7 @@ unsafe fn embed_bitcode(
|
|||||||
// reason (see issue #90326 for historical background).
|
// reason (see issue #90326 for historical background).
|
||||||
let is_aix = target_is_aix(cgcx);
|
let is_aix = target_is_aix(cgcx);
|
||||||
let is_apple = target_is_apple(cgcx);
|
let is_apple = target_is_apple(cgcx);
|
||||||
if is_apple
|
if is_apple || is_aix || cgcx.opts.target_triple.triple().starts_with("wasm") {
|
||||||
|| is_aix
|
|
||||||
|| cgcx.opts.target_triple.triple().starts_with("wasm")
|
|
||||||
|| cgcx.opts.target_triple.triple().starts_with("asmjs")
|
|
||||||
{
|
|
||||||
// We don't need custom section flags, create LLVM globals.
|
// We don't need custom section flags, create LLVM globals.
|
||||||
let llconst = common::bytes_in_context(llcx, bitcode);
|
let llconst = common::bytes_in_context(llcx, bitcode);
|
||||||
let llglobal = llvm::LLVMAddGlobal(
|
let llglobal = llvm::LLVMAddGlobal(
|
||||||
|
@ -2243,9 +2243,9 @@ fn linker_with_args<'a>(
|
|||||||
// ------------ Late order-dependent options ------------
|
// ------------ Late order-dependent options ------------
|
||||||
|
|
||||||
// Doesn't really make sense.
|
// Doesn't really make sense.
|
||||||
// FIXME: In practice built-in target specs use this for arbitrary order-independent options,
|
// FIXME: In practice built-in target specs use this for arbitrary order-independent options.
|
||||||
// introduce a target spec option for order-independent linker options, migrate built-in specs
|
// Introduce a target spec option for order-independent linker options, migrate built-in specs
|
||||||
// to it and remove the option.
|
// to it and remove the option. Currently the last holdout is wasm32-unknown-emscripten.
|
||||||
add_post_link_args(cmd, sess, flavor);
|
add_post_link_args(cmd, sess, flavor);
|
||||||
|
|
||||||
Ok(cmd.take_cmd())
|
Ok(cmd.take_cmd())
|
||||||
|
@ -836,7 +836,6 @@ impl<'a, Ty> FnAbi<'a, Ty> {
|
|||||||
wasm::compute_c_abi_info(cx, self)
|
wasm::compute_c_abi_info(cx, self)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
"asmjs" => wasm::compute_c_abi_info(cx, self),
|
|
||||||
"bpf" => bpf::compute_abi_info(self),
|
"bpf" => bpf::compute_abi_info(self),
|
||||||
arch => {
|
arch => {
|
||||||
return Err(AdjustForForeignAbiError::Unsupported {
|
return Err(AdjustForForeignAbiError::Unsupported {
|
||||||
|
@ -1609,7 +1609,6 @@ supported_targets! {
|
|||||||
("thumbv7a-pc-windows-msvc", thumbv7a_pc_windows_msvc),
|
("thumbv7a-pc-windows-msvc", thumbv7a_pc_windows_msvc),
|
||||||
("thumbv7a-uwp-windows-msvc", thumbv7a_uwp_windows_msvc),
|
("thumbv7a-uwp-windows-msvc", thumbv7a_uwp_windows_msvc),
|
||||||
|
|
||||||
("asmjs-unknown-emscripten", asmjs_unknown_emscripten),
|
|
||||||
("wasm32-unknown-emscripten", wasm32_unknown_emscripten),
|
("wasm32-unknown-emscripten", wasm32_unknown_emscripten),
|
||||||
("wasm32-unknown-unknown", wasm32_unknown_unknown),
|
("wasm32-unknown-unknown", wasm32_unknown_unknown),
|
||||||
("wasm32-wasi", wasm32_wasi),
|
("wasm32-wasi", wasm32_wasi),
|
||||||
@ -2244,10 +2243,6 @@ impl TargetOptions {
|
|||||||
add_link_args(&mut self.pre_link_args, flavor, args);
|
add_link_args(&mut self.pre_link_args, flavor, args);
|
||||||
}
|
}
|
||||||
|
|
||||||
fn add_post_link_args(&mut self, flavor: LinkerFlavor, args: &[&'static str]) {
|
|
||||||
add_link_args(&mut self.post_link_args, flavor, args);
|
|
||||||
}
|
|
||||||
|
|
||||||
fn update_from_cli(&mut self) {
|
fn update_from_cli(&mut self) {
|
||||||
self.linker_flavor = LinkerFlavor::from_cli_json(
|
self.linker_flavor = LinkerFlavor::from_cli_json(
|
||||||
self.linker_flavor_json,
|
self.linker_flavor_json,
|
||||||
|
@ -241,7 +241,6 @@ impl fmt::Debug for c_void {
|
|||||||
),
|
),
|
||||||
all(target_arch = "aarch64", any(target_os = "macos", target_os = "ios", target_os = "tvos")),
|
all(target_arch = "aarch64", any(target_os = "macos", target_os = "ios", target_os = "tvos")),
|
||||||
target_family = "wasm",
|
target_family = "wasm",
|
||||||
target_arch = "asmjs",
|
|
||||||
target_os = "uefi",
|
target_os = "uefi",
|
||||||
windows,
|
windows,
|
||||||
))]
|
))]
|
||||||
@ -270,7 +269,6 @@ pub struct VaListImpl<'f> {
|
|||||||
),
|
),
|
||||||
all(target_arch = "aarch64", any(target_os = "macos", target_os = "ios", target_os = "tvos")),
|
all(target_arch = "aarch64", any(target_os = "macos", target_os = "ios", target_os = "tvos")),
|
||||||
target_family = "wasm",
|
target_family = "wasm",
|
||||||
target_arch = "asmjs",
|
|
||||||
target_os = "uefi",
|
target_os = "uefi",
|
||||||
windows,
|
windows,
|
||||||
))]
|
))]
|
||||||
@ -395,7 +393,6 @@ pub struct VaList<'a, 'f: 'a> {
|
|||||||
any(target_os = "macos", target_os = "ios", target_os = "tvos")
|
any(target_os = "macos", target_os = "ios", target_os = "tvos")
|
||||||
),
|
),
|
||||||
target_family = "wasm",
|
target_family = "wasm",
|
||||||
target_arch = "asmjs",
|
|
||||||
target_os = "uefi",
|
target_os = "uefi",
|
||||||
windows,
|
windows,
|
||||||
))]
|
))]
|
||||||
@ -413,7 +410,6 @@ pub struct VaList<'a, 'f: 'a> {
|
|||||||
not(any(target_os = "macos", target_os = "ios", target_os = "tvos"))
|
not(any(target_os = "macos", target_os = "ios", target_os = "tvos"))
|
||||||
),
|
),
|
||||||
not(target_family = "wasm"),
|
not(target_family = "wasm"),
|
||||||
not(target_arch = "asmjs"),
|
|
||||||
not(target_os = "uefi"),
|
not(target_os = "uefi"),
|
||||||
not(windows),
|
not(windows),
|
||||||
))]
|
))]
|
||||||
@ -431,7 +427,6 @@ pub struct VaList<'a, 'f: 'a> {
|
|||||||
),
|
),
|
||||||
all(target_arch = "aarch64", any(target_os = "macos", target_os = "ios", target_os = "tvos")),
|
all(target_arch = "aarch64", any(target_os = "macos", target_os = "ios", target_os = "tvos")),
|
||||||
target_family = "wasm",
|
target_family = "wasm",
|
||||||
target_arch = "asmjs",
|
|
||||||
target_os = "uefi",
|
target_os = "uefi",
|
||||||
windows,
|
windows,
|
||||||
))]
|
))]
|
||||||
@ -461,7 +456,6 @@ impl<'f> VaListImpl<'f> {
|
|||||||
not(any(target_os = "macos", target_os = "ios", target_os = "tvos"))
|
not(any(target_os = "macos", target_os = "ios", target_os = "tvos"))
|
||||||
),
|
),
|
||||||
not(target_family = "wasm"),
|
not(target_family = "wasm"),
|
||||||
not(target_arch = "asmjs"),
|
|
||||||
not(target_os = "uefi"),
|
not(target_os = "uefi"),
|
||||||
not(windows),
|
not(windows),
|
||||||
))]
|
))]
|
||||||
|
@ -25,7 +25,6 @@ fn main() {
|
|||||||
|| target.contains("vxworks")
|
|| target.contains("vxworks")
|
||||||
|| target.contains("wasm32")
|
|| target.contains("wasm32")
|
||||||
|| target.contains("wasm64")
|
|| target.contains("wasm64")
|
||||||
|| target.contains("asmjs")
|
|
||||||
|| target.contains("espidf")
|
|| target.contains("espidf")
|
||||||
|| target.contains("solid")
|
|| target.contains("solid")
|
||||||
|| target.contains("nintendo-3ds")
|
|| target.contains("nintendo-3ds")
|
||||||
|
@ -31,7 +31,6 @@ pub use self::arch::{blkcnt_t, blksize_t, ino_t, nlink_t, off_t, stat, time_t};
|
|||||||
target_arch = "powerpc",
|
target_arch = "powerpc",
|
||||||
target_arch = "sparc",
|
target_arch = "sparc",
|
||||||
target_arch = "arm",
|
target_arch = "arm",
|
||||||
target_arch = "asmjs",
|
|
||||||
target_arch = "wasm32"
|
target_arch = "wasm32"
|
||||||
))]
|
))]
|
||||||
mod arch {
|
mod arch {
|
||||||
|
@ -31,7 +31,6 @@ pub use self::arch::{blkcnt_t, blksize_t, ino_t, nlink_t, off_t, stat, time_t};
|
|||||||
target_arch = "powerpc",
|
target_arch = "powerpc",
|
||||||
target_arch = "sparc",
|
target_arch = "sparc",
|
||||||
target_arch = "arm",
|
target_arch = "arm",
|
||||||
target_arch = "asmjs",
|
|
||||||
target_arch = "wasm32"
|
target_arch = "wasm32"
|
||||||
))]
|
))]
|
||||||
mod arch {
|
mod arch {
|
||||||
|
@ -14,7 +14,6 @@ use crate::ptr;
|
|||||||
target_arch = "powerpc",
|
target_arch = "powerpc",
|
||||||
target_arch = "powerpc64",
|
target_arch = "powerpc64",
|
||||||
target_arch = "sparc",
|
target_arch = "sparc",
|
||||||
target_arch = "asmjs",
|
|
||||||
target_arch = "wasm32",
|
target_arch = "wasm32",
|
||||||
target_arch = "hexagon",
|
target_arch = "hexagon",
|
||||||
all(target_arch = "riscv32", not(target_os = "espidf")),
|
all(target_arch = "riscv32", not(target_os = "espidf")),
|
||||||
|
@ -174,17 +174,6 @@ pub mod os {
|
|||||||
pub const EXE_EXTENSION: &str = "elf";
|
pub const EXE_EXTENSION: &str = "elf";
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(all(target_os = "emscripten", target_arch = "asmjs"))]
|
|
||||||
pub mod os {
|
|
||||||
pub const FAMILY: &str = "unix";
|
|
||||||
pub const OS: &str = "emscripten";
|
|
||||||
pub const DLL_PREFIX: &str = "lib";
|
|
||||||
pub const DLL_SUFFIX: &str = ".so";
|
|
||||||
pub const DLL_EXTENSION: &str = "so";
|
|
||||||
pub const EXE_SUFFIX: &str = ".js";
|
|
||||||
pub const EXE_EXTENSION: &str = "js";
|
|
||||||
}
|
|
||||||
|
|
||||||
#[cfg(all(target_os = "emscripten", target_arch = "wasm32"))]
|
#[cfg(all(target_os = "emscripten", target_arch = "wasm32"))]
|
||||||
pub mod os {
|
pub mod os {
|
||||||
pub const FAMILY: &str = "unix";
|
pub const FAMILY: &str = "unix";
|
||||||
|
@ -98,7 +98,7 @@ const EXTRA_CHECK_CFGS: &[(Option<Mode>, &str, Option<&[&'static str]>)] = &[
|
|||||||
/* Extra values not defined in the built-in targets yet, but used in std */
|
/* Extra values not defined in the built-in targets yet, but used in std */
|
||||||
(Some(Mode::Std), "target_env", Some(&["libnx"])),
|
(Some(Mode::Std), "target_env", Some(&["libnx"])),
|
||||||
// (Some(Mode::Std), "target_os", Some(&[])),
|
// (Some(Mode::Std), "target_os", Some(&[])),
|
||||||
(Some(Mode::Std), "target_arch", Some(&["asmjs", "spirv", "nvptx", "xtensa"])),
|
(Some(Mode::Std), "target_arch", Some(&["spirv", "nvptx", "xtensa"])),
|
||||||
/* Extra names used by dependencies */
|
/* Extra names used by dependencies */
|
||||||
// FIXME: Used by serde_json, but we should not be triggering on external dependencies.
|
// FIXME: Used by serde_json, but we should not be triggering on external dependencies.
|
||||||
(Some(Mode::Rustc), "no_btreemap_remove_entry", None),
|
(Some(Mode::Rustc), "no_btreemap_remove_entry", None),
|
||||||
|
@ -1,43 +0,0 @@
|
|||||||
FROM ubuntu:16.04
|
|
||||||
|
|
||||||
RUN apt-get update && apt-get install -y --no-install-recommends \
|
|
||||||
g++ \
|
|
||||||
make \
|
|
||||||
ninja-build \
|
|
||||||
file \
|
|
||||||
curl \
|
|
||||||
ca-certificates \
|
|
||||||
python3 \
|
|
||||||
git \
|
|
||||||
cmake \
|
|
||||||
sudo \
|
|
||||||
gdb \
|
|
||||||
xz-utils \
|
|
||||||
bzip2
|
|
||||||
|
|
||||||
COPY scripts/emscripten.sh /scripts/
|
|
||||||
RUN bash /scripts/emscripten.sh
|
|
||||||
|
|
||||||
COPY scripts/sccache.sh /scripts/
|
|
||||||
RUN sh /scripts/sccache.sh
|
|
||||||
|
|
||||||
ENV PATH=$PATH:/emsdk-portable
|
|
||||||
ENV PATH=$PATH:/emsdk-portable/upstream/emscripten/
|
|
||||||
ENV PATH=$PATH:/emsdk-portable/node/12.9.1_64bit/bin/
|
|
||||||
ENV BINARYEN_ROOT=/emsdk-portable/upstream/
|
|
||||||
|
|
||||||
ENV TARGETS=asmjs-unknown-emscripten
|
|
||||||
|
|
||||||
# Use -O1 optimizations in the link step to reduce time spent optimizing JS.
|
|
||||||
ENV EMCC_CFLAGS=-O1
|
|
||||||
|
|
||||||
# Emscripten installation is user-specific
|
|
||||||
ENV NO_CHANGE_USER=1
|
|
||||||
|
|
||||||
ENV SCRIPT python3 ../x.py --stage 2 test --host='' --target $TARGETS
|
|
||||||
|
|
||||||
# This is almost identical to the wasm32-unknown-emscripten target, so
|
|
||||||
# running with assertions again is not useful
|
|
||||||
ENV NO_DEBUG_ASSERTIONS=1
|
|
||||||
ENV NO_LLVM_ASSERTIONS=1
|
|
||||||
ENV NO_OVERFLOW_CHECKS=1
|
|
@ -75,8 +75,7 @@ ENV RUN_MAKE_TARGETS=$RUN_MAKE_TARGETS,thumbv7m-none-eabi
|
|||||||
ENV RUN_MAKE_TARGETS=$RUN_MAKE_TARGETS,thumbv7em-none-eabi
|
ENV RUN_MAKE_TARGETS=$RUN_MAKE_TARGETS,thumbv7em-none-eabi
|
||||||
ENV RUN_MAKE_TARGETS=$RUN_MAKE_TARGETS,thumbv7em-none-eabihf
|
ENV RUN_MAKE_TARGETS=$RUN_MAKE_TARGETS,thumbv7em-none-eabihf
|
||||||
|
|
||||||
ENV TARGETS=asmjs-unknown-emscripten
|
ENV TARGETS=wasm32-unknown-emscripten
|
||||||
ENV TARGETS=$TARGETS,wasm32-unknown-emscripten
|
|
||||||
ENV TARGETS=$TARGETS,arm-unknown-linux-musleabi
|
ENV TARGETS=$TARGETS,arm-unknown-linux-musleabi
|
||||||
ENV TARGETS=$TARGETS,arm-unknown-linux-musleabihf
|
ENV TARGETS=$TARGETS,arm-unknown-linux-musleabihf
|
||||||
ENV TARGETS=$TARGETS,armv5te-unknown-linux-gnueabi
|
ENV TARGETS=$TARGETS,armv5te-unknown-linux-gnueabi
|
||||||
|
@ -148,7 +148,6 @@ target | std | notes
|
|||||||
`armv7a-none-eabi` | * | Bare ARMv7-A
|
`armv7a-none-eabi` | * | Bare ARMv7-A
|
||||||
`armv7r-none-eabi` | * | Bare ARMv7-R
|
`armv7r-none-eabi` | * | Bare ARMv7-R
|
||||||
`armv7r-none-eabihf` | * | Bare ARMv7-R, hardfloat
|
`armv7r-none-eabihf` | * | Bare ARMv7-R, hardfloat
|
||||||
`asmjs-unknown-emscripten` | ✓ | asm.js via Emscripten
|
|
||||||
`i586-pc-windows-msvc` | * | 32-bit Windows w/o SSE [^x86_32-floats-x87]
|
`i586-pc-windows-msvc` | * | 32-bit Windows w/o SSE [^x86_32-floats-x87]
|
||||||
`i586-unknown-linux-gnu` | ✓ | 32-bit Linux w/o SSE (kernel 3.2, glibc 2.17) [^x86_32-floats-x87]
|
`i586-unknown-linux-gnu` | ✓ | 32-bit Linux w/o SSE (kernel 3.2, glibc 2.17) [^x86_32-floats-x87]
|
||||||
`i586-unknown-linux-musl` | ✓ | 32-bit Linux w/o SSE, MUSL [^x86_32-floats-x87]
|
`i586-unknown-linux-musl` | ✓ | 32-bit Linux w/o SSE, MUSL [^x86_32-floats-x87]
|
||||||
|
@ -516,7 +516,6 @@ impl<'a> fmt::Display for Display<'a> {
|
|||||||
(sym::target_arch, Some(arch)) => match arch.as_str() {
|
(sym::target_arch, Some(arch)) => match arch.as_str() {
|
||||||
"aarch64" => "AArch64",
|
"aarch64" => "AArch64",
|
||||||
"arm" => "ARM",
|
"arm" => "ARM",
|
||||||
"asmjs" => "JavaScript",
|
|
||||||
"loongarch64" => "LoongArch LA64",
|
"loongarch64" => "LoongArch LA64",
|
||||||
"m68k" => "M68k",
|
"m68k" => "M68k",
|
||||||
"csky" => "CSKY",
|
"csky" => "CSKY",
|
||||||
|
@ -82,7 +82,6 @@ static TARGETS: &[&str] = &[
|
|||||||
"armv7r-none-eabi",
|
"armv7r-none-eabi",
|
||||||
"armv7r-none-eabihf",
|
"armv7r-none-eabihf",
|
||||||
"armv7s-apple-ios",
|
"armv7s-apple-ios",
|
||||||
"asmjs-unknown-emscripten",
|
|
||||||
"bpfeb-unknown-none",
|
"bpfeb-unknown-none",
|
||||||
"bpfel-unknown-none",
|
"bpfel-unknown-none",
|
||||||
"i386-apple-ios",
|
"i386-apple-ios",
|
||||||
|
@ -410,9 +410,6 @@ impl Config {
|
|||||||
|
|
||||||
pub fn matches_arch(&self, arch: &str) -> bool {
|
pub fn matches_arch(&self, arch: &str) -> bool {
|
||||||
self.target_cfg().arch == arch ||
|
self.target_cfg().arch == arch ||
|
||||||
// Shorthand for convenience. The arch for
|
|
||||||
// asmjs-unknown-emscripten is actually wasm32.
|
|
||||||
(arch == "asmjs" && self.target.starts_with("asmjs")) ||
|
|
||||||
// Matching all the thumb variants as one can be convenient.
|
// Matching all the thumb variants as one can be convenient.
|
||||||
// (thumbv6m, thumbv7em, thumbv7m, etc.)
|
// (thumbv6m, thumbv7em, thumbv7m, etc.)
|
||||||
(arch == "thumb" && self.target.starts_with("thumb"))
|
(arch == "thumb" && self.target.starts_with("thumb"))
|
||||||
|
@ -146,19 +146,13 @@ pub(super) fn parse_cfg_name_directive<'a>(
|
|||||||
}
|
}
|
||||||
|
|
||||||
// `wasm32-bare` is an alias to refer to just wasm32-unknown-unknown
|
// `wasm32-bare` is an alias to refer to just wasm32-unknown-unknown
|
||||||
// (in contrast to `wasm32` which also matches non-bare targets like
|
// (in contrast to `wasm32` which also matches non-bare targets)
|
||||||
// asmjs-unknown-emscripten).
|
|
||||||
condition! {
|
condition! {
|
||||||
name: "wasm32-bare",
|
name: "wasm32-bare",
|
||||||
condition: config.target == "wasm32-unknown-unknown",
|
condition: config.target == "wasm32-unknown-unknown",
|
||||||
message: "when the target is WASM"
|
message: "when the target is WASM"
|
||||||
}
|
}
|
||||||
|
|
||||||
condition! {
|
|
||||||
name: "asmjs",
|
|
||||||
condition: config.target.starts_with("asmjs"),
|
|
||||||
message: "when the architecture is asm.js",
|
|
||||||
}
|
|
||||||
condition! {
|
condition! {
|
||||||
name: "thumb",
|
name: "thumb",
|
||||||
condition: config.target.starts_with("thumb"),
|
condition: config.target.starts_with("thumb"),
|
||||||
|
@ -398,8 +398,6 @@ fn ignore_arch() {
|
|||||||
("x86_64-unknown-linux-gnu", "x86_64"),
|
("x86_64-unknown-linux-gnu", "x86_64"),
|
||||||
("i686-unknown-linux-gnu", "x86"),
|
("i686-unknown-linux-gnu", "x86"),
|
||||||
("nvptx64-nvidia-cuda", "nvptx64"),
|
("nvptx64-nvidia-cuda", "nvptx64"),
|
||||||
("asmjs-unknown-emscripten", "wasm32"),
|
|
||||||
("asmjs-unknown-emscripten", "asmjs"),
|
|
||||||
("thumbv7m-none-eabi", "thumb"),
|
("thumbv7m-none-eabi", "thumb"),
|
||||||
];
|
];
|
||||||
for (target, arch) in archs {
|
for (target, arch) in archs {
|
||||||
@ -492,9 +490,6 @@ fn wasm_special() {
|
|||||||
("wasm32-unknown-unknown", "wasm32", true),
|
("wasm32-unknown-unknown", "wasm32", true),
|
||||||
("wasm32-unknown-unknown", "wasm32-bare", true),
|
("wasm32-unknown-unknown", "wasm32-bare", true),
|
||||||
("wasm32-unknown-unknown", "wasm64", false),
|
("wasm32-unknown-unknown", "wasm64", false),
|
||||||
("asmjs-unknown-emscripten", "emscripten", true),
|
|
||||||
("asmjs-unknown-emscripten", "wasm32", true),
|
|
||||||
("asmjs-unknown-emscripten", "wasm32-bare", false),
|
|
||||||
("wasm32-unknown-emscripten", "emscripten", true),
|
("wasm32-unknown-emscripten", "emscripten", true),
|
||||||
("wasm32-unknown-emscripten", "wasm32", true),
|
("wasm32-unknown-emscripten", "wasm32", true),
|
||||||
("wasm32-unknown-emscripten", "wasm32-bare", false),
|
("wasm32-unknown-emscripten", "wasm32-bare", false),
|
||||||
|
@ -345,7 +345,7 @@ trait EvalContextExtPriv<'mir, 'tcx: 'mir>: crate::MiriInterpCxExt<'mir, 'tcx> {
|
|||||||
// List taken from `library/std/src/sys/common/alloc.rs`.
|
// List taken from `library/std/src/sys/common/alloc.rs`.
|
||||||
// This list should be kept in sync with the one from libstd.
|
// This list should be kept in sync with the one from libstd.
|
||||||
let min_align = match this.tcx.sess.target.arch.as_ref() {
|
let min_align = match this.tcx.sess.target.arch.as_ref() {
|
||||||
"x86" | "arm" | "mips" | "mips32r6" | "powerpc" | "powerpc64" | "asmjs" | "wasm32" => 8,
|
"x86" | "arm" | "mips" | "mips32r6" | "powerpc" | "powerpc64" | "wasm32" => 8,
|
||||||
"x86_64" | "aarch64" | "mips64" | "mips64r6" | "s390x" | "sparc64" | "loongarch64" =>
|
"x86_64" | "aarch64" | "mips64" | "mips64r6" | "s390x" | "sparc64" | "loongarch64" =>
|
||||||
16,
|
16,
|
||||||
arch => bug!("unsupported target architecture for malloc: `{}`", arch),
|
arch => bug!("unsupported target architecture for malloc: `{}`", arch),
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
// targets, with the exception of nvptx64-nvidia-cuda
|
// targets, with the exception of nvptx64-nvidia-cuda
|
||||||
//
|
//
|
||||||
// revisions: r1 r2 r3 r4 r5 r6 r7 r8 r9 r10 r11 r12 r13 r14 r15 r16 r17 r18 r19 r20 r21 r22 r23
|
// revisions: r1 r2 r3 r4 r5 r6 r7 r8 r9 r10 r11 r12 r13 r14 r15 r16 r17 r18 r19 r20 r21 r22 r23
|
||||||
// revisions: r24 r25 r26 r27 r28 r29 r30 r31 r32 r33 r34 r35 r36 r37 r38 r39 r40 r41 r42 r43 r44
|
// revisions: r24 r25 r26 r27 r28 r29 r30 r31 r32 r33 r35 r36 r37 r38 r39 r40 r41 r42 r43 r44
|
||||||
// revisions: r45 r46 r47 r48 r49 r50 r51 r52 r53 r54 r55 r56 r57 r58 r59 r60 r61 r62 r63 r64 r65
|
// revisions: r45 r46 r47 r48 r49 r50 r51 r52 r53 r54 r55 r56 r57 r58 r59 r60 r61 r62 r63 r64 r65
|
||||||
// revisions: r66 r67 r68 r69 r70 r71 r72 r73 r74 r75 r76 r77 r78 r79 r80 r81 r82 r83 r84
|
// revisions: r66 r67 r68 r69 r70 r71 r72 r73 r74 r75 r76 r77 r78 r79 r80 r81 r82 r83 r84
|
||||||
// assembly-output: emit-asm
|
// assembly-output: emit-asm
|
||||||
@ -72,8 +72,7 @@
|
|||||||
// [r32] needs-llvm-components: arm
|
// [r32] needs-llvm-components: arm
|
||||||
// [r33] compile-flags: --target armv7-unknown-linux-musleabihf
|
// [r33] compile-flags: --target armv7-unknown-linux-musleabihf
|
||||||
// [r33] needs-llvm-components: arm
|
// [r33] needs-llvm-components: arm
|
||||||
// [r34] compile-flags: --target asmjs-unknown-emscripten
|
|
||||||
// [r34] needs-llvm-components: webassembly
|
|
||||||
// [r35] compile-flags: --target i586-pc-windows-msvc
|
// [r35] compile-flags: --target i586-pc-windows-msvc
|
||||||
// [r35] needs-llvm-components: x86
|
// [r35] needs-llvm-components: x86
|
||||||
// [r36] compile-flags: --target i586-unknown-linux-gnu
|
// [r36] compile-flags: --target i586-unknown-linux-gnu
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
// Test that changing a tracked commandline argument invalidates
|
// Test that changing a tracked commandline argument invalidates
|
||||||
// the cache while changing an untracked one doesn't.
|
// the cache while changing an untracked one doesn't.
|
||||||
|
|
||||||
// ignore-asmjs wasm2js does not support source maps yet
|
|
||||||
// revisions:rpass1 rpass2 rpass3 rpass4
|
// revisions:rpass1 rpass2 rpass3 rpass4
|
||||||
// compile-flags: -Z query-dep-graph
|
// compile-flags: -Z query-dep-graph
|
||||||
|
|
||||||
|
@ -2,7 +2,6 @@
|
|||||||
// compile-flags: -Z query-dep-graph -g
|
// compile-flags: -Z query-dep-graph -g
|
||||||
// aux-build:extern_crate.rs
|
// aux-build:extern_crate.rs
|
||||||
|
|
||||||
// ignore-asmjs wasm2js does not support source maps yet
|
|
||||||
// This test case makes sure that we detect if paths emitted into debuginfo
|
// This test case makes sure that we detect if paths emitted into debuginfo
|
||||||
// are changed, even when the change happens in an external crate.
|
// are changed, even when the change happens in an external crate.
|
||||||
|
|
||||||
|
@ -3,7 +3,6 @@
|
|||||||
// the spans and this test makes sure that we handle them correctly by hashing
|
// the spans and this test makes sure that we handle them correctly by hashing
|
||||||
// file:line:column instead of raw byte offset.
|
// file:line:column instead of raw byte offset.
|
||||||
|
|
||||||
// ignore-asmjs wasm2js does not support source maps yet
|
|
||||||
// revisions:rpass1 rpass2
|
// revisions:rpass1 rpass2
|
||||||
// compile-flags: -g -Z query-dep-graph
|
// compile-flags: -g -Z query-dep-graph
|
||||||
|
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
// Test that moving a type definition within a source file does not affect
|
// Test that moving a type definition within a source file does not affect
|
||||||
// re-compilation.
|
// re-compilation.
|
||||||
|
|
||||||
// ignore-asmjs wasm2js does not support source maps yet
|
|
||||||
// revisions:rpass1 rpass2
|
// revisions:rpass1 rpass2
|
||||||
// compile-flags: -Z query-dep-graph -g
|
// compile-flags: -Z query-dep-graph -g
|
||||||
|
|
||||||
|
@ -3,7 +3,6 @@
|
|||||||
|
|
||||||
// revisions:rpass1 rpass2
|
// revisions:rpass1 rpass2
|
||||||
|
|
||||||
// ignore-asmjs wasm2js does not support source maps yet
|
|
||||||
// compile-flags: -g -Z query-dep-graph
|
// compile-flags: -g -Z query-dep-graph
|
||||||
|
|
||||||
#![feature(rustc_attrs)]
|
#![feature(rustc_attrs)]
|
||||||
|
@ -8,11 +8,6 @@ use std::ffi::VaList;
|
|||||||
extern "C" {
|
extern "C" {
|
||||||
fn rust_interesting_average(_: u64, ...) -> f64;
|
fn rust_interesting_average(_: u64, ...) -> f64;
|
||||||
|
|
||||||
// FIXME: we need to disable this lint for `VaList`,
|
|
||||||
// since it contains a `MaybeUninit<i32>` on the asmjs target,
|
|
||||||
// and this type isn't FFI-safe. This is OK for now,
|
|
||||||
// since the type is layout-compatible with `i32`.
|
|
||||||
#[cfg_attr(target_arch = "asmjs", allow(improper_ctypes))]
|
|
||||||
fn rust_valist_interesting_average(_: u64, _: VaList) -> f64;
|
fn rust_valist_interesting_average(_: u64, _: VaList) -> f64;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -3,7 +3,6 @@
|
|||||||
// compile-flags: -Copt-level=z -Cdebuginfo=2 --edition=2018
|
// compile-flags: -Copt-level=z -Cdebuginfo=2 --edition=2018
|
||||||
|
|
||||||
// run-pass
|
// run-pass
|
||||||
// ignore-asmjs wasm2js does not support source maps yet
|
|
||||||
|
|
||||||
use std::future::Future;
|
use std::future::Future;
|
||||||
use std::task::Poll;
|
use std::task::Poll;
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
// run-pass
|
// run-pass
|
||||||
#![allow(dead_code)]
|
#![allow(dead_code)]
|
||||||
// compile-flags: -g
|
// compile-flags: -g
|
||||||
// ignore-asmjs wasm2js does not support source maps yet
|
|
||||||
|
|
||||||
#[derive(PartialEq, Eq)]
|
#[derive(PartialEq, Eq)]
|
||||||
struct NewBool(bool);
|
struct NewBool(bool);
|
||||||
|
@ -28,9 +28,6 @@ pub fn main() { }
|
|||||||
#[cfg(target_arch = "s390x")]
|
#[cfg(target_arch = "s390x")]
|
||||||
pub fn main() { }
|
pub fn main() { }
|
||||||
|
|
||||||
#[cfg(target_arch = "asmjs")]
|
|
||||||
pub fn main() { }
|
|
||||||
|
|
||||||
#[cfg(target_arch = "wasm32")]
|
#[cfg(target_arch = "wasm32")]
|
||||||
pub fn main() { }
|
pub fn main() { }
|
||||||
|
|
||||||
|
@ -1,6 +1,5 @@
|
|||||||
// run-pass
|
// run-pass
|
||||||
// compile-flags: -g
|
// compile-flags: -g
|
||||||
// ignore-asmjs wasm2js does not support source maps yet
|
|
||||||
|
|
||||||
#![feature(coroutines, coroutine_trait)]
|
#![feature(coroutines, coroutine_trait)]
|
||||||
|
|
||||||
|
@ -11,7 +11,6 @@
|
|||||||
|
|
||||||
// edition:2018
|
// edition:2018
|
||||||
// ignore-wasm32 issue #62807
|
// ignore-wasm32 issue #62807
|
||||||
// ignore-asmjs issue #62807
|
|
||||||
// needs-unwind Size of Closures change on panic=abort
|
// needs-unwind Size of Closures change on panic=abort
|
||||||
|
|
||||||
#![feature(coroutines, coroutine_trait)]
|
#![feature(coroutines, coroutine_trait)]
|
||||||
|
1
tests/ui/extern/extern-const.fixed
vendored
1
tests/ui/extern/extern-const.fixed
vendored
@ -6,7 +6,6 @@
|
|||||||
|
|
||||||
// run-rustfix
|
// run-rustfix
|
||||||
// ignore-wasm32-bare no external library to link to.
|
// ignore-wasm32-bare no external library to link to.
|
||||||
// ignore-asmjs wasm2js does not support source maps yet
|
|
||||||
// compile-flags: -g
|
// compile-flags: -g
|
||||||
#![feature(rustc_private)]
|
#![feature(rustc_private)]
|
||||||
extern crate libc;
|
extern crate libc;
|
||||||
|
1
tests/ui/extern/extern-const.rs
vendored
1
tests/ui/extern/extern-const.rs
vendored
@ -6,7 +6,6 @@
|
|||||||
|
|
||||||
// run-rustfix
|
// run-rustfix
|
||||||
// ignore-wasm32-bare no external library to link to.
|
// ignore-wasm32-bare no external library to link to.
|
||||||
// ignore-asmjs wasm2js does not support source maps yet
|
|
||||||
// compile-flags: -g
|
// compile-flags: -g
|
||||||
#![feature(rustc_private)]
|
#![feature(rustc_private)]
|
||||||
extern crate libc;
|
extern crate libc;
|
||||||
|
2
tests/ui/extern/extern-const.stderr
vendored
2
tests/ui/extern/extern-const.stderr
vendored
@ -1,5 +1,5 @@
|
|||||||
error: extern items cannot be `const`
|
error: extern items cannot be `const`
|
||||||
--> $DIR/extern-const.rs:16:11
|
--> $DIR/extern-const.rs:15:11
|
||||||
|
|
|
|
||||||
LL | const rust_dbg_static_mut: libc::c_int;
|
LL | const rust_dbg_static_mut: libc::c_int;
|
||||||
| ------^^^^^^^^^^^^^^^^^^^
|
| ------^^^^^^^^^^^^^^^^^^^
|
||||||
|
@ -2,7 +2,6 @@
|
|||||||
// Test for issue #18804, #[linkage] does not propagate through generic
|
// Test for issue #18804, #[linkage] does not propagate through generic
|
||||||
// functions. Failure results in a linker error.
|
// functions. Failure results in a linker error.
|
||||||
|
|
||||||
// ignore-asmjs no weak symbol support
|
|
||||||
// ignore-emscripten no weak symbol support
|
// ignore-emscripten no weak symbol support
|
||||||
// ignore-windows no extern_weak linkage
|
// ignore-windows no extern_weak linkage
|
||||||
// ignore-macos no extern_weak linkage
|
// ignore-macos no extern_weak linkage
|
||||||
|
@ -1,5 +1,4 @@
|
|||||||
// build-pass
|
// build-pass
|
||||||
// ignore-asmjs wasm2js does not support source maps yet
|
|
||||||
// compile-flags: -g
|
// compile-flags: -g
|
||||||
|
|
||||||
pub struct Dst {
|
pub struct Dst {
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
// run-pass
|
// run-pass
|
||||||
// aux-build:issue-24687-lib.rs
|
// aux-build:issue-24687-lib.rs
|
||||||
// compile-flags:-g
|
// compile-flags:-g
|
||||||
// ignore-asmjs wasm2js does not support source maps yet
|
|
||||||
|
|
||||||
extern crate issue_24687_lib as d;
|
extern crate issue_24687_lib as d;
|
||||||
|
|
||||||
|
@ -3,7 +3,6 @@
|
|||||||
// as options to the compiler.
|
// as options to the compiler.
|
||||||
|
|
||||||
// compile-flags:-g -g -O -O
|
// compile-flags:-g -g -O -O
|
||||||
// ignore-asmjs wasm2js does not support source maps yet
|
|
||||||
|
|
||||||
fn main() {
|
fn main() {
|
||||||
assert_eq!(1, 1);
|
assert_eq!(1, 1);
|
||||||
|
@ -1,6 +1,5 @@
|
|||||||
// run-pass
|
// run-pass
|
||||||
// compile-flags:-g
|
// compile-flags:-g
|
||||||
// ignore-asmjs wasm2js does not support source maps yet
|
|
||||||
|
|
||||||
fn helper<F: FnOnce(usize) -> bool>(_f: F) {
|
fn helper<F: FnOnce(usize) -> bool>(_f: F) {
|
||||||
print!("");
|
print!("");
|
||||||
|
@ -1,6 +1,5 @@
|
|||||||
// run-pass
|
// run-pass
|
||||||
// compile-flags: -g
|
// compile-flags: -g
|
||||||
// ignore-asmjs wasm2js does not support source maps yet
|
|
||||||
|
|
||||||
use std::ops::Deref;
|
use std::ops::Deref;
|
||||||
|
|
||||||
|
@ -1,6 +1,5 @@
|
|||||||
// run-pass
|
// run-pass
|
||||||
// compile-flags:-g
|
// compile-flags:-g
|
||||||
// ignore-asmjs wasm2js does not support source maps yet
|
|
||||||
|
|
||||||
// In this test we just want to make sure that the code below does not lead to
|
// In this test we just want to make sure that the code below does not lead to
|
||||||
// a debuginfo verification assertion during compilation. This was caused by the
|
// a debuginfo verification assertion during compilation. This was caused by the
|
||||||
|
@ -2,7 +2,6 @@
|
|||||||
// Regression test for #36856.
|
// Regression test for #36856.
|
||||||
|
|
||||||
// compile-flags:-g
|
// compile-flags:-g
|
||||||
// ignore-asmjs wasm2js does not support source maps yet
|
|
||||||
|
|
||||||
fn g() -> bool {
|
fn g() -> bool {
|
||||||
false
|
false
|
||||||
|
@ -2,7 +2,6 @@
|
|||||||
// Regression test for #42210.
|
// Regression test for #42210.
|
||||||
|
|
||||||
// compile-flags: -g
|
// compile-flags: -g
|
||||||
// ignore-asmjs wasm2js does not support source maps yet
|
|
||||||
|
|
||||||
trait Foo {
|
trait Foo {
|
||||||
fn foo() { }
|
fn foo() { }
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
// run-pass
|
// run-pass
|
||||||
#![allow(unused_variables)]
|
#![allow(unused_variables)]
|
||||||
// compile-flags:--test -g
|
// compile-flags:--test -g
|
||||||
// ignore-asmjs wasm2js does not support source maps yet
|
|
||||||
|
|
||||||
#[cfg(target_os = "macos")]
|
#[cfg(target_os = "macos")]
|
||||||
#[test]
|
#[test]
|
||||||
|
@ -1,6 +1,5 @@
|
|||||||
// run-pass
|
// run-pass
|
||||||
// compile-flags:-C debuginfo=2
|
// compile-flags:-C debuginfo=2
|
||||||
// ignore-asmjs wasm2js does not support source maps yet
|
|
||||||
|
|
||||||
fn foo() -> impl Copy {
|
fn foo() -> impl Copy {
|
||||||
foo
|
foo
|
||||||
|
@ -7,7 +7,6 @@
|
|||||||
// aux-build:debuginfo-lto-aux.rs
|
// aux-build:debuginfo-lto-aux.rs
|
||||||
// compile-flags: -C lto -g
|
// compile-flags: -C lto -g
|
||||||
// no-prefer-dynamic
|
// no-prefer-dynamic
|
||||||
// ignore-asmjs wasm2js does not support source maps yet
|
|
||||||
|
|
||||||
extern crate debuginfo_lto_aux;
|
extern crate debuginfo_lto_aux;
|
||||||
|
|
||||||
|
@ -7,7 +7,6 @@
|
|||||||
// issue-48508-aux.rs
|
// issue-48508-aux.rs
|
||||||
|
|
||||||
// compile-flags:-g
|
// compile-flags:-g
|
||||||
// ignore-asmjs wasm2js does not support source maps yet
|
|
||||||
|
|
||||||
#![allow(uncommon_codepoints)]
|
#![allow(uncommon_codepoints)]
|
||||||
|
|
||||||
|
@ -4,7 +4,6 @@
|
|||||||
|
|
||||||
// aux-build:sepcomp_lib.rs
|
// aux-build:sepcomp_lib.rs
|
||||||
// compile-flags: -C lto -g
|
// compile-flags: -C lto -g
|
||||||
// ignore-asmjs wasm2js does not support source maps yet
|
|
||||||
// no-prefer-dynamic
|
// no-prefer-dynamic
|
||||||
|
|
||||||
extern crate sepcomp_lib;
|
extern crate sepcomp_lib;
|
||||||
|
@ -10,7 +10,6 @@
|
|||||||
// This is a regression test for issue #17021.
|
// This is a regression test for issue #17021.
|
||||||
//
|
//
|
||||||
// compile-flags: -g
|
// compile-flags: -g
|
||||||
// ignore-asmjs wasm2js does not support source maps yet
|
|
||||||
|
|
||||||
use std::ptr;
|
use std::ptr;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user