1
Fork 0
Commit graph

4796 commits

Author SHA1 Message Date
bjorn3
cb4a25ca81 Remove liballoc compiler-builtins f16/f128 disable patch
We already build with the compiler-builtins-no-f16-f128 feature enabled.
2025-03-18 14:49:15 +00:00
bjorn3
1adce908c6 Run alloctests tests too 2025-03-18 09:52:12 +00:00
bjorn3
ebef14a7b6 Reuse the Cargo.lock of the library workspace for coretests 2025-03-18 09:46:49 +00:00
bjorn3
93a9102a06 Rustup to rustc 1.87.0-nightly (43a2e9d2c 2025-03-17) 2025-03-18 09:01:19 +00:00
bjorn3
e69d216ab9 Sync from rust 43a2e9d2c7 2025-03-18 08:53:49 +00:00
bjorn3
92e5c1a44d
Merge pull request #1564 from rust-lang/fix_arm64_asm_vector_regs
Fix usage of vector registers in inline asm on arm64
2025-03-16 18:01:11 +01:00
bjorn3
5bb37b7580 Fix usage of vector registers in inline asm on arm64 2025-03-16 14:55:32 +00:00
许杰友 Jieyou Xu (Joe)
a2797e514b Rollup merge of #138082 - thaliaarchi:slice-cfg-not-test, r=thomcc
Remove `#[cfg(not(test))]` gates in `core`

These gates are unnecessary now that unit tests for `core` are in a separate package, `coretests`, instead of in the same files as the source code. They previously prevented the two `core` versions from conflicting with each other.
2025-03-16 09:40:05 +08:00
Ralf Jung
025eecc3e7 atomic intrinsics: clarify which types are supported and (if applicable) what happens with provenance 2025-03-13 08:14:34 +01:00
bjorn3
eea0db2590 Fix rustc test suite 2025-03-12 13:18:52 +00:00
bjorn3
d2b328e6b3 Reduce verbosity of ./scripts/rustup.sh pull 2025-03-12 13:08:50 +00:00
bjorn3
4ca551cf41 Rustup to rustc 1.87.0-nightly (665025243 2025-03-11) 2025-03-12 13:08:42 +00:00
bjorn3
11565c3471 Sync from rust 6650252439 2025-03-12 13:02:12 +00:00
Ralf Jung
56715d9864 intrinsics: remove unnecessary leading underscore from argument names 2025-03-12 08:04:09 +01:00
bors
43a25a5ec6 Auto merge of #128440 - oli-obk:defines, r=lcnr
Add `#[define_opaques]` attribute and require it for all type-alias-impl-trait sites that register a hidden type

Instead of relying on the signature of items to decide whether they are constraining an opaque type, the opaque types that the item constrains must be explicitly listed.

A previous version of this PR used an actual attribute, but had to keep the resolved `DefId`s in a side table.

Now we just lower to fields in the AST that have no surface syntax, instead a builtin attribute macro fills in those fields where applicable.

Note that for convenience referencing opaque types in associated types from associated methods on the same impl will not require an attribute. If that causes problems `#[defines()]` can be used to overwrite the default of searching for opaques in the signature.

One wart of this design is that closures and static items do not have generics. So since I stored the opaques in the generics of functions, consts and methods, I would need to add a custom field to closures and statics to track this information. During a T-types discussion we decided to just not do this for now.

fixes #131298
2025-03-11 18:13:31 +00:00
bors
5a44fffc33 Auto merge of #137586 - nnethercote:SetImpliedBits, r=bjorn3
Speed up target feature computation

The LLVM backend calls `LLVMRustHasFeature` twice for every feature. In short-running rustc invocations, this accounts for a surprising amount of work.

r? `@bjorn3`
2025-03-11 12:05:16 +00:00
Oli Scherer
d9de94001a Implement #[define_opaque] attribute for functions. 2025-03-11 12:05:02 +00:00
bjorn3
540565e5b9 Fully test the alloc crate through alloctests
For the tests that make use of internal implementation details, we
include the module to test using #[path] in alloctests now.
2025-03-07 19:11:13 +00:00
Thalia Archibald
fd3fb2cf46 Remove #[cfg(not(test))] gates in core
These gates are unnecessary now that unit tests for `core` are in a
separate package, `coretests`, instead of in the same files as the
source code. They previously prevented the two `core` versions from
conflicting with each other.
2025-03-06 13:21:59 -08:00
bjorn3
4b7bcdbf9f Use the github cli to publish dev releases
This removes a whole bunch of complicated javascript with two lines of
bash.

