Skip to content

Commit 35a3a2e

Browse files
committed
Augment stdarch-test to parse PPC
- Remove some unused env variables from `run.sh`
1 parent cbe0f39 commit 35a3a2e

File tree

3 files changed

+7
-4
lines changed

3 files changed

+7
-4
lines changed

ci/run-docker.sh

-2
Original file line numberDiff line numberDiff line change
@@ -23,12 +23,10 @@ run() {
2323
--env CARGO_TARGET_DIR=/checkout/target \
2424
--env TARGET="${1}" \
2525
--env STDARCH_TEST_EVERYTHING \
26-
--env STDARCH_ASSERT_INSTR_IGNORE \
2726
--env STDARCH_DISABLE_ASSERT_INSTR \
2827
--env NOSTD \
2928
--env NORUN \
3029
--env RUSTFLAGS \
31-
--env STDARCH_TEST_NORUN \
3230
--volume "${HOME}/.cargo":/cargo \
3331
--volume "$(rustc --print sysroot)":/rust:ro \
3432
--volume "$(pwd)":/checkout:ro \

crates/stdarch-test/src/disassembly.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ fn normalize(mut symbol: &str) -> String {
2929

3030
// Normalize to no leading underscore to handle platforms that may
3131
// inject extra ones in symbol names.
32-
while symbol.starts_with('_') {
32+
while symbol.starts_with('_') || symbol.starts_with('.') {
3333
symbol.remove(0);
3434
}
3535
// Windows/x86 has a suffix such as @@4.

crates/stdarch-test/src/lib.rs

+6-1
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,12 @@ pub fn assert(shim_addr: usize, fnname: &str, expected: &str) {
104104
// failed inlining something.
105105
s[0].starts_with("call ") && s[1].starts_with("pop") // FIXME: original logic but does not match comment
106106
})
107-
} else if cfg!(any(target_arch = "aarch64", target_arch = "arm64ec")) {
107+
} else if cfg!(any(
108+
target_arch = "aarch64",
109+
target_arch = "arm64ec",
110+
target_arch = "powerpc",
111+
target_arch = "powerpc64"
112+
)) {
108113
instrs.iter().any(|s| s.starts_with("bl "))
109114
} else {
110115
// FIXME: Add detection for other archs

0 commit comments

Comments
 (0)