Attempt to fix the tests
This commit is contained in:
parent
4115e09c13
commit
e74bc5113d
@ -29,10 +29,10 @@ git config user.name || git config user.name "None"
|
|||||||
|
|
||||||
git commit -m "Initial commit" -q
|
git commit -m "Initial commit" -q
|
||||||
for file in $(ls ../../patches/ | grep -v patcha); do
|
for file in $(ls ../../patches/ | grep -v patcha); do
|
||||||
echo "[GIT] apply" $file
|
echo "[GIT] apply" $file
|
||||||
git apply ../../patches/$file
|
git apply ../../patches/$file
|
||||||
git add -A
|
git add -A
|
||||||
git commit --no-gpg-sign -m "Patch $file"
|
git commit --no-gpg-sign -m "Patch $file"
|
||||||
done
|
done
|
||||||
popd
|
popd
|
||||||
|
|
||||||
|
@ -165,10 +165,15 @@ pub fn generic_simd_intrinsic<'a, 'gcc, 'tcx>(
|
|||||||
InvalidMonomorphizationReturnIntegerType { span, name, ret_ty, out_ty }
|
InvalidMonomorphizationReturnIntegerType { span, name, ret_ty, out_ty }
|
||||||
);
|
);
|
||||||
|
|
||||||
|
let arg1 = args[0].immediate();
|
||||||
|
// NOTE: we get different vector types for the same vector type and libgccjit doesn't
|
||||||
|
// compare them as equal, so bitcast.
|
||||||
|
// FIXME(antoyo): allow comparing vector types as equal in libgccjit.
|
||||||
|
let arg2 = bx.context.new_bitcast(None, args[1].immediate(), arg1.get_type());
|
||||||
return Ok(compare_simd_types(
|
return Ok(compare_simd_types(
|
||||||
bx,
|
bx,
|
||||||
args[0].immediate(),
|
arg1,
|
||||||
args[1].immediate(),
|
arg2,
|
||||||
in_elem,
|
in_elem,
|
||||||
llret_ty,
|
llret_ty,
|
||||||
cmp_op,
|
cmp_op,
|
||||||
|
@ -1,3 +1,5 @@
|
|||||||
|
// FIXME: simple programs now segfault with a sysroot compile in release mode.
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* TODO(antoyo): implement equality in libgccjit based on https://zpz.github.io/blog/overloading-equality-operator-in-cpp-class-hierarchy/ (for type equality?)
|
* TODO(antoyo): implement equality in libgccjit based on https://zpz.github.io/blog/overloading-equality-operator-in-cpp-class-hierarchy/ (for type equality?)
|
||||||
* TODO(antoyo): support #[inline] attributes.
|
* TODO(antoyo): support #[inline] attributes.
|
||||||
|
15
test.sh
15
test.sh
@ -214,12 +214,14 @@ function setup_rustc() {
|
|||||||
rm config.toml || true
|
rm config.toml || true
|
||||||
|
|
||||||
cat > config.toml <<EOF
|
cat > config.toml <<EOF
|
||||||
|
changelog-seen = 2
|
||||||
|
|
||||||
[rust]
|
[rust]
|
||||||
codegen-backends = []
|
codegen-backends = []
|
||||||
deny-warnings = false
|
deny-warnings = false
|
||||||
|
|
||||||
[build]
|
[build]
|
||||||
cargo = "$(which cargo)"
|
cargo = "$(rustup which cargo)"
|
||||||
local-rebuild = true
|
local-rebuild = true
|
||||||
rustc = "$HOME/.rustup/toolchains/$rust_toolchain-$TARGET_TRIPLE/bin/rustc"
|
rustc = "$HOME/.rustup/toolchains/$rust_toolchain-$TARGET_TRIPLE/bin/rustc"
|
||||||
|
|
||||||
@ -237,7 +239,7 @@ EOF
|
|||||||
function asm_tests() {
|
function asm_tests() {
|
||||||
setup_rustc
|
setup_rustc
|
||||||
|
|
||||||
echo "[TEST] rustc test suite"
|
echo "[TEST] rustc asm test suite"
|
||||||
RUSTC_ARGS="-Zpanic-abort-tests -Csymbol-mangling-version=v0 -Zcodegen-backend="$(pwd)"/../target/"$CHANNEL"/librustc_codegen_gcc."$dylib_ext" --sysroot "$(pwd)"/../build_sysroot/sysroot -Cpanic=abort"
|
RUSTC_ARGS="-Zpanic-abort-tests -Csymbol-mangling-version=v0 -Zcodegen-backend="$(pwd)"/../target/"$CHANNEL"/librustc_codegen_gcc."$dylib_ext" --sysroot "$(pwd)"/../build_sysroot/sysroot -Cpanic=abort"
|
||||||
COMPILETEST_FORCE_STAGE0=1 ./x.py test --run always --stage 0 tests/assembly/asm --rustc-args "$RUSTC_ARGS"
|
COMPILETEST_FORCE_STAGE0=1 ./x.py test --run always --stage 0 tests/assembly/asm --rustc-args "$RUSTC_ARGS"
|
||||||
}
|
}
|
||||||
@ -351,7 +353,14 @@ function test_rustc() {
|
|||||||
git checkout tests/ui/type-alias-impl-trait/auxiliary/cross_crate_ice2.rs
|
git checkout tests/ui/type-alias-impl-trait/auxiliary/cross_crate_ice2.rs
|
||||||
git checkout tests/ui/macros/rfc-2011-nicer-assert-messages/auxiliary/common.rs
|
git checkout tests/ui/macros/rfc-2011-nicer-assert-messages/auxiliary/common.rs
|
||||||
|
|
||||||
RUSTC_ARGS="$TEST_FLAGS -Csymbol-mangling-version=v0 -Zcodegen-backend="$(pwd)"/../target/"$CHANNEL"/librustc_codegen_gcc."$dylib_ext" --sysroot "$(pwd)"/../build_sysroot/sysroot"
|
# We need to overwrite the sysroot in the tests, now.
|
||||||
|
# TODO(antoyo): find a faster way to do this.
|
||||||
|
# FIXME: this makes the stderr different since it changes the line numbers.
|
||||||
|
for file in $(find tests/ui -type f -name '*.rs'); do
|
||||||
|
sed -ie "1i // compile-flags: --sysroot "$(pwd)"/../build_sysroot/sysroot\n" $file
|
||||||
|
done
|
||||||
|
|
||||||
|
RUSTC_ARGS="$TEST_FLAGS -Csymbol-mangling-version=v0 -Zcodegen-backend="$(pwd)"/../target/"$CHANNEL"/librustc_codegen_gcc."$dylib_ext""
|
||||||
|
|
||||||
if [ $# -eq 0 ]; then
|
if [ $# -eq 0 ]; then
|
||||||
# No argument supplied to the function. Doing nothing.
|
# No argument supplied to the function. Doing nothing.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user