Fixes rust-lang/rustc_codegen_cranelift#1562
2025-03-06 14:43:29 +00:00
bjorn3
aa31d42b39 Remove no longer necessary disabling of dylib usage for run-make tests
Run-make tests are now fully compiled using the bootstrap compiler.
2025-03-06 12:51:22 +00:00
bjorn3
75109ec1ba FIx rustc test suite 2025-03-06 12:46:54 +00:00
bjorn3
f048c45018 Rustup to rustc 1.87.0-nightly (30f168ef8 2025-03-05) 2025-03-06 12:40:11 +00:00
bjorn3
41b355ac4b Sync from rust 30f168ef81 2025-03-06 12:16:04 +00:00
bjorn3
7eb0a99fc9 Fix jit mode testing 2025-03-05 15:55:41 +00:00
bjorn3
5cdb866356 Update rust-analyzer config
mod_bench no longer exists and there is no benefit to not having a
sysroot available for mini_core and mini_core_hello_world.
2025-03-05 15:51:35 +00:00
bjorn3
5d03df9431 Remove support for the lazy jit mode
I might re-implement it in the future, but would probably do so by
replacing cranelift-jit. cranelift-jit's api doesn't quite work well for
lazy jitting. And even so it adds complexity to cranelift-jit and breaks
cranelift-jit outside of x86_64.
2025-03-05 15:37:10 +00:00
bjorn3
0fcd068bec Refactor the cli of cg_clif 2025-03-05 15:12:57 +00:00
Trevor Gross
75485a2c09 Update compiler-builtins to 0.1.151
This enables `f16` builtins for loongarch [1] and adds support for
Cygwin [2].

[1]: https://github.com/rust-lang/compiler-builtins/pull/770
[2]: https://github.com/rust-lang/compiler-builtins/pull/774
2025-03-05 01:35:02 -05:00
Jubilee
ca89d80764 Rollup merge of #137634 - tgross35:update-builtins, r=tgross35
Update `compiler-builtins` to 0.1.149

Includes a change to make a subset of math symbols available on all platforms [1], and disables `f16` on aarch64 without neon [2].

[1]: https://github.com/rust-lang/compiler-builtins/pull/763
[2]: https://github.com/rust-lang/compiler-builtins/pull/775

try-job: aarch64-gnu
try-job: aarch64-gnu-debug
try-job: armhf-gnu
try-job: dist-various-1
try-job: dist-various-2
try-job: dist-aarch64-linux
try-job: dist-arm-linux
try-job: dist-armv7-linux
try-job: dist-x86_64-linux
try-job: test-various
2025-03-04 14:50:40 -08:00
Nicholas Nethercote
157137a64a Change signature of target_features_cfg.
Currently it is called twice, once with `allow_unstable` set to true and
once with it set to false. This results in some duplicated work. Most
notably, for the LLVM backend, `LLVMRustHasFeature` is called twice for
every feature, and it's moderately slow. For very short running
compilations on platforms with many features (e.g. a `check` build of
hello-world on x86) this is a significant fraction of runtime.

This commit changes `target_features_cfg` so it is only called once, and
it now returns a pair of feature sets. This halves the number of
`LLVMRustHasFeature` calls.
2025-03-05 09:49:17 +11:00
bjorn3
0f9c09fb3a Remoe has_ptr_meta in favor of tcx.type_has_metadata() 2025-03-03 12:43:05 +00:00
bjorn3
57767d6d99 Rustup to rustc 1.87.0-nightly (f4a216d28 2025-03-02) 2025-03-03 12:35:10 +00:00
bjorn3
a797db4883 Sync from rust f4a216d28e 2025-03-03 12:30:27 +00:00
Trevor Gross
5328983b07 Update compiler-builtins to 0.1.150
Includes a change to make a subset of math symbols available on all
platforms [1], and disables `f16` on aarch64 without neon [2].

