about summary refs log tree commit diff
path: root/compiler/rustc_codegen_cranelift/src/debuginfo
AgeCommit message (Collapse)AuthorLines
2025-09-28remove explicit deref of AbiAlign for most methodsJubilee Young-5/+3
Much of the compiler calls functions on Align projected from AbiAlign. AbiAlign impls Deref to its inner Align, so we can simplify these away. Also, it will minimize disruption when AbiAlign is removed. For now, preserve usages that might resolve to PartialOrd or PartialEq, as those have odd inference.
2025-05-25Merge commit '979dcf8e2f213e4f4b645cb62e7fe9f4f2c0c785' into ↵bjorn3-10/+49
sync_cg_clif-2025-05-25
2025-04-04Rollup merge of #138949 - madsmtm:rename-to-darwin, r=WaffleLapkinMatthias Krüger-1/+1
Rename `is_like_osx` to `is_like_darwin` Replace `is_like_osx` with `is_like_darwin`, which more closely describes reality (OS X is the pre-2016 name for macOS, and is by now quite outdated; Darwin is the overall name for the OS underlying Apple's macOS, iOS, etc.). ``@rustbot`` label O-apple r? compiler
2025-03-30Merge commit 'ba315abda789c9f59f2100102232bddb30b0d3d3' into ↵bjorn3-2/+2
sync_cg_clif-2025-03-30
2025-03-25Rename `is_like_osx` to `is_like_darwin`Mads Marquart-1/+1
2025-02-15Merge commit '557ed8ebb7e981817d03c87352892c394183dd70' into ↵bjorn3-3/+3
sync_cg_clif-2025-02-15
2025-02-08Rustfmtbjorn3-9/+12
2024-11-23remove remaining references to `Reveal`lcnr-5/+11
2024-11-18use `TypingEnv` when no `infcx` is availablelcnr-3/+5
the behavior of the type system not only depends on the current assumptions, but also the currentnphase of the compiler. This is mostly necessary as we need to decide whether and how to reveal opaque types. We track this via the `TypingMode`.
2024-11-09Merge commit '1fa693ca4462fc1f790693464cf765ad693616af' into ↵bjorn3-1/+1
sync_cg_clif-2024-11-09
2024-11-02Merge commit '5b1246bb4bed72fd0bb8fa497d8e5ed2c7f3515c' into ↵bjorn3-4/+10
sync_cg_clif-2024-11-02
2024-10-26Effects cleanupDeadbeef-1/+0
- removed extra bits from predicates queries that are no longer needed in the new system - removed the need for `non_erasable_generics` to take in tcx and DefId, removed unused arguments in callers
2024-10-04Use wide pointers consistenly across the compilerUrgau-1/+1
2024-09-22Reformat using the new identifier sorting from rustfmtMichael Goulet-19/+16
2024-09-20Do not unnecessarily eval consts in codegenMichael Goulet-1/+1
2024-07-29Reformat `use` declarations.Nicholas Nethercote-1/+2
The previous commit updated `rustfmt.toml` appropriately. This commit is the outcome of running `x fmt --all` with the new formatting options.
2024-07-13Merge commit '659243d85c7489412bd0faa1c068d904a6042941' into ↵bjorn3-1/+7
sync_cg_clif-2024-07-13
2024-04-25debuginfo: Stabilize `-Z debug-macros`, `-Z collapse-macro-debuginfo` and ↵Vadim Petrochenkov-6/+3
`#[collapse_debuginfo]` `-Z debug-macros` is "stabilized" by enabling it by default and removing. `-Z collapse-macro-debuginfo` is stabilized as `-C collapse-macro-debuginfo`. It now supports all typical boolean values (`parse_opt_bool`) in addition to just yes/no. Default value of `collapse_debuginfo` was changed from `false` to `external` (i.e. collapsed if external, not collapsed if local). `#[collapse_debuginfo]` attribute without a value is no longer supported to avoid guessing the default.
2024-04-23Merge commit 'de5d6523738fd44a0521b6abf3e73ae1df210741' into ↵bjorn3-5/+7
sync_cg_clif-2024-04-23
2024-04-11Merge commit '89f54caacf90e99fc8ba0d60a28bdadea3cfdf1e' into ↵bjorn3-0/+8
sync_cg_clif-2024-04-11
2024-03-28Replace Session should_remap_filepaths with filename_display_preferenceUrgau-29/+9
2024-03-28Introduce `FileNameMapping::to_real_filename` and use it everywhereUrgau-12/+8
2024-03-28Make local_crate_source_file return a RealFileNameUrgau-1/+8
so it can be remapped (or not) by callers
2024-03-28Replace `RemapFileNameExt::for_codegen` with explicit callsUrgau-1/+3
2024-03-28Merge commit '09fae60a86b848a2fc0ad219ecc4e438dc1eef86' into ↵bjorn3-96/+478
sync_cg_clif-2024-03-28
2024-01-26Merge commit '3e50cf65025f96854d6597e80449b0d64ad89589' into ↵bjorn3-7/+4
sync_cg_clif-2024-01-26
2024-01-08Improved support of collapse_debuginfo attribute for macros.Andrew Zhogin-9/+1
2023-10-21Merge commit 'c07d1e2f88cb3b1a0604ae8f18b478c1aeb7a7fa' into ↵bjorn3-1/+1
sync_cg_clif-2023-10-21
2023-10-17[RFC 3127 - Trim Paths]: Condition remapped filepath on remap scopesUrgau-4/+28
2023-10-09Merge commit '81dc066758ec150b43822d4a0c84aae20fe10f40' into ↵bjorn3-24/+14
sync_cg_clif-2023-10-09
2023-09-07Use `Freeze` for `SourceFile.lines`John Kåre Alsaker-1/+1
2023-09-03Use relative positions inside a SourceFile.Camille GILLOT-5/+2
2023-07-22Merge commit '1eded3619d0e55d57521a259bf27a03906fdfad0' into ↵bjorn3-2/+2
sync_cg_clif-2023-07-22
2023-06-29Avoid unnecessary line lookup.Nicholas Nethercote-1/+1
`lookup_debug_loc` calls `SourceMap::lookup_line`, which does a binary search over the files, and then a binary search over the lines within the found file. It then calls `SourceFile::line_begin_pos`, which redoes the binary search over the lines within the found file. This commit removes the second binary search over the lines, instead getting the line starting pos directly using the result of the first binary search over the lines. (And likewise for `get_span_loc`, in the cranelift backend.)
2023-03-15Merge commit 'dec0daa8f6d0a0e1c702f169abb6bf3eee198c67' into ↵bjorn3-1/+1
sync_cg_clif-2023-03-15
2023-01-24Merge commit '598f0909568a51de8a2d1148f55a644fd8dffad0' into ↵bjorn3-5/+9
sync_cg_clif-2023-01-24
2023-01-16Move compiler input and ouput paths into sessionOli Scherer-1/+1
2022-12-14Merge commit '2bb3996244cf1b89878da9e39841e9f6bf061602' into ↵bjorn3-1/+3
sync_cg_clif-2022-12-14
2022-11-09Fix `rustdoc --version` when used with download-rustcJoshua Nelson-1/+1
Previously, rustdoc would unconditionally report the version that *rustc* was compiled with. That showed things like `nightly-2022-10-30`, which wasn't right, since this was a `dev` build compiled from source. Fix it by changing `rustc_driver::version` to a macro expanded at invocation time.
2022-09-07ssa: implement `#[collapse_debuginfo]`David Wood-3/+3
Debuginfo line information for macro invocations are collapsed by default - line information are replaced by the line of the outermost expansion site. Using `-Zdebug-macros` disables this behaviour. When the `collapse_debuginfo` feature is enabled, the default behaviour is reversed so that debuginfo is not collapsed by default. In addition, the `#[collapse_debuginfo]` attribute is available and can be applied to macro definitions which will then have their line information collapsed. Signed-off-by: David Wood <david.wood@huawei.com>
2022-08-24Merge commit 'e9d1a0a7b0b28dd422f1a790ccde532acafbf193' into ↵bjorn3-359/+138
sync_cg_clif-2022-08-24
2022-07-13Rename `debugging_opts` to `unstable_opts`Joshua Nelson-1/+1
This is no longer used only for debugging options (e.g. `-Zoutput-width`, `-Zallow-features`). Rename it to be more clear.
2022-03-20Merge commit '370c397ec9169809e5ad270079712e0043514240' into ↵bjorn3-7/+7
sync_cg_clif-2022-03-20
2022-02-15Overhaul `TyS` and `Ty`.Nicholas Nethercote-2/+2
Specifically, change `Ty` from this: ``` pub type Ty<'tcx> = &'tcx TyS<'tcx>; ``` to this ``` pub struct Ty<'tcx>(Interned<'tcx, TyS<'tcx>>); ``` There are two benefits to this. - It's now a first class type, so we can define methods on it. This means we can move a lot of methods away from `TyS`, leaving `TyS` as a barely-used type, which is appropriate given that it's not meant to be used directly. - The uniqueness requirement is now explicit, via the `Interned` type. E.g. the pointer-based `Eq` and `Hash` comes from `Interned`, rather than via `TyS`, which wasn't obvious at all. Much of this commit is boring churn. The interesting changes are in these files: - compiler/rustc_middle/src/arena.rs - compiler/rustc_middle/src/mir/visit.rs - compiler/rustc_middle/src/ty/context.rs - compiler/rustc_middle/src/ty/mod.rs Specifically: - Most mentions of `TyS` are removed. It's very much a dumb struct now; `Ty` has all the smarts. - `TyS` now has `crate` visibility instead of `pub`. - `TyS::make_for_test` is removed in favour of the static `BOOL_TY`, which just works better with the new structure. - The `Eq`/`Ord`/`Hash` impls are removed from `TyS`. `Interned`s impls of `Eq`/`Hash` now suffice. `Ord` is now partly on `Interned` (pointer-based, for the `Equal` case) and partly on `TyS` (contents-based, for the other cases). - There are many tedious sigil adjustments, i.e. adding or removing `*` or `&`. They seem to be unavoidable.
2022-01-11Store a `Symbol` instead of an `Ident` in `VariantDef`/`FieldDef`Aaron Hill-1/+1
The field is also renamed from `ident` to `name. In most cases, we don't actually need the `Span`. A new `ident` method is added to `VariantDef` and `FieldDef`, which constructs the full `Ident` using `tcx.def_ident_span()`. This method is used in the cases where we actually need an `Ident`. This makes incremental compilation properly track changes to the `Span`, without all of the invalidations caused by storing a `Span` directly via an `Ident`.
2021-12-30Merge commit '40b00f4200fbdeefd11815398cb46394b8cb0a5e' into ↵bjorn3-14/+14
sync_cg_clif-2021-12-30
2021-12-20Merge commit '97e504549371d7640cf011d266e3c17394fdddac' into ↵bjorn3-37/+11
sync_cg_clif-2021-12-20
2021-09-19Merge commit '61667dedf55e3e5aa584f7ae2bd0471336b92ce9' into ↵bjorn3-5/+92
sync_cg_clif-2021-09-19
2021-09-03Auto merge of #88363 - michaelwoerister:remapped-diagnostics, r=estebankbors-1/+1
Path remapping: Make behavior of diagnostics output dependent on presence of --remap-path-prefix. This PR fixes a regression (#87745) with `--remap-path-prefix` where the flag stopped causing diagnostic messages to be remapped as well. The regression was introduced in https://github.com/rust-lang/rust/pull/83813 where we erroneously assumed that remapping of diagnostic messages was not desired anymore (because #70642 partially undid that functionality with nobody objecting). The issue is fixed by making `--remap-path-prefix` remap diagnostic messages again, including for paths that have been remapped in upstream crates (e.g. the standard library). This means that "sysroot-localization" (implemented in #70642) is also disabled if `rustc` is invoked with `--remap-path-prefix`. The assumption is that once someone starts explicitly remapping paths they also don't want paths to their local Rust installation in their build output. In the future we might want to give more fine-grained control over this behavior via compiler flags (see https://github.com/rust-lang/rfcs/pull/3127 for a related RFC). For now this PR is intended as a regression fix. This PR is an alternative to https://github.com/rust-lang/rust/pull/88191, which makes diagnostic messages be remapped unconditionally. That approach, however, would effectively revert #70642. Fixes https://github.com/rust-lang/rust/issues/87745. cc `@cbeuw` r? `@ghost`
2021-08-30rustc_target: `TyAndLayout::field` should never error.Eduard-Mihai Burtescu-6/+4