IR: Add MDNode::isDistinct()
authorDuncan P. N. Exon Smith <dexonsmith@apple.com>
Wed, 7 Jan 2015 21:35:38 +0000 (21:35 +0000)
committerDuncan P. N. Exon Smith <dexonsmith@apple.com>
Wed, 7 Jan 2015 21:35:38 +0000 (21:35 +0000)
commit136ea3f97b64f82666cb6c8803321e7160af16c7
tree21ca2f2877dd309a415e233bc34dfc764a4b9a99
parent9d01a5b5e4432ef56b3cfdd3ea56a140ee9326ab
IR: Add MDNode::isDistinct()

Add API to indicate whether an `MDNode` is distinct.  A distinct node is
not stored in the MDNode uniquing tables, and will never be returned by
`MDNode::get()`.

Although distinct nodes are only currently created by uniquing
collisions (when operands change), PR22111 will allow these nodes to be
explicitly created.

llvm-svn: 225401
llvm/include/llvm/IR/Metadata.h
llvm/unittests/IR/MetadataTest.cpp