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

Clients of SelectionDAG::ReplaceAllUsesWith drop debug info, & are inconsistent #34686

Open
vedantk opened this issue Nov 17, 2017 · 2 comments
Assignees
Labels
bugzilla Issues migrated from bugzilla debuginfo llvm:codegen llvm:SelectionDAG SelectionDAGISel as well

Comments

@vedantk
Copy link
Collaborator

vedantk commented Nov 17, 2017

Bugzilla Link 35338
Version trunk
OS All
Attachments Rough patch to enforce "don't drop debug info" in CombineTo().
CC @adrian-prantl,@gregbedwell,@JDevlieghere,@jmorse,@RKSimon,@pogo59,@rnk

Extended Description

There are a few issues here:

  • CombineTo() calls ReplaceAllUsesWith(), which calls transferDbgValues(). If we assert that debug line/value information is preserved after the RAUW in CombineTo(), a bunch of tests fail.

  • Clients of transferDbgValues() pass it SDValues which are attached to SDNodes with invalidated debug info. It seems unfortunate that we'd even try to propagate invalid debug info.

  • One overload of ReplaceAllUsesWith(From, To) requires From != To, but another doesn't. This is partly annoying, but may also be masking correctness issues.

@vedantk
Copy link
Collaborator Author

vedantk commented Nov 17, 2017

assigned to @vedantk

@llvmbot llvmbot transferred this issue from llvm/llvm-bugzilla-archive Dec 10, 2021
@arsenm arsenm added debuginfo llvm:SelectionDAG SelectionDAGISel as well labels Aug 17, 2023
@llvmbot
Copy link
Collaborator

llvmbot commented Aug 17, 2023

@llvm/issue-subscribers-debuginfo

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugzilla Issues migrated from bugzilla debuginfo llvm:codegen llvm:SelectionDAG SelectionDAGISel as well
Projects
None yet
Development

No branches or pull requests

3 participants