Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(467)

Issue 10442019: llvm: workaround debug info with bad invariants (Closed)

Created:
8 years, 7 months ago by jvoung (off chromium)
Modified:
8 years, 6 months ago
CC:
native-client-reviews_googlegroups.com
Visibility:
Public.

Description

llvm: workaround for dangling debug info Value.cpp fires an assertion when there is a dangling reference to a Value from the "UseList". I.e., it may have been added to the UseList twice, but only removed once before deletion. Occasionally debug nodes are duplicated when they should not be, or DAGs are formed when they should not be, after bitcode linking. This may set up the above issue. For now, while we are still debugging the bitcode linking, try the following workaround. Turn the LexicalScope's value handle for debug info from AssertingVH to WeakVH, by hacking AssertingVH to be able to be switched to Weak (really gross). WeakVH get cleaned up by ValueIsDeleted and remove themselves from the list, while AssertingVH do not (see lib/VMCore/Value.cpp). Thus, this prevents the original assert from triggering. We've only seen the assertion while llvm is shutting down, hopefully this workaround won't be a problem, and it only affects debug mode. BUG= http://code.google.com/p/nativeclient/issues/detail?id=2786 TEST= tumbler, IRT, dosbox with -g

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+20 lines, -0 lines) Patch
M llvm/include/llvm/CodeGen/LexicalScopes.h View 1 chunk +6 lines, -0 lines 0 comments Download
M llvm/include/llvm/Support/ValueHandle.h View 2 chunks +14 lines, -0 lines 0 comments Download

Messages

Total messages: 2 (0 generated)
jvoung (off chromium)
8 years, 7 months ago (2012-05-24 21:20:11 UTC) #1
Robert Muth (chromium)
8 years, 7 months ago (2012-05-24 21:51:13 UTC) #2
LGTM

Powered by Google App Engine
This is Rietveld 408576698