Skip to content

Commit 1b7a927

Browse files
committed
ci: move tests from x86_64-gnu-llvm-19 job to aarch64
1 parent 95a2212 commit 1b7a927

File tree

8 files changed

+79
-7
lines changed

8 files changed

+79
-7
lines changed
Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
FROM ubuntu:24.10
2+
3+
ARG DEBIAN_FRONTEND=noninteractive
4+
5+
RUN apt-get update && apt-get install -y --no-install-recommends \
6+
bzip2 \
7+
g++ \
8+
make \
9+
ninja-build \
10+
file \
11+
curl \
12+
ca-certificates \
13+
python3 \
14+
git \
15+
cmake \
16+
sudo \
17+
gdb \
18+
llvm-19-tools \
19+
llvm-19-dev \
20+
libedit-dev \
21+
libssl-dev \
22+
pkg-config \
23+
zlib1g-dev \
24+
xz-utils \
25+
nodejs \
26+
mingw-w64 \
27+
# libgccjit dependencies
28+
flex \
29+
libmpfr-dev \
30+
libgmp-dev \
31+
libmpc3 \
32+
libmpc-dev \
33+
&& rm -rf /var/lib/apt/lists/*
34+
35+
COPY scripts/sccache.sh /scripts/
36+
RUN sh /scripts/sccache.sh
37+
38+
# We are disabling CI LLVM since this builder is intentionally using a host
39+
# LLVM, rather than the typical src/llvm-project LLVM.
40+
ENV NO_DOWNLOAD_CI_LLVM 1
41+
ENV EXTERNAL_LLVM 1
42+
43+
# Using llvm-link-shared due to libffi issues -- see #34486
44+
ENV RUST_CONFIGURE_ARGS \
45+
--build=aarch64-unknown-linux-gnu \
46+
--llvm-root=/usr/lib/llvm-19 \
47+
--enable-llvm-link-shared \
48+
--set rust.randomize-layout=true \
49+
--set rust.thin-lto-import-instr-limit=10
50+
51+
COPY scripts/shared.sh /scripts/
52+
53+
ARG SCRIPT_ARG
54+
55+
COPY scripts/stage_2_test_set1.sh /tmp/
56+
COPY scripts/stage_2_test_set2.sh /tmp/
57+
58+
ENV SCRIPT "/tmp/${SCRIPT_ARG}"

src/ci/docker/scripts/x86_64-gnu-llvm.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22

33
set -ex
44

5-
# NOTE: intentionally uses all of `x.py`, `x`, and `x.ps1` to make sure they all work on Linux.
6-
../x.py --stage 2 test --skip src/tools/tidy
5+
# NOTE: intentionally uses `x`, and `x.ps1` to make sure they work on Linux.
6+
# Make sure that `x.py` is tested elsewhere.
77

88
# Run the `mir-opt` tests again but this time for a 32-bit target.
99
# This enforces that tests using `// EMIT_MIR_FOR_EACH_BIT_WIDTH` have

src/ci/github-actions/jobs.yml

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,17 @@ pr:
121121
env:
122122
ENABLE_GCC_CODEGEN: "1"
123123
DOCKER_SCRIPT: x86_64-gnu-llvm.sh
124-
<<: *job-linux-16c
124+
<<: *job-linux-4c
125+
- name: aarch64-gnu-llvm-19-1
126+
env:
127+
IMAGE: aarch64-gnu-llvm-19
128+
DOCKER_SCRIPT: stage_2_test_set1.sh
129+
<<: *job-aarch64-linux-8c
130+
- name: aarch64-gnu-llvm-19-2
131+
env:
132+
IMAGE: aarch64-gnu-llvm-19
133+
DOCKER_SCRIPT: stage_2_test_set2.sh
134+
<<: *job-aarch64-linux
125135
- name: x86_64-gnu-tools
126136
<<: *job-linux-36c-codebuild
127137

tests/debuginfo/by-value-non-immediate-argument.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
//@ min-gdb-version: 13.0
33
//@ compile-flags:-g
44
//@ ignore-windows-gnu: #128973
5+
//@ ignore-aarch64-unknown-linux-gnu (gdb tries to read from 0x0; FIXME: #128973)
56

67
// === GDB TESTS ===================================================================================
78

tests/run-make/mte-ffi/bar.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
// FIXME(#141600) the mte-ffi test doesn't fail in aarch64-gnu
2+
13
#ifndef __BAR_H
24
#define __BAR_H
35

tests/run-make/mte-ffi/bar_float.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@
33
#include <stdint.h>
44
#include "bar.h"
55

6-
extern void foo(char*);
6+
extern void foo(float*);
77

8-
void bar(char *ptr) {
8+
void bar(float *ptr) {
99
if (((uintptr_t)ptr >> 56) != 0x1f) {
1010
fprintf(stderr, "Top byte corrupted on Rust -> C FFI boundary!\n");
1111
exit(1);

tests/run-make/mte-ffi/bar_int.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
extern void foo(unsigned int *);
77

8-
void bar(char *ptr) {
8+
void bar(unsigned int *ptr) {
99
if (((uintptr_t)ptr >> 56) != 0x1f) {
1010
fprintf(stderr, "Top byte corrupted on Rust -> C FFI boundary!\n");
1111
exit(1);

tests/run-make/mte-ffi/bar_string.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
#include <stdio.h>
22
#include <stdlib.h>
33
#include <stdint.h>
4+
#include <string.h>
45
#include "bar.h"
56

67
extern void foo(char*);
@@ -32,7 +33,7 @@ int main(void)
3233

3334
// Store an arbitrary tag in bits 56-59 of the pointer (where an MTE tag may be),
3435
// and a different value in the ignored top 4 bits.
35-
ptr = (unsigned int *)((uintptr_t)ptr | 0x1fl << 56);
36+
ptr = (char *)((uintptr_t)ptr | 0x1fl << 56);
3637

3738
if (mte_enabled()) {
3839
set_tag(ptr);

0 commit comments

Comments
 (0)