Commit graph

158136 commits

Author SHA1 Message Date
Yoh Deadfall
498ea324e3 Illumos: Added epoll and eventfd 2025-01-13 22:04:47 +03:00
Yoh Deadfall
b7b6dee26d Added Android to epoll and eventfd test targets 2025-01-12 22:16:43 +03:00
Ralf Jung
8db1e9a2ed
Merge pull request #4135 from RalfJung/unsup-targets
Add FreeBSD maintainer; test all of Solarish
2025-01-12 16:12:36 +00:00
Ralf Jung
f4e05845a7 turns out Solarish targets support our entire test suite 2025-01-12 16:47:55 +01:00
Ralf Jung
be36fbb720 remove a rustfmt::skip 2025-01-12 16:41:51 +01:00
Ralf Jung
30708e1eab record YohDeadfall as FreeBSD maintainer 2025-01-12 16:38:31 +01:00
Oli Scherer
78fdd59343
Merge pull request #4134 from RalfJung/miri-script-ra
adjust the way we build miri-script in RA, to fix proc-macros
2025-01-11 19:20:01 +00:00
Ralf Jung
4221765728 avoid issues due to MIRI_TEST_TARGET being set from the outside 2025-01-11 19:45:13 +01:00
Ralf Jung
ce5c691114 adjust the way we build miri-script in RA, to fix proc-macros 2025-01-11 19:45:13 +01:00
geetanshjuneja
ac7d9a1a94 Supported fioclex for ioctl on macos 2025-01-11 23:12:52 +05:30
Yoh Deadfall
b0ac8c4039 Switched FreeBSD to pthread_setname_np 2025-01-10 21:51:26 +03:00
Ralf Jung
ba44c88167 fix clippy warning 2025-01-10 15:55:48 +01:00
Ralf Jung
a86d0f3baf disable threading tests on freebsd for now 2025-01-10 15:39:06 +01:00
Ralf Jung
20c7b31356 Preparing for merge from rustc 2025-01-10 15:38:00 +01:00
Ralf Jung
2d180714e1 Merge from rustc 2025-01-08 09:23:40 +01:00
cod10129
67f49010ad add tidy warning for unrecognized directives
This makes tidy warn on the presence of any directives it does not recognize.

There are changes in compiletest because that file used "tidy-alphabet" instead of "tidy-alphabetical".
2025-01-14 20:24:11 -06:00
bors
627513a764 Auto merge of #135281 - onur-ozkan:build-stamps, r=jieyouxu
centralize build stamp logic

This PR brings all the stamp file handling into one place inside `build_stamp` module, which takes care of everything related to build stamps. By doing this, we cut down on duplicated code and types and keep the codebase easier to maintain and more consistent.

Main goals are:

- Make stamp handling stricter so we don't have to pass `Path`s around and manually `join` on arbitrary directories
- Keep all stamp-related logic in one place
- Make it easier to test and debug
- Avoid duplication
- Keep things simple and well-documented

Resolves #134962
2025-01-12 17:28:00 +00:00
bors
7bb9888953 Auto merge of #135402 - matthiaskrgr:rollup-cz7hs13, r=matthiaskrgr
Rollup of 6 pull requests

Successful merges:

 - #129259 (Add inherent versions of MaybeUninit methods for slices)
 - #135374 (Suggest typo fix when trait path expression is typo'ed)
 - #135377 (Make MIR cleanup for functions with impossible predicates into a real MIR pass)
 - #135378 (Remove a bunch of diagnostic stashing that doesn't do anything)
 - #135397 (compiletest: add erroneous variant to `string_enum`s conversions error)
 - #135398 (add more crash tests)

r? `@ghost`
`@rustbot` modify labels: rollup
2025-01-12 14:43:10 +00:00
bors
c0f6a1ce3f Auto merge of #135262 - mrkajetanp:ci-aarch64-dist-reland, r=Kobzol
ci: Move dist-aarch64-linux to an aarch64 runner

Move the dist-aarch64-linux CI job to an aarch64 runner instead of cross-compiling it from an x86 one. This will make it possible to perform optimisations such as LTO, PGO and BOLT later on.

