Commit graph

122 commits

Author SHA1 Message Date
bors 1aa6c7cbc6 Auto merge of #80182 - in42:stack_trace, r=tmandry
Implement printing of stack traces on LLVM segfaults and aborts

Implement #79153

Based on discussion, try to extend the rust_backtrace=1 feature to handle segfault or aborts in the llvm backend
2021-07-02 05:40:51 +00:00
Tyler Mandry 162ed4d7da Use signal handler only on supported platforms 2021-07-02 01:23:25 +00:00
bors 1034282bca Auto merge of #86617 - joshtriplett:prune-dependencies, r=Mark-Simulacrum
Remove unused dependencies from compiler crates

Various compiler crates have dependencies that they don't appear to use. I used some scripting to detect such dependencies, filtered them based on some manual review, and removed those that do indeed appear to be entirely unused.
2021-07-01 03:49:47 +00:00
bors 866335b337 Auto merge of #86757 - JohnTitor:rollup-acevhz7, r=JohnTitor
Rollup of 8 pull requests

Successful merges:

 - #85504 (the foundation owns rust trademarks)
 - #85520 (Fix typo and improve documentation for E0632)
 - #86680 (Improve error for missing -Z with debugging option)
 - #86728 (Check node kind to avoid ICE in `check_expr_return()`)
 - #86740 (copy rust-lld as ld in dist)
 - #86746 (Fix rustdoc query type filter)
 - #86750 (Test cross-crate usage of `feature(const_trait_impl)`)
 - #86755 (alloc: `RawVec<T, A>::shrink` can be in `no_global_oom_handling`.)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
2021-07-01 01:08:46 +00:00
Yuki Okushi 56ddef8ab8
Rollup merge of #86680 - camsteffen:dbg-opt-error, r=petrochenkov
Improve error for missing -Z with debugging option

Before:
```text
❯ rustc --unpretty=hir
error: Unrecognized option: 'unpretty'
```
After:
```text
❯ rustc --unpretty=hir
error: Unrecognized option: 'unpretty'. Did you mean `-Z unpretty`?
```
2021-07-01 05:20:57 +09:00
Camille GILLOT aa1bc5874e Fix AST pretty. 2021-06-30 20:53:10 +02:00
Camille GILLOT 2f28737ebe Move AST crate. 2021-06-30 20:53:10 +02:00
Cameron Steffen 2a60f090b9 Add suggestion for missing compile flag group 2021-06-30 13:28:15 -05:00
Fabian Wolff a8b57723d4 Use Option::map() instead of if let 2021-06-26 22:26:26 +02:00
Fabian Wolff 7682e87c6d Fix ICE with -Zunpretty=hir,typed when an expression occurs in a function signature 2021-06-26 16:05:53 +02:00
Josh Triplett 8f7839f722 rustc_driver: Remove unused dependencies rustc_mir_build and rustc_typeck
Unused since commit dc3eabd487
("Store THIR in `IndexVec`s instead of an `Arena`").
2021-06-25 01:12:59 -07:00
bors 50a9081216 Auto merge of #85640 - bjorn3:custom_ice_hook, r=jackh726
Allow changing the bug report url for the ice hook

cc https://github.com/bjorn3/rustc_codegen_cranelift/issues/1174
2021-06-25 04:06:32 +00:00
Aris Merchant 0bb6bc40ce Teach rustc to accept lowercase error codes 2021-06-22 22:56:38 -07:00
Tyler Mandry ec6a85a536 Small fixes 2021-06-16 01:44:18 +00:00
Vikram Pal 2325966003 Implement printing of stack traces on LLVM segfaults and aborts 2021-06-16 01:43:20 +00:00
bjorn3 7d5c79497c Rustfmt 2021-06-04 13:20:05 +02:00
bjorn3 c1b66379dd Support --version and -Cpasses=list for other codegen backends 2021-06-04 13:20:04 +02:00
bjorn3 1870f9b05f Allow printing the version of the default codegen backend if it isn't llvm 2021-06-04 13:20:04 +02:00
bjorn3 a702729aac Turn a regular comment on Compilation into a doc comment 2021-06-04 13:20:04 +02:00
bjorn3 048fe539e4 Don't invoke the default panic hook from report_ice 2021-05-24 18:47:16 +02:00
bors f94942d842 Auto merge of #83842 - LeSeulArtichaut:thir-vec, r=nikomatsakis
Store THIR in `IndexVec`s instead of an `Arena`

This is a necessary step to store the THIR in a query: #85273. See [relevant discussion on Zulip](https://rust-lang.zulipchat.com/#narrow/stream/278509-project-thir-unsafeck/topic/THIR-dependent.20queries.20design).

r? `@ghost` cc `@cjgillot` `@nikomatsakis`
2021-05-19 18:41:23 +00:00
LeSeulArtichaut dc3eabd487 Store THIR in IndexVecs instead of an Arena 2021-05-19 16:03:35 +02:00
Camille GILLOT 1fb9cad50a Use () for analysis. 2021-05-12 14:01:16 +02:00
bors ac923d94f8 Auto merge of #83610 - bjorn3:driver_cleanup, r=cjgillot
rustc_driver cleanup

