-
Notifications
You must be signed in to change notification settings - Fork 13k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cg_llvm: Use constants for DWARF opcodes, instead of FFI calls #135115
Conversation
Could not assign reviewer from: |
r? @Noratrieb rustbot has assigned @Noratrieb. Use |
For historical reference, the removal of fake Introduction of |
@@ -87,8 +75,6 @@ type SmallVec<T> = smallvec::SmallVec<[T; 16]>; | |||
mod enums; | |||
mod type_map; | |||
|
|||
pub(crate) use type_map::TypeMap; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I moved this to where the other imports are, so that it doesn't trick rust-analyzer into adding new imports in the wrong place.
This comment has been minimized.
This comment has been minimized.
I'll rebase this and also incorporate the new constant added by #133990. |
This comment was marked as resolved.
This comment was marked as resolved.
The `gimli` crate is already a dependency of `thorin-dwp`, which is already a dependency of `rustc_codegen_ssa`.
These commits modify the If this was unintentional then you should revert the changes before this PR is merged. |
@@ -9,6 +9,7 @@ test = false | |||
[dependencies] | |||
# tidy-alphabetical-start | |||
bitflags = "2.4.1" | |||
gimli = "0.30" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
mmm, three versions of gimli in the repo... should fix that...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, it looks like we have:
- 0.31 (latest) used by run-make-support, which actually needs it
- 0.30
used by most stuff, which can probably be bumped to 0.31- used by
thorin-dwp
, which has been bumped on main but hasn't had another release since then - bump
gimli
to 0.31 to avoid duplicate inrust-lang/rust
thorin#36
- used by
- 0.28 used by an old addr2line, which is pulled in by anyhow's
backtrace
feature, which is perhaps not even needed nowadays?- also pulled in by color-eyre
@bors r+ rollup |
Rollup of 3 pull requests Successful merges: - rust-lang#135115 (cg_llvm: Use constants for DWARF opcodes, instead of FFI calls) - rust-lang#135118 (Clarified the documentation on `core::iter::from_fn` and `core::iter::successors`) - rust-lang#135121 (Mark `slice::reverse` unstably const) r? `@ghost` `@rustbot` modify labels: rollup
Rollup merge of rust-lang#135115 - Zalathar:dwarf-const, r=workingjubilee cg_llvm: Use constants for DWARF opcodes, instead of FFI calls Split off from rust-lang#134009 to incorporate feedback from rust-lang#134009 (comment). Most of the constant values now come from gimli, which is already a compiler dependency. I noticed that `DW_OP_LLVM_fragment` is an LLVM detail that is not defined by DWARF and could hypothetically change, so I added a static assertion on the C++ side to detect that if it ever happens. r? workingjubilee
Split off from #134009 to incorporate feedback from #134009 (comment).
Most of the constant values now come from gimli, which is already a compiler dependency.
I noticed that
DW_OP_LLVM_fragment
is an LLVM detail that is not defined by DWARF and could hypothetically change, so I added a static assertion on the C++ side to detect that if it ever happens.r? workingjubilee