r? `@Kobzol`

Reland of #133809 now that the higher page sizes are fixed.

try-job: dist-aarch64-linux
try-job: dist-x86_64-linux
try-job: dist-i686-linux
2025-01-12 11:56:04 +00:00
Matthias Krüger
13805491b2
Rollup merge of #135389 - jieyouxu:fix-stage0-rustdoc-rmake, r=onur-ozkan
compiletest: include stage0-sysroot libstd dylib in recipe dylib search path

To fix some of the failures in `COMPILETEST_FORCE_STAGE0=1 ./x test run-make --stage 0`. Specifically,

```
COMPILETEST_FORCE_STAGE0=1 ./x test tests/run-make/rustdoc-default-output/ --stage 0
```

should now pass.

Fixes #135373. (As in, make *some* of the `run-make` tests pass, other `run-make` tests fail for various reasons against stage0, and generally `run-make` tests are not guaranteed to pass at stage 0.)

cc `@lolbinarycat`

r? bootstrap
2025-01-12 09:14:14 +01:00
Matthias Krüger
6fa92eaf03
Rollup merge of #135375 - lolbinarycat:bootstrap-allow-stage0-rustdoc-js, r=jieyouxu
allow rustdoc-js tests to be run at stage0

this mirrors the behavior of rustdoc-js-std tests.

previously this required COMPILETEST_FORCE_STAGE0.
2025-01-12 09:14:13 +01:00
Rémy Rakic
33ce74f308 add error message to string_enum!s string conversions 2025-01-12 08:13:45 +00:00
Rémy Rakic
d19bdf9b48 add test for string_enum 2025-01-12 08:05:50 +00:00
onur-ozkan
2a4bcf597b update doc-comment of BuildStamp::add_stamp
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-01-12 10:15:36 +03:00
onur-ozkan
b03fba7ab4 rename done_stamp to lld_stamp
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-01-12 08:53:22 +03:00
onur-ozkan
b54d65230f rustc-dev-guide: update outdated LLVM stamp filename
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-01-12 08:47:57 +03:00
onur-ozkan
fae26e7ffa add change entry for renamings
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-01-12 08:46:58 +03:00
onur-ozkan
9611d8ea13 avoid magical AsRef<Path> implementation
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-01-12 08:43:51 +03:00
onur-ozkan
dcc001adbb refactor with_stamp as add_stamp for incrementality
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-01-12 08:43:48 +03:00
onur-ozkan
99322a5158 extend sanitizers stamp calculation
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-01-12 08:43:45 +03:00
onur-ozkan
216969b8c2 run git only inside the current directory
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-01-12 08:43:42 +03:00
onur-ozkan
ffd4c5b51c migrate lld build stamp
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-01-12 08:43:40 +03:00
onur-ozkan
bdb7518203 apply minor improvements on build_stamp
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-01-12 08:43:37 +03:00
onur-ozkan
a72068adee migrate program_out_of_date to BuildStamp::is_up_to_date
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-01-12 08:43:32 +03:00
onur-ozkan
9878d63acb add coverage for BuildStamp::with_prefix
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-01-12 08:43:29 +03:00
onur-ozkan
1fa66573cd fix an invalid prefix usage on enzyme
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-01-12 08:43:26 +03:00
onur-ozkan
9e86d76ad9 fix compiler errors
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-01-12 08:43:24 +03:00
onur-ozkan
615131b4d4 migrate generate_smart_stamp_hash
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-01-12 08:43:21 +03:00
onur-ozkan
cacb4fe93a add test coverage for build_stamp implementation
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-01-12 08:43:16 +03:00
onur-ozkan
9e1c9fd654 document build_stamp implementation
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-01-12 08:43:13 +03:00
onur-ozkan
236d5804bf migrate Builder::clear_if_dirty
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-01-12 08:43:11 +03:00
onur-ozkan
9e929754b2 migrate helper stamp functions
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-01-12 08:43:08 +03:00
onur-ozkan
c68c721b50 migrate HashStamp to BuildStamp
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-01-12 08:43:05 +03:00
onur-ozkan
e3de3c767e use BuildStamp instead of std paths and strings
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-01-12 08:43:03 +03:00
onur-ozkan
58306c6a00 implement BuildStamp that is stricter impl for build stamps
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-01-12 08:43:00 +03:00
许杰友 Jieyou Xu (Joe)
1665b80b71 run-make-support: don't use lossy on TARGET_RPATH_DIR 2025-01-12 13:03:22 +08:00
许杰友 Jieyou Xu (Joe)
fec2e3ab1a compiletest: include stage0-sysroot libstd dylib in recipe dylib search path
To fix some of the failures in
`COMPILETEST_FORCE_STAGE0=1 ./x test run-make --stage 0`.
2025-01-12 13:03:22 +08:00
binarycat
af2247ce10 allow rustdoc-js tests to be run at stage0
this mirrors the behavior of rustdoc-js-std tests.

