Skip to content

Commit 35be999

Browse files
briansmithaddd45
authored andcommitted
CI: Add code coverage mesurement for powerpc-unknown-linux-gnu.
Profiler builtins were added in rust-lang/rust#119404.
1 parent 65a60bd commit 35be999

File tree

2 files changed

+12
-2
lines changed

2 files changed

+12
-2
lines changed

.github/workflows/ci.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -529,7 +529,7 @@ jobs:
529529
- i686-unknown-linux-gnu # Has assembly
530530
# TODO: arm-unknown-linux-gnueabi # Has assembly but doesn't build w/ clang
531531
# TODO: armv7-unknown-linux-gnueabihf # Has assembly but doesn't have profiler builtins
532-
# TODO: powerpc-unknown-linux-gnu No assembly 32-bit big-endian but doesn't have profiler builtins
532+
- powerpc-unknown-linux-gnu # No assembly 32-bit big-endian with flags
533533
- powerpc64-unknown-linux-gnu # No assembly 64-bit big-endian with flags
534534
- powerpc64le-unknown-linux-gnu # No assembly 64-bit little-endian with flags
535535
- riscv64gc-unknown-linux-gnu # No assembly 64-bit little-endian without flags
@@ -573,6 +573,9 @@ jobs:
573573
- target: i686-unknown-linux-gnu
574574
host_os: ubuntu-22.04
575575

576+
- target: powerpc-unknown-linux-gnu
577+
host_os: ubuntu-22.04
578+
576579
- target: powerpc64-unknown-linux-gnu
577580
host_os: ubuntu-22.04
578581

mk/cargo.sh

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -231,11 +231,18 @@ if [ -n "${RING_COVERAGE-}" ]; then
231231
;;
232232
esac
233233

234+
additional_rustflags=""
235+
case "$target" in
236+
powerpc-unknown-linux-gnu)
237+
additional_rustflags="-latomic"
238+
;;
239+
esac
240+
234241
runner_var=CARGO_TARGET_${target_upper}_RUNNER
235242
declare -x "${runner_var}=mk/runner ${!runner_var-}"
236243

237244
rustflags_var=CARGO_TARGET_${target_upper}_RUSTFLAGS
238-
declare -x "${rustflags_var}=-Cinstrument-coverage ${!rustflags_var-}"
245+
declare -x "${rustflags_var}=${additional_rustflags} -Cinstrument-coverage ${!rustflags_var-}"
239246
fi
240247

241248
if [ -n "${use_clang}" ]; then

0 commit comments

Comments
 (0)