[1]: https://github.com/rust-lang/compiler-builtins/pull/763
[2]: https://github.com/rust-lang/compiler-builtins/pull/775
2025-03-01 20:02:51 +00:00
Matthias Krüger
ee5bae8a12 Rollup merge of #137804 - RalfJung:backend-repr-simd-vector, r=workingjubilee
rename BackendRepr::Vector → SimdVector

For many Rustaceans, "vector" does not imply "SIMD", so let's be more clear in this type that is used pervasively in the compiler.

r? `@workingjubilee`
2025-03-01 16:03:10 +01:00
bors
f56e516575 Auto merge of #133250 - DianQK:embed-bitcode-pgo, r=nikic
The embedded bitcode should always be prepared for LTO/ThinLTO

Fixes #115344. Fixes #117220.

There are currently two methods for generating bitcode that used for LTO. One method involves using `-C linker-plugin-lto` to emit object files as bitcode, which is the typical setting used by cargo. The other method is through `-C embed-bitcode=yes`.

When using with `-C embed-bitcode=yes -C lto=no`, we run a complete non-LTO LLVM pipeline to obtain bitcode, then the bitcode is used for LTO. We run the Call Graph Profile Pass twice on the same module.

This PR is doing something similar to LLVM's `buildFatLTODefaultPipeline`, obtaining the bitcode for embedding after running `buildThinLTOPreLinkDefaultPipeline`.

r? nikic
2025-03-01 08:22:18 +00:00
Ralf Jung
b9ca52582b rename BackendRepr::Vector → SimdVector 2025-02-28 17:17:45 +01:00
bjorn3
30ece8da06 Make tiny-skia work on arm64 2025-02-26 13:06:01 +00:00
bjorn3
d27c67c941 Fix FIXME about unversioned macOS target names 2025-02-26 11:24:41 +00:00
bjorn3
994c8cfaf6 Skip downloading test crates in CI jobs that don't need them 2025-02-26 11:11:44 +00:00
bjorn3
e173b714aa You don't need y.sh prepare to build, only to test
Also improve the error message when trying to test without having run
y.sh prepare first.
2025-02-26 11:06:15 +00:00
bjorn3
4698eb6276 Rustup to rustc 1.87.0-nightly (85abb2763 2025-02-25) 2025-02-26 10:52:47 +00:00
bjorn3
7874766497 Sync from rust 85abb27636 2025-02-26 10:47:43 +00:00
bjorn3
2695a19fb0 Use native x86_64 runners for macOS abi-cafe tests too 2025-02-26 10:35:27 +00:00
bjorn3
bdcd07466b Use native x86_64 macOS runners for x86_64 builds
Rather than running in Rosetta 2. This should make testing on CI faster.
2025-02-26 10:10:43 +00:00
bjorn3
a26a938dac
Merge pull request #1557 from rust-lang/arm64_linux_ci
Test and dist for arm64 linux on CI
2025-02-26 11:08:04 +01:00
bjorn3
439062052e Test and dist for arm64 linux on CI 2025-02-26 09:32:53 +00:00
bjorn3
94ac6e557f Update to Cranelift 0.117 2025-02-26 09:14:43 +00:00
bors
309d6b0375 Auto merge of #137608 - fmease:rollup-h4siso6, r=fmease
Rollup of 8 pull requests

Successful merges:

 - #137370 (adjust_abi: make fallback logic for ABIs a bit easier to read)
 - #137444 (Improve behavior of `IF_LET_RESCOPE` around temporaries and place expressions)
 - #137464 (Fix invalid suggestion from type error for derive macro)
 - #137539 ( Add rustdoc-gui regression test for #137082 )
 - #137576 (Don't doc-comment BTreeMap<K, SetValZST, A>)
 - #137595 (remove `simd_fpow` and `simd_fpowi`)
 - #137600 (type_ir: remove redundant part of comment)
 - #137602 (feature: fix typo in attribute description)

r? `@ghost`
`@rustbot` modify labels: rollup
2025-02-25 19:36:17 +00:00