Commit Graph

1432 Commits

Author SHA1 Message Date
antoyo
e69f125758
Merge pull request #438 from GuillaumeGomez/master-feature-default
Put back `master` feature as default
2024-02-15 09:00:03 -05:00
Guillaume Gomez
98c1efd5b6 Put back master feature as default 2024-02-15 12:30:43 +01:00
David Wood
ec5328b3d9 errors: only eagerly translate subdiagnostics
Subdiagnostics don't need to be lazily translated, they can always be
eagerly translated. Eager translation is slightly more complex as we need
to have a `DiagCtxt` available to perform the translation, which involves
slightly more threading of that context.

This slight increase in complexity should enable later simplifications -
like passing `DiagCtxt` into `AddToDiagnostic` and moving Fluent messages
into the diagnostic structs rather than having them in separate files
(working on that was what led to this change).

Signed-off-by: David Wood <david@davidtw.co>
2024-02-15 10:34:41 +00:00
antoyo
77b980451d
Merge pull request #437 from rust-lang/dummy-emit-ir
Implement dummy emit=llvm-ir
2024-02-14 12:27:14 -05:00
Antoni Boucher
de57533e56 Implement dummy emit=llvm-ir 2024-02-14 09:38:56 -05:00
antoyo
826a20be1d
Merge pull request #436 from GuillaumeGomez/cleanup-patches
Move `crates_patches` and `cross_patches` into the `patches` folder
2024-02-14 09:31:53 -05:00
Guillaume Gomez
ebac107a55 Remove paths that don't exist anymore from file 2024-02-14 15:11:34 +01:00
Guillaume Gomez
a883c6da20 Move crates_patches and cross_patches into the patches folder 2024-02-14 13:35:20 +01:00
tempdragon
17e329777f feat(test.rs): Lookup the commit with cat-file to avoid re-fetches 2024-02-14 17:59:16 +08:00
tempdragon
452ebf5f37 feat(test.rs): Clone only 1 layer in build_system 2024-02-14 08:12:10 +08:00
antoyo
6afabceaa6
Merge pull request #435 from GuillaumeGomez/clean-up-repo
Generate content into `build` folder
2024-02-13 18:16:24 -05:00
Guillaume Gomez
46d6e772c0 Update tests/lang_tests_common.rs test 2024-02-13 22:11:31 +01:00
Guillaume Gomez
436fea8efb Add build folder into the ignored git entries 2024-02-13 22:11:31 +01:00
Guillaume Gomez
896b1a9049 Generate libgccjit.so into the build folder 2024-02-13 22:11:31 +01:00
Guillaume Gomez
267aaef81d Move some top-level folders into build 2024-02-13 22:11:31 +01:00
antoyo
7faff65296
Merge pull request #434 from rust-lang/fix/platform-specific-function
Rework the download function to only contain the platform-specific code
2024-02-13 11:17:12 -05:00
antoyo
ac708d9485
Merge pull request #430 from GuillaumeGomez/download-config
Add `download` config
2024-02-13 10:49:10 -05:00
Guillaume Gomez
b80a99922b Improve code readability and add more code comments 2024-02-13 15:43:42 +01:00
Guillaume Gomez
1096b1b8db Add more explanation on what cg_gcc_path is used for and improve help message for --cg_gcc-path 2024-02-13 15:43:42 +01:00
Guillaume Gomez
2bcc73540c Don't join config file path if provided through --config-file option 2024-02-13 15:43:42 +01:00
Guillaume Gomez
59546ea2d5 Merge download.yml into ci.yml 2024-02-13 15:43:42 +01:00
Guillaume Gomez
d04ffb0ffc Update lang_tests_common.rs test 2024-02-13 15:43:42 +01:00
Guillaume Gomez
65f4b6354d Add CI for download config 2024-02-13 15:43:42 +01:00
Guillaume Gomez
5c6cdf5ab6 Add info command to help get some information 2024-02-13 15:43:42 +01:00
Guillaume Gomez
0a4b0af141 Generate symbolic link to libgccjit.so as well 2024-02-13 15:43:42 +01:00
Guillaume Gomez
eee04a48d9 Add support for "download" 2024-02-13 15:43:42 +01:00
Antoni Boucher
5d5137cebc Rework the download function to only contain the platform-specific code 2024-02-12 21:20:12 -04:00
Oli Scherer
64dfa4f455 Teach llvm backend how to fall back to default bodies 2024-02-12 17:50:39 +00:00
Guillaume Gomez
588db24344 Correctly handle --use-system-gcc 2024-02-12 14:42:37 +01:00
antoyo
560e65c323
Merge pull request #427 from GuillaumeGomez/config-file
Switch to `config.toml` instead of `gcc-path`
2024-02-11 17:47:56 -05:00
Guillaume Gomez
de9d1b63b4 Add --config-file option to override default location of config.toml 2024-02-11 23:15:50 +01:00
Guillaume Gomez
79241b8a4e Update tests to use config.toml instead 2024-02-11 23:15:50 +01:00
Guillaume Gomez
0b2402fdfc Update CI scripts to work with config.toml 2024-02-11 23:15:50 +01:00
Guillaume Gomez
2640b316e2 Switch to config.toml instead of gcc-path 2024-02-11 21:53:56 +01:00
antoyo
357cae82ad
Merge pull request #426 from rust-lang/ci/projects
Run the tests of popular crates in the CI
2024-02-10 10:07:22 -05:00
Antoni Boucher
6b05753cb3 Run the tests of popular crates in the CI 2024-02-10 09:32:44 -05:00
Matthias Krüger
5a12a89992 Rollup merge of #120693 - nnethercote:invert-diagnostic-lints, r=davidtwco
Invert diagnostic lints.

That is, change `diagnostic_outside_of_impl` and `untranslatable_diagnostic` from `allow` to `deny`, because more than half of the compiler has been converted to use translated diagnostics.

This commit removes more `deny` attributes than it adds `allow` attributes, which proves that this change is warranted.

r? ````@davidtwco````
2024-02-09 14:41:50 +01:00
antoyo
8235b26062
Merge pull request #423 from rust-lang/fix/bswap128
Renable intrinsics-integer.rs test
2024-02-07 17:15:11 -05:00
Matthias Krüger
1f5316a769 Rollup merge of #120502 - clubby789:remove-ffi-returns-twice, r=compiler-errors
Remove `ffi_returns_twice` feature

The [tracking issue](https://github.com/rust-lang/rust/issues/58314) and [RFC](https://github.com/rust-lang/rfcs/pull/2633) have been closed for a couple of years.

There is also an attribute gate in R-A which should be removed if this lands.
2024-02-06 22:45:42 +01:00
Michael Goulet
31f7f03c2a Add CoroutineClosure to TyKind, AggregateKind, UpvarArgs 2024-02-06 02:22:58 +00:00
Nicholas Nethercote
007cea3238 Invert diagnostic lints.
That is, change `diagnostic_outside_of_impl` and
`untranslatable_diagnostic` from `allow` to `deny`, because more than
half of the compiler has be converted to use translated diagnostics.

This commit removes more `deny` attributes than it adds `allow`
attributes, which proves that this change is warranted.
2024-02-06 13:12:33 +11:00
Matthias Krüger
fe7be54b91 Rollup merge of #119543 - usamoi:avx512fp16, r=oli-obk
add avx512fp16 to x86 target features

std_detect avx512fp16: https://github.com/rust-lang/stdarch/pull/1508
2024-02-03 21:29:40 +01:00
Antoni Boucher
0a38748d8a Renable intrinsics-integer.rs test 2024-02-03 13:26:06 -05:00
antoyo
b04824a3b2
Merge pull request #421 from rust-lang/update/gcc
Update for rebased gcc
2024-02-02 12:11:57 -05:00
Antoni Boucher
ad8e820139 Update for rebased gcc 2024-02-02 11:49:32 -05:00
antoyo
2a36f58475
Merge pull request #416 from Liewyec/feature/improve-iterator-for-file-suppression
Improve iterator for files suppression
2024-02-01 09:10:38 -05:00
clubby789
04e4c5ddbc Remove ffi_returns_twice feature 2024-01-30 22:09:09 +00:00
Nicholas Nethercote
b9d44eef7a Remove the lifetime from DiagnosticArgValue.
Because it's almost always static.

This makes `impl IntoDiagnosticArg for DiagnosticArgValue` trivial,
which is nice.

There are a few diagnostics constructed in
`compiler/rustc_mir_build/src/check_unsafety.rs` and
`compiler/rustc_mir_transform/src/errors.rs` that now need symbols
converted to `String` with `to_string` instead of `&str` with `as_str`,
but that' no big deal, and worth it for the simplifications elsewhere.
2024-01-30 18:46:06 +11:00
bors
bb121d111d Auto merge of #116167 - RalfJung:structural-eq, r=lcnr
remove StructuralEq trait

The documentation given for the trait is outdated: *all* function pointers implement `PartialEq` and `Eq` these days. So the `StructuralEq` trait doesn't really seem to have any reason to exist any more.

One side-effect of this PR is that we allow matching on some consts that do not implement `Eq`. However, we already allowed matching on floats and consts containing floats, so this is not new, it is just allowed in more cases now. IMO it makes no sense at all to allow float matching but also sometimes require an `Eq` instance. If we want to require `Eq` we should adjust https://github.com/rust-lang/rust/pull/115893 to check for `Eq`, and rule out float matching for good.

Fixes https://github.com/rust-lang/rust/issues/115881
2024-01-26 00:17:00 +00:00
bors
d645e1638d Auto merge of #119911 - NCGThompson:is-statically-known, r=oli-obk
Replacement of #114390: Add new intrinsic `is_var_statically_known` and optimize pow for powers of two

This adds a new intrinsic `is_val_statically_known` that lowers to [``@llvm.is.constant.*`](https://llvm.org/docs/LangRef.html#llvm-is-constant-intrinsic).` It also applies the intrinsic in the int_pow methods to recognize and optimize the idiom `2isize.pow(x)`. See #114390 for more discussion.

While I have extended the scope of the power of two optimization from #114390, I haven't added any new uses for the intrinsic. That can be done in later pull requests.

Note: When testing or using the library, be sure to use `--stage 1` or higher. Otherwise, the intrinsic will be a noop and the doctests will be skipped. If you are trying out edits, you may be interested in [`--keep-stage 0`](https://rustc-dev-guide.rust-lang.org/building/suggested.html#faster-builds-with---keep-stage).

Fixes #47234
Resolves #114390
`@Centri3`
2024-01-25 05:16:53 +00:00