[LLVMdev] Naming TBAA nodes in LLVM >=3.6?

Robison, Arch arch.robison at intel.com
Thu May 28 11:20:56 PDT 2015


In Julia's use of LLVM, we were naming TBAA nodes with logic like this for LLVM 3.3:

static MDNode *tbaa_make_child( const char *name, MDNode *parent, bool isConstant=false )
{
    MDNode *n = mbuilder->createTBAANode(name,parent,isConstant);
    n->setValueName( ValueName::Create(name, name+strlen(name)));
    return n;
}

The names would show up in dumps of the IR (e.g. "call F.dump()" from gdb) , which was really handy for debugging.  But with LLVM 3.6's split of Value and MDNode, the naming facility seems to have disappeared.  Is there a way with LLVM 3.6 or later to name MDNodes in a way that will show up in IR dumps?

Arch Robison
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20150528/6f6d6831/attachment.html>


More information about the llvm-dev mailing list