Best reviewed one commit at a time.
2021-05-12 08:38:03 +00:00
bjorn3 163b4801e7 Run save_analysis even when analysis returned an error 2021-05-03 13:44:13 +02:00
bjorn3 b71cd56e48 Move queries.crate_name() 2021-05-02 18:12:48 +02:00
bjorn3 b25292473a Simplify make_input 2021-05-02 18:12:48 +02:00
bjorn3 673c1b6e49 Remove unnecessary argument 2021-05-02 18:00:20 +02:00
bjorn3 c752ee53ae Tiny cleanup 2021-05-02 18:00:20 +02:00
bjorn3 2acdc87700 Inline process_rlink into try_process_rlink 2021-05-02 18:00:20 +02:00
bjorn3 2fa7175293 Document a few things 2021-05-02 18:00:20 +02:00
bjorn3 b5e049de08 Remove dummy_config 2021-05-02 17:59:48 +02:00
Dylan DPC e00893b715
Rollup merge of #83895 - eggyal:issue-83883, r=jyn514
Add listing of lints (eg via `-W help`) to rustdoc

Fixes #83883

r? `@jyn514`
2021-04-06 17:42:31 +02:00
Alan Egerton 4d23c8e9a1
Add listing of lints (eg via -W help) to rustdoc 2021-04-06 09:54:56 +01:00
bors 354cc751b7 Auto merge of #81641 - bjorn3:find_codegen_backend, r=davidtwco
Find codegen backends in more locations

* Search in the sysroot passed using `--sysroot` in addition to the default sysroot.
* Search for `librustc_codegen_$name.so` in addition to `librustc_codegen_$name-$release.so`.

This combined would allow putting `librustc_codegen_cranelift.so` in the right location of a sysroot passed using `--sysroot`.
2021-04-06 07:16:19 +00:00
bjorn3 cab940e848 Merge two consecutive tcx.analysis() calls 2021-03-30 09:19:46 +02:00
Joshua Nelson de0fda9558 Address review comments
- Add back `HirIdVec`, with a comment that it will soon be used.
- Add back `*_region` functions, with a comment they may soon be used.
- Remove `-Z borrowck_stats` completely. It didn't do anything.
- Remove `make_nop` completely.
- Add back `current_loc`, which is used by an out-of-tree tool.
- Fix style nits
- Remove `AtomicCell` with `cfg(parallel_compiler)` for consistency.
2021-03-27 22:16:34 -04:00
Joshua Nelson 441dc3640a Remove (lots of) dead code
Found with https://github.com/est31/warnalyzer.

Dubious changes:
- Is anyone else using rustc_apfloat? I feel weird completely deleting
  x87 support.
- Maybe some of the dead code in rustc_data_structures, in case someone
  wants to use it in the future?
- Don't change rustc_serialize

  I plan to scrap most of the json module in the near future (see
  https://github.com/rust-lang/compiler-team/issues/418) and fixing the
  tests needed more work than I expected.

TODO: check if any of the comments on the deleted code should be kept.
2021-03-27 22:16:33 -04:00
bors 2e012ce681 Auto merge of #83050 - osa1:issue83048, r=matthewjasper
Run analyses before thir-tree dumps

Fixes #83048
2021-03-24 12:02:13 +00:00
Eric Huss 45583e56c0 Change -W help to display edition level. 2021-03-22 12:57:52 -07:00
hyd-dev d7ab3c77b3
Add rustc_interface::interface::Config::parse_sess_created 2021-03-15 18:24:58 +08:00
Ömer Sinan Ağacan b24902ea18 Run analyses before thir-tree dumps
Fixes #83048
2021-03-12 10:08:44 +03:00
LeSeulArtichaut 6bf4147646 Add -Z unpretty flag for the THIR 2021-03-11 19:42:40 +01:00
Oli Scherer 62f2d72330 Bump tracing-tree dependency 2021-03-09 16:44:51 +00:00
bors 7f32f62aa5 Auto merge of #82304 - LeSeulArtichaut:unpretty-ast, r=spastorino
Add `-Z unpretty` flags for the AST

Implements rust-lang/compiler-team#408.
Builds on #82269, but if that PR is rejected or stalls out, I can implement this without #82269.
cc rust-lang/rustc-dev-guide#1062
2021-03-04 05:46:43 +00:00
LeSeulArtichaut 61114453ae Add -Z unpretty flags for the AST 2021-03-03 15:11:26 +01:00
Tomasz Miąsko 2abe7c8f9c Update tracing to 0.1.25 2021-02-28 11:24:24 +01:00
Aaron Hill 8c0119da77
Rollup merge of #82269 - LeSeulArtichaut:cleanup-ppmode, r=spastorino
Cleanup `PpMode` and friends

This PR:
 - Separates `PpSourceMode` and `PpHirMode` to remove invalid states
 - Renames the variant to remove the redundant `Ppm` prefix
 - Adds basic documentation for the different pretty-print modes
 - Cleanups some code to make it more idiomatic

Not sure if this is actually useful, but it looks cleaner to me.
2021-02-25 16:06:16 -05:00
bors d2b38d6b3c Auto merge of #82341 - GuillaumeGomez:rollup-t7y7tyg, r=GuillaumeGomez
Rollup of 7 pull requests

Successful merges:

 - #80595 (`impl PartialEq<Punct> for char`; symmetry for #78636)
 - #81991 (Fix panic in 'remove semicolon' when types are not local)
 - #82176 (fix MIR fn-ptr pretty-printing)
 - #82244 (Keep consistency in example for Stdin StdinLock)
 - #82260 (rustc: Show ``@path`` usage in stable)
 - #82316 (Fix minor mistake in LTO docs.)
 - #82332 (Don't generate src link on dummy spans)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
2021-02-20 21:38:53 +00:00
Guillaume Gomez 8c095619cb
Rollup merge of #82260 - ojeda:rustc-argfile, r=jyn514
rustc: Show `@path` usage in stable

The feature was stabilized in #66172, but the usage string was not updated to be shown.
2021-02-20 20:37:02 +01:00