Skip to content

cannot build rustc with -g #29923

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

Closed
nikomatsakis opened this issue Nov 19, 2015 · 4 comments
Closed

cannot build rustc with -g #29923

nikomatsakis opened this issue Nov 19, 2015 · 4 comments
Labels
A-debuginfo Area: Debugging information in compiled programs (DWARF, PDB, etc.) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Comments

@nikomatsakis
Copy link
Contributor

When I try to bootstrap the compiler with RUSTFLAGS=-g, I get the following result:

!dbg attachment points at wrong subprogram for function
!157160 = !DISubprogram(name: "fnfn", linkageName: "fnfn", scope: !157144, file: !157144, line: 38, type: !46087, isLocal: true, isDefinition: true, scopeLine: 38, flags: DIFlagPrototyped, isOptimized: t\
rue, function: i64 (%closure.1177*, %"ast::Expr"*)* @_ZN3ext6expand11expand_expr13closure.70644E, templateParams: !1064, variables: !157161)
i64 (%closure.1177*, %"ast::Expr"*)* @_ZN3ext6expand11expand_expr13closure.70644E
  tail call void @llvm.dbg.value(metadata %"ext::expand::IdentRenamer"* %rename_fld.i.857, i64 0, metadata !157531, metadata !191193), !dbg !784008
!784008 = !DILocation(line: 113, scope: !157525, inlinedAt: !784009)
!784010 = distinct !DILexicalBlock(scope: !784011, file: !157144, line: 129, column: 56)
!160778 = !DISubprogram(name: "fnfn", linkageName: "fnfn", scope: !157144, file: !157144, line: 129, type: !160779, isLocal: true, isDefinition: true, scopeLine: 129, flags: DIFlagPrototyped, isOptimized\
: true, templateParams: !1064, variables: !160781)
LLVM ERROR: Broken function found, compilation aborted!
m

cc @rust-lang/compiler @michaelwoerister

@nikomatsakis nikomatsakis added A-debuginfo Area: Debugging information in compiled programs (DWARF, PDB, etc.) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Nov 19, 2015
@dotdash
Copy link
Contributor

dotdash commented Nov 19, 2015

Stage 0? Looks like the LLVM bug for which we recently cherry-picked a
bugfix. Probably works in stage 1 and just needs a new snapshot
Am 19.11.2015 11:23 schrieb "Niko Matsakis" notifications@github.com:

When I build with RUSTFLAGS=-g, I get the following result:

!dbg attachment points at wrong subprogram for function
!157160 = !DISubprogram(name: "fnfn", linkageName: "fnfn", scope: !157144, file: !157144, line: 38, type: !46087, isLocal: true, isDefinition: true, scopeLine: 38, flags: DIFlagPrototyped, isOptimized: t
rue, function: i64 (%closure.1177_, %"ast::Expr")* @ZN3ext6expand11expand_expr13closure.70644E, templateParams: !1064, variables: !157161)
i64 (%closure.1177
, %"ast::Expr"
)* @_ZN3ext6expand11expand_expr13closure.70644E
tail call void @llvm.dbg.value(metadata %"ext::expand::IdentRenamer"* %rename_fld.i.857, i64 0, metadata !157531, metadata !191193), !dbg !784008
!784008 = !DILocation(line: 113, scope: !157525, inlinedAt: !784009)
!784010 = distinct !DILexicalBlock(scope: !784011, file: !157144, line: 129, column: 56)
!160778 = !DISubprogram(name: "fnfn", linkageName: "fnfn", scope: !157144, file: !157144, line: 129, type: !160779, isLocal: true, isDefinition: true, scopeLine: 129, flags: DIFlagPrototyped, isOptimized
: true, templateParams: !1064, variables: !160781)
LLVM ERROR: Broken function found, compilation aborted!
m

cc @rust-lang/compiler https://github.com/orgs/rust-lang/teams/compiler
@michaelwoerister https://github.com/michaelwoerister


Reply to this email directly or view it on GitHub
#29923.

@nikomatsakis
Copy link
Contributor Author

That'd be nice! (Testing that theory now...)

@nikomatsakis
Copy link
Contributor Author

Yes, this is the problem.

@sanxiyn
Copy link
Member

sanxiyn commented Jan 5, 2016

A new snapshot is done, closing. (This is also tested by auto-linux-64-debug-opt on buildbot now.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-debuginfo Area: Debugging information in compiled programs (DWARF, PDB, etc.) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

No branches or pull requests

3 participants