[llvm-dev] Assertion isUniqued() failure

David Jones via llvm-dev llvm-dev at lists.llvm.org
Tue Jan 12 10:17:04 PST 2016


Well, I'm not sure if I can do #2 because the metadata needs to be resolved
in order to print out the IR (is this true?) I'm not even sure if
non-uniqueness is something that will show up on an IR dump.

I believe the problem has to do with self-referential metadata. The error
occurs in a situation that may generate it, and I see that new methods have
been added to DIBuilder to deal with this: replaceVTableHolder,
replaceArrays, replaceTemporary.

I now need to determine if/how to use these. The description in the include
file is not very clear.

On Tue, Jan 12, 2016 at 1:07 PM, mats petersson <mats at planetcatfish.com>
wrote:

> I'm not sure of this particular error, but I have been working on
> implementing debug info in my code, and my principle for debugging the
> debug info is comprised of:
> 1. Minimise the code until the problem goes away, then undo the last
> change.
> 2. Generate LLVM-IR and inspect manually.
> 3. Dump the metadata and try to trace it back to the original construct
> (and then a lot of thinking to understand why it's not working)
>
> I'm sorry if I'm telling you things you already know...
>
> --
> Mats
>
> On 12 January 2016 at 14:06, David Jones via llvm-dev <
> llvm-dev at lists.llvm.org> wrote:
>
>> I'm upgrading my application to use LLVM 3.7.1 instead of 3.5.1.
>>
>> On one of my regression tests I am getting an assertion:
>>
>>  /home2/djones/llvm-3.7.1.src/lib/IR/Metadata.cpp:490: void
>> llvm::MDNode::resolve(): Assertion `isUniqued() && "Expected this to be
>> uniqued"' failed.
>>
>> This occurs when finalizing debug info prior to code generation:
>>
>> #4  0x00007ffff4520455 in llvm::MDNode::resolve() () from
>> /tools/llvm/3.7.1dbg/lib/libLLVM-3.7.1.so
>> #5  0x00007ffff4520f16 in llvm::MDNode::resolveCycles() () from
>> /tools/llvm/3.7.1dbg/lib/libLLVM-3.7.1.so
>> #6  0x00007ffff4434654 in llvm::DIBuilder::finalize() () from
>> /tools/llvm/3.7.1dbg/lib/libLLVM-3.7.1.so
>>
>> I am using DIBuilder to generate all debug metadata. What application
>> behavior would cause this assertion?
>>
>> _______________________________________________
>> LLVM Developers mailing list
>> llvm-dev at lists.llvm.org
>> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev
>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20160112/782619a5/attachment-0001.html>


More information about the llvm-dev mailing list