previously this required COMPILETEST_FORCE_STAGE0.
2025-01-11 14:00:16 -06:00
Matthias Krüger
0bb0f0412f
Rollup merge of #135205 - lqd:bitsets, r=Mark-Simulacrum
Rename `BitSet` to `DenseBitSet`

r? `@Mark-Simulacrum` as you requested this in https://github.com/rust-lang/rust/pull/134438#discussion_r1890659739 after such a confusion.

This PR renames `BitSet` to `DenseBitSet` to make it less obvious as the go-to solution for bitmap needs, as well as make its representation (and positives/negatives) clearer. It also expands the comments there to hopefully make it clearer when it's not a good fit, with some alternative bitsets types.

(This migrates the subtrees cg_gcc and clippy to use the new name in separate commits, for easier review by their respective owners, but they can obvs be squashed)
2025-01-11 18:13:47 +01:00
Matthias Krüger
b8e230a824
Rollup merge of #134030 - folkertdev:min-fn-align, r=workingjubilee
add `-Zmin-function-alignment`

tracking issue: https://github.com/rust-lang/rust/issues/82232

This PR adds the `-Zmin-function-alignment=<align>` flag, that specifies a minimum alignment for all* functions.

### Motivation

This feature is requested by RfL [here](https://github.com/rust-lang/rust/issues/128830):

> i.e. the equivalents of `-fmin-function-alignment` ([GCC](https://gcc.gnu.org/onlinedocs/gcc/Optimize-Options.html#index-fmin-function-alignment_003dn), Clang does not support it) / `-falign-functions` ([GCC](https://gcc.gnu.org/onlinedocs/gcc/Optimize-Options.html#index-falign-functions), [Clang](https://clang.llvm.org/docs/ClangCommandLineReference.html#cmdoption-clang1-falign-functions)).
>
> For the Linux kernel, the behavior wanted is that of GCC's `-fmin-function-alignment` and Clang's `-falign-functions`, i.e. align all functions, including cold functions.
>
> There is [`feature(fn_align)`](https://github.com/rust-lang/rust/issues/82232), but we need to do it globally.

### Behavior

The `fn_align` feature does not have an RFC. It was decided at the time that it would not be necessary, but maybe we feel differently about that now? In any case, here are the semantics of this flag:

- `-Zmin-function-alignment=<align>` specifies the minimum alignment of all* functions
- the `#[repr(align(<align>))]` attribute can be used to override the function alignment on a per-function basis: when `-Zmin-function-alignment` is specified, the attribute's value is only used when it is higher than the value passed to `-Zmin-function-alignment`.
- the target may decide to use a higher value (e.g. on x86_64 the minimum that LLVM generates is 16)
- The highest supported alignment in rust is `2^29`: I checked a bunch of targets, and they all emit the `.p2align        29` directive for targets that align functions at all (some GPU stuff does not have function alignment).

*: Only with `build-std` would the minimum alignment also be applied to `std` functions.

---

cc `@ojeda`

r? `@workingjubilee` you were active on the tracking issue
2025-01-11 18:13:45 +01:00