tests: check wasm compiler_builtins object architecture#156230
Conversation
|
|
This comment has been minimized.
This comment has been minimized.
211904e to
b25f8a1
Compare
|
Reminder, once the PR becomes ready for a review, use |
b25f8a1 to
962838f
Compare
|
Thanks for the feedback! I've just force-pushed the fixes to the branch. Addresssed everything we discussed: added the module-level docs with links, and broadened the directive to only-wasm to cover other targets. I also flipped the filter to skip only .rmeta so unexpected files will actually trigger a failure now. For the wasm check, i dropped the raw magic bytes and went with object::File::parse + matching on Wasm32/Wasm64. Also cleaned up the misleading assert message about compiler-builtins-c and dropped the trailing eprintln!. Let me know what you think! |
This comment has been minimized.
This comment has been minimized.
962838f to
50ad258
Compare
|
@bors try jobs=test-various* |
This comment has been minimized.
This comment has been minimized.
…ect-arch, r=<try> tests: check wasm compiler_builtins object architecture try-job: test-various*
|
@bors try jobs=test-various* |
This comment has been minimized.
This comment has been minimized.
…ect-arch, r=<try> tests: check wasm compiler_builtins object architecture try-job: test-various*
|
💔 Test for 30c565b failed: CI. Failed job:
|
This comment has been minimized.
This comment has been minimized.
50ad258 to
266e90f
Compare
|
|
Pushed a fix - @rustbot ready |
|
I don't think that's a better solution since if there's a problem reading the entry (e.g. if But that is an interesting point - any idea why (If you can't run locally then to get a more useful output message in CI, you could keep the current version but push the name to a vec if it fails to parse. Then after the loop, print the whole vec and fail if any entries don't match |
d5d20bf to
91d8c56
Compare
|
Found the issue
Went back to the original (If you'd rather keep the @rustbot ready |
Yes please - we'll probably want it at some other point anyway :) Sorry this has had so much back and forth |
Add a run-make test that checks the `.o` members in the prebuilt `libcompiler_builtins` archive for `wasm32-wasip1` are wasm objects. This guards against building wasm compiler-rt fallbacks with the host C toolchain.
91d8c56 to
e101c8d
Compare
|
The run-make-support library was changed cc @jieyouxu |
|
Thanks for the patience (: ! Enabled the @rustbot ready |
|
@bors try jobs=test-various |
This comment has been minimized.
This comment has been minimized.
…ect-arch, r=<try> tests: check wasm compiler_builtins object architecture try-job: test-various
…uiltins-object-arch, r=tgross35 tests: check wasm compiler_builtins object architecture See rust-lang#132802 This adds a run-make test for the wasm sysroot regression fixed in rust-lang#137457 The test checks that the `.o` members in the prebuilt `libcompiler_builtins` rlib for `wasm32-wasip1` are wasm objects rather than host ELF objects. Before that fix, bootstrap could use the host C compiler for compiler-rt fallbacks on wasm targets and end up embedding host objects into the wasm sysroot. I used `wasm32-wasip1` because that's the wasm target covered by the existing `tests/run-make` CI setup, and the test asserts that it actually saw `.o` members in the archive. Closes: rust-lang#132802 r? @tgross35
…uiltins-object-arch, r=tgross35 tests: check wasm compiler_builtins object architecture See rust-lang#132802 This adds a run-make test for the wasm sysroot regression fixed in rust-lang#137457 The test checks that the `.o` members in the prebuilt `libcompiler_builtins` rlib for `wasm32-wasip1` are wasm objects rather than host ELF objects. Before that fix, bootstrap could use the host C compiler for compiler-rt fallbacks on wasm targets and end up embedding host objects into the wasm sysroot. I used `wasm32-wasip1` because that's the wasm target covered by the existing `tests/run-make` CI setup, and the test asserts that it actually saw `.o` members in the archive. Closes: rust-lang#132802 r? @tgross35
…uwer Rollup of 16 pull requests Successful merges: - #155722 (Introduce aarch64-unknown-linux-pauthtest target) - #156230 (tests: check wasm compiler_builtins object architecture) - #158073 (bootstrap: fix panic when repo path contains spaces by switching to CARGO_ENCODED_RUSTFLAGS) - #158169 (Fix debuginfo compression in bootstrap) - #158256 (Avoid parser panics bubbling out to proc macros) - #158375 (Support `DefKind::InlineConst` in `ConstKind::Unevaluated`) - #158556 (delegation: store child segment flag in `PathSegment`) - #158561 (Avoid building rustdoc for tests without doctests) - #158562 (Improve tracing of steps in bootstrap) - #157445 (Allow section override when using patchable-function-entries) - #158081 (trait-system: Recover deferred closure calls after errors) - #158327 (Move attribute and keyword docs from `std` to `core`) - #158468 (Include default-stability info in rustdoc JSON.) - #158564 (fix `-Z min-recursion-limit` unstable chapter name) - #158568 (llvm-wrapper: use accessors for private fields in LLVM 23+) - #158582 (Comment on needed RAM in huge-stacks.rs)
…uwer Rollup of 16 pull requests Successful merges: - #155722 (Introduce aarch64-unknown-linux-pauthtest target) - #156230 (tests: check wasm compiler_builtins object architecture) - #158073 (bootstrap: fix panic when repo path contains spaces by switching to CARGO_ENCODED_RUSTFLAGS) - #158169 (Fix debuginfo compression in bootstrap) - #158256 (Avoid parser panics bubbling out to proc macros) - #158375 (Support `DefKind::InlineConst` in `ConstKind::Unevaluated`) - #158556 (delegation: store child segment flag in `PathSegment`) - #158561 (Avoid building rustdoc for tests without doctests) - #158562 (Improve tracing of steps in bootstrap) - #157445 (Allow section override when using patchable-function-entries) - #158081 (trait-system: Recover deferred closure calls after errors) - #158327 (Move attribute and keyword docs from `std` to `core`) - #158468 (Include default-stability info in rustdoc JSON.) - #158564 (fix `-Z min-recursion-limit` unstable chapter name) - #158568 (llvm-wrapper: use accessors for private fields in LLVM 23+) - #158582 (Comment on needed RAM in huge-stacks.rs)
…uwer Rollup of 11 pull requests Successful merges: - #155722 (Introduce aarch64-unknown-linux-pauthtest target) - #156230 (tests: check wasm compiler_builtins object architecture) - #156295 (Pass the whole `GenericArgs` to `Interner::for_each_relevant_impl()`) - #158375 (Support `DefKind::InlineConst` in `ConstKind::Unevaluated`) - #158556 (delegation: store child segment flag in `PathSegment`) - #158081 (trait-system: Recover deferred closure calls after errors) - #158468 (Include default-stability info in rustdoc JSON.) - #158543 (Note usage of documentation hard links in `core::io`) - #158564 (fix `-Z min-recursion-limit` unstable chapter name) - #158568 (llvm-wrapper: use accessors for private fields in LLVM 23+) - #158582 (Comment on needed RAM in huge-stacks.rs)
…uwer Rollup of 11 pull requests Successful merges: - #155722 (Introduce aarch64-unknown-linux-pauthtest target) - #156230 (tests: check wasm compiler_builtins object architecture) - #156295 (Pass the whole `GenericArgs` to `Interner::for_each_relevant_impl()`) - #158375 (Support `DefKind::InlineConst` in `ConstKind::Unevaluated`) - #158556 (delegation: store child segment flag in `PathSegment`) - #158081 (trait-system: Recover deferred closure calls after errors) - #158468 (Include default-stability info in rustdoc JSON.) - #158543 (Note usage of documentation hard links in `core::io`) - #158564 (fix `-Z min-recursion-limit` unstable chapter name) - #158568 (llvm-wrapper: use accessors for private fields in LLVM 23+) - #158582 (Comment on needed RAM in huge-stacks.rs)
…uwer Rollup of 11 pull requests Successful merges: - #155722 (Introduce aarch64-unknown-linux-pauthtest target) - #156230 (tests: check wasm compiler_builtins object architecture) - #156295 (Pass the whole `GenericArgs` to `Interner::for_each_relevant_impl()`) - #158375 (Support `DefKind::InlineConst` in `ConstKind::Unevaluated`) - #158556 (delegation: store child segment flag in `PathSegment`) - #158081 (trait-system: Recover deferred closure calls after errors) - #158468 (Include default-stability info in rustdoc JSON.) - #158543 (Note usage of documentation hard links in `core::io`) - #158564 (fix `-Z min-recursion-limit` unstable chapter name) - #158568 (llvm-wrapper: use accessors for private fields in LLVM 23+) - #158582 (Comment on needed RAM in huge-stacks.rs)
Rollup merge of #156230 - Vastargazing:tests/wasm-compiler-builtins-object-arch, r=tgross35 tests: check wasm compiler_builtins object architecture See #132802 This adds a run-make test for the wasm sysroot regression fixed in #137457 The test checks that the `.o` members in the prebuilt `libcompiler_builtins` rlib for `wasm32-wasip1` are wasm objects rather than host ELF objects. Before that fix, bootstrap could use the host C compiler for compiler-rt fallbacks on wasm targets and end up embedding host objects into the wasm sysroot. I used `wasm32-wasip1` because that's the wasm target covered by the existing `tests/run-make` CI setup, and the test asserts that it actually saw `.o` members in the archive. Closes: #132802 r? @tgross35
View all comments
See #132802
This adds a run-make test for the wasm sysroot regression fixed in #137457
The test checks that the
.omembers in the prebuiltlibcompiler_builtinsrlib forwasm32-wasip1are wasm objects rather thanhost ELF objects. Before that fix, bootstrap could use the host C compiler for
compiler-rt fallbacks on wasm targets and end up embedding host objects into
the wasm sysroot.
I used
wasm32-wasip1because that's the wasm target covered by the existingtests/run-makeCI setup, and the test asserts that it actually saw.omembers in the archive.
Closes: #132802
r? @tgross35