Skip to content
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

Teach rustc about DW_AT_noreturn and a few more DIFlags #47618

Merged
merged 3 commits into from
Jan 26, 2018

Conversation

mrhota
Copy link
Contributor

@mrhota mrhota commented Jan 20, 2018

We achieve two small things with this PR:

  1. We provide definitions for a few additional llvm debuginfo flags
  2. We use one of these new flags, FlagNoReturn, and add it to debuginfo for functions with the never return type (!).

@mrhota
Copy link
Contributor Author

mrhota commented Jan 21, 2018

i'm not sure why test fails on travis. it passes locally when I run the individual test and ./x.py test:

...
test [codegen] codegen/x86_mmx.rs ... ignored
test [codegen] codegen/zip.rs ... ignored
test [codegen] codegen/noreturnflag.rs ... ok

test result: ok. 1 passed; 0 failed; 62 ignored; 0 measured; 0 filtered out

@@ -545,6 +549,18 @@ static unsigned fromRust(LLVMRustDIFlags Flags) {
Result |= DINode::DIFlags::FlagRValueReference;
}
#if LLVM_RUSTLLVM || LLVM_VERSION_GE(4, 0)
Copy link
Member

@kennytm kennytm Jan 21, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i'm not sure why test fails on travis.

The CI uses the system LLVM 3.9 for testing, so both conditions are going to be false, meaning these flags won't be applied at all.

You may move these flags into another #if block which does not check LLVM_RUSTLLVM (assume these can apply to the unmodified LLVM), or tag the test case with // no-system-llvm.

@kennytm kennytm added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Jan 21, 2018
@kennytm
Copy link
Member

kennytm commented Jan 21, 2018

r? @michaelwoerister

@michaelwoerister
Copy link
Member

Thanks for the PR, @mrhota!

@bors r+

@bors
Copy link
Contributor

bors commented Jan 23, 2018

📌 Commit e0f9b26 has been approved by michaelwoerister

@kennytm kennytm added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jan 24, 2018
alexcrichton added a commit to alexcrichton/rust that referenced this pull request Jan 25, 2018
…rister

Teach rustc about DW_AT_noreturn and a few more DIFlags

We achieve two small things with this PR:
1. We provide definitions for a few additional llvm debuginfo flags
1. We _use_ one of these new flags, `FlagNoReturn`, and add it to debuginfo for functions with the never return type (`!`).
bors added a commit that referenced this pull request Jan 26, 2018
@bors
Copy link
Contributor

bors commented Jan 26, 2018

☔ The latest upstream changes (presumably #47748) made this pull request unmergeable. Please resolve the merge conflicts.

@bors bors merged commit e0f9b26 into rust-lang:master Jan 26, 2018
@mrhota mrhota deleted the dw_at_noreturn branch January 27, 2018 01:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants