Lines Matching refs:Context
29 LLVMContext Context; in TEST() local
30 ContextAndReplaceableUses CRU(Context); in TEST()
31 EXPECT_EQ(&Context, &CRU.getContext()); in TEST()
37 LLVMContext Context; in TEST() local
38 ContextAndReplaceableUses CRU(make_unique<ReplaceableMetadataImpl>(Context)); in TEST()
39 EXPECT_EQ(&Context, &CRU.getContext()); in TEST()
45 LLVMContext Context; in TEST() local
46 ContextAndReplaceableUses CRU(Context); in TEST()
47 CRU.makeReplaceable(make_unique<ReplaceableMetadataImpl>(Context)); in TEST()
48 EXPECT_EQ(&Context, &CRU.getContext()); in TEST()
54 LLVMContext Context; in TEST() local
55 auto ReplaceableUses = make_unique<ReplaceableMetadataImpl>(Context); in TEST()
59 EXPECT_EQ(&Context, &CRU.getContext()); in TEST()
67 MetadataTest() : M("test", Context), Counter(0) {} in MetadataTest()
70 LLVMContext Context; member in __anon68cdb3b90111::MetadataTest
74 MDNode *getNode() { return MDNode::get(Context, None); } in getNode()
75 MDNode *getNode(Metadata *MD) { return MDNode::get(Context, MD); } in getNode()
78 return MDNode::get(Context, MDs); in getNode()
81 MDTuple *getTuple() { return MDTuple::getDistinct(Context, None); } in getTuple()
83 return DISubroutineType::getDistinct(Context, 0, 0, getNode(nullptr)); in getSubroutineType()
86 return DISubprogram::getDistinct(Context, nullptr, "", "", nullptr, 0, in getSubprogram()
91 return DIFile::getDistinct(Context, "file.c", "/path/to/dir"); in getFile()
94 return DICompileUnit::getDistinct(Context, 1, getFile(), "clang", false, in getUnit()
100 return DIBasicType::get(Context, dwarf::DW_TAG_unspecified_type, Name); in getBasicType()
103 return DIDerivedType::getDistinct(Context, dwarf::DW_TAG_pointer_type, "", in getDerivedType()
108 return ConstantInt::get(Type::getInt32Ty(Context), Counter++); in getConstant()
115 Context, dwarf::DW_TAG_structure_type, "", nullptr, 0, nullptr, nullptr, in getCompositeType()
120 Name, FunctionType::get(Type::getVoidTy(Context), None, false))); in getFunction()
129 MDString *s1 = MDString::get(Context, StringRef(&x[0], 3)); in TEST_F()
131 MDString *s2 = MDString::get(Context, StringRef(&x[0], 3)); in TEST_F()
141 MDString *s1 = MDString::get(Context, StringRef(&x[0], 3)); in TEST_F()
142 MDString *s2 = MDString::get(Context, StringRef(&y[0], 3)); in TEST_F()
150 MDString *s = MDString::get(Context, StringRef(str, 13)); in TEST_F()
163 MDString *s = MDString::get(Context, StringRef(str+0, 5)); in TEST_F()
177 MDString *s1 = MDString::get(Context, StringRef(&x[0], 3)); in TEST_F()
178 MDString *s2 = MDString::get(Context, StringRef(&y[0], 3)); in TEST_F()
180 ConstantAsMetadata::get(ConstantInt::get(Context, APInt(8, 0))); in TEST_F()
187 MDNode *n1 = MDNode::get(Context, V); in TEST_F()
189 MDNode *n2 = MDNode::get(Context, c1); in TEST_F()
191 MDNode *n3 = MDNode::get(Context, V); in TEST_F()
192 MDNode *n4 = MDNode::getIfExists(Context, V); in TEST_F()
193 MDNode *n5 = MDNode::getIfExists(Context, c1); in TEST_F()
194 MDNode *n6 = MDNode::getIfExists(Context, c2); in TEST_F()
211 Constant *C = ConstantInt::get(Type::getInt32Ty(Context), 1); in TEST_F()
212 Instruction *I = new BitCastInst(C, Type::getInt32Ty(Context)); in TEST_F()
215 MDNode *n = MDNode::get(Context, V); in TEST_F()
227 auto Temp = MDNode::getTemporary(Context, None); in TEST_F()
229 MDNode *Self = MDNode::get(Context, Args); in TEST_F()
236 MDNode *Ref1 = MDNode::get(Context, Args); in TEST_F()
237 MDNode *Ref2 = MDNode::get(Context, Args); in TEST_F()
245 auto Temp = MDNode::getTemporary(Context, None); in TEST_F()
246 Metadata *Args[] = {Temp.get(), MDNode::get(Context, None)}; in TEST_F()
247 MDNode *Self = MDNode::get(Context, Args); in TEST_F()
254 MDNode *Ref1 = MDNode::get(Context, Args); in TEST_F()
255 MDNode *Ref2 = MDNode::get(Context, Args); in TEST_F()
262 Constant *C = ConstantInt::get(Type::getInt32Ty(Context), 7); in TEST_F()
263 MDString *S = MDString::get(Context, "foo"); in TEST_F()
269 MDNode *N = MDNode::get(Context, Args); in TEST_F()
306 TempMDNode Temp = MDNode::getTemporary(Context, Arg); in TEST_F()
308 Module M("test", Context); in TEST_F()
321 Constant *C = ConstantInt::get(Type::getInt32Ty(Context), 7); in TEST_F()
322 MDString *S = MDString::get(Context, "foo"); in TEST_F()
328 MDNode *N = MDNode::get(Context, Args); in TEST_F()
329 Module M("test", Context); in TEST_F()
347 Module M("test", Context); in TEST_F()
348 auto *FTy = FunctionType::get(Type::getVoidTy(Context), false); in TEST_F()
351 auto *BB0 = BasicBlock::Create(Context, "entry", F0); in TEST_F()
352 auto *BB1 = BasicBlock::Create(Context, "entry", F1); in TEST_F()
353 auto *R0 = ReturnInst::Create(Context, BB0); in TEST_F()
354 auto *R1 = ReturnInst::Create(Context, BB1); in TEST_F()
355 auto *N0 = MDNode::getDistinct(Context, None); in TEST_F()
356 auto *N1 = MDNode::getDistinct(Context, None); in TEST_F()
369 Module M("test", Context); in TEST_F()
372 Function::Create(FunctionType::get(Type::getVoidTy(Context), in TEST_F()
373 Type::getMetadataTy(Context), false), in TEST_F()
376 auto *FTy = FunctionType::get(Type::getVoidTy(Context), false); in TEST_F()
379 auto *BB0 = BasicBlock::Create(Context, "entry", F0); in TEST_F()
380 auto *BB1 = BasicBlock::Create(Context, "entry", F1); in TEST_F()
381 auto *N0 = MDNode::getDistinct(Context, None); in TEST_F()
382 auto *N1 = MDNode::getDistinct(Context, None); in TEST_F()
383 auto *MAV0 = MetadataAsValue::get(Context, N0); in TEST_F()
384 auto *MAV1 = MetadataAsValue::get(Context, N1); in TEST_F()
407 MDNode *Empty = MDNode::get(Context, None); in TEST_F()
411 MDNode *N = MDNode::get(Context, Ops); in TEST_F()
420 MDNode *NullOp = MDNode::get(Context, Ops); in TEST_F()
427 MDNode *Empty = MDNode::get(Context, None); in TEST_F()
433 MDNode *Wrapped1 = MDNode::get(Context, Wrapped1Ops); in TEST_F()
440 MDNode *Wrapped2 = MDNode::get(Context, Wrapped2Ops); in TEST_F()
454 MDNode *Empty = MDNode::get(Context, None); in TEST_F()
457 ASSERT_EQ(Empty, MDNode::get(Context, None)); in TEST_F()
460 MDNode *Distinct1 = MDNode::getDistinct(Context, None); in TEST_F()
461 MDNode *Distinct2 = MDNode::getDistinct(Context, None); in TEST_F()
469 ASSERT_EQ(Empty, MDNode::get(Context, None)); in TEST_F()
473 MDNode *U = MDTuple::get(Context, None); in TEST_F()
474 MDNode *D = MDTuple::getDistinct(Context, None); in TEST_F()
475 auto T = MDTuple::getTemporary(Context, None); in TEST_F()
482 MDNode *U = MDTuple::get(Context, None); in TEST_F()
483 MDNode *D = MDTuple::getDistinct(Context, None); in TEST_F()
484 auto T = MDTuple::getTemporary(Context, None); in TEST_F()
491 MDNode *U = MDTuple::get(Context, None); in TEST_F()
492 MDNode *D = MDTuple::getDistinct(Context, None); in TEST_F()
493 auto T = MDTuple::getTemporary(Context, None); in TEST_F()
501 auto Temp = MDTuple::getTemporary(Context, None); in TEST_F()
506 MDNode *Distinct = MDNode::getDistinct(Context, Ops); in TEST_F()
511 MDNode *Empty = MDNode::get(Context, None); in TEST_F()
518 MDNode *N0 = MDNode::get(Context, None); in TEST_F()
521 auto Temp3 = MDTuple::getTemporary(Context, None); in TEST_F()
523 MDNode *N1 = MDNode::get(Context, Ops1); in TEST_F()
527 MDNode *N2 = MDNode::get(Context, Ops2); in TEST_F()
531 MDNode *N3 = MDNode::get(Context, Ops3); in TEST_F()
536 MDNode *N4 = MDNode::get(Context, Ops4); in TEST_F()
550 MDNode *N5 = MDNode::getDistinct(Context, Ops5); in TEST_F()
552 MDNode *N6 = MDNode::getDistinct(Context, Ops6); in TEST_F()
585 auto Temp = MDTuple::getTemporary(Context, None); in TEST_F()
588 MDNode *Empty = MDTuple::get(Context, ArrayRef<Metadata *>()); in TEST_F()
589 MDNode *N = MDTuple::get(Context, Ops); in TEST_F()
606 auto *Empty = MDTuple::get(Context, None); in TEST_F()
610 auto Temp = MDTuple::getTemporary(Context, Ops); in TEST_F()
622 auto Temp = MDTuple::getTemporary(Context, Ops); in TEST_F()
632 auto Unresolved = MDTuple::getTemporary(Context, None); in TEST_F()
634 auto Temp = MDTuple::getTemporary(Context, Ops); in TEST_F()
654 MDTuple *Op = MDTuple::getTemporary(Context, None).release(); in TEST_F()
659 MDTuple *N = MDTuple::getTemporary(Context, Ops).release(); in TEST_F()
674 Type *Ty = Type::getInt1PtrTy(Context); in TEST_F()
681 MDTuple *N = MDTuple::getTemporary(Context, Ops).release(); in TEST_F()
691 ASSERT_EQ(N, MDTuple::get(Context, NullOps)); in TEST_F()
696 auto *Empty = MDTuple::get(Context, None); in TEST_F()
698 auto Temp = MDTuple::getTemporary(Context, Ops); in TEST_F()
709 auto Unresolved = MDTuple::getTemporary(Context, None); in TEST_F()
711 auto Temp = MDTuple::getTemporary(Context, Ops); in TEST_F()
728 auto Temp = MDTuple::getTemporary(Context, Ops); in TEST_F()
732 auto *U = MDTuple::get(Context, T); in TEST_F()
748 EXPECT_EQ(U, MDTuple::get(Context, N)); in TEST_F()
753 EXPECT_EQ(U, MDNode::replaceWithPermanent(MDTuple::getTemporary(Context, N))); in TEST_F()
757 auto Temp2 = MDTuple::getTemporary(Context, U); in TEST_F()
768 auto Temp = MDTuple::getTemporary(Context, None); in TEST_F()
780 DILocation *L = DILocation::get(Context, 2, 7, N); in TEST_F()
786 DILocation *L = DILocation::get(Context, UINT32_MAX, U16 - 1, N); in TEST_F()
791 DILocation *L = DILocation::get(Context, UINT32_MAX, U16, N); in TEST_F()
796 DILocation *L = DILocation::get(Context, UINT32_MAX, U16 + 1, N); in TEST_F()
804 DILocation *L0 = DILocation::getDistinct(Context, 2, 7, N); in TEST_F()
806 DILocation *L1 = DILocation::get(Context, 2, 7, N); in TEST_F()
808 EXPECT_EQ(L1, DILocation::get(Context, 2, 7, N)); in TEST_F()
812 MDNode *N = MDNode::get(Context, None); in TEST_F()
813 auto L = DILocation::getTemporary(Context, 2, 7, N); in TEST_F()
819 MDNode *N = MDNode::get(Context, None); in TEST_F()
820 auto L = DILocation::getTemporary(Context, 2, 7, N); in TEST_F()
830 auto *Empty = MDNode::get(Context, None); in TEST_F()
832 auto *N = GenericDINode::get(Context, 15, Header, Ops1); in TEST_F()
836 EXPECT_EQ(MDString::get(Context, Header), N->getOperand(0)); in TEST_F()
842 EXPECT_EQ(N, GenericDINode::get(Context, 15, Header, Ops1)); in TEST_F()
851 EXPECT_EQ(N, GenericDINode::get(Context, 15, Header, Ops2)); in TEST_F()
858 EXPECT_EQ(N, GenericDINode::get(Context, 15, Header, Ops1)); in TEST_F()
866 auto *N = GenericDINode::get(Context, 15, StringRef(), None); in TEST_F()
874 auto *N = DISubrange::get(Context, 5, 7); in TEST_F()
878 EXPECT_EQ(N, DISubrange::get(Context, 5, 7)); in TEST_F()
879 EXPECT_EQ(DISubrange::get(Context, 5, 0), DISubrange::get(Context, 5)); in TEST_F()
886 auto *N = DISubrange::get(Context, -1, 0); in TEST_F()
890 EXPECT_EQ(N, DISubrange::get(Context, -1, 0)); in TEST_F()
896 auto *N = DIEnumerator::get(Context, 7, "name"); in TEST_F()
900 EXPECT_EQ(N, DIEnumerator::get(Context, 7, "name")); in TEST_F()
902 EXPECT_NE(N, DIEnumerator::get(Context, 8, "name")); in TEST_F()
903 EXPECT_NE(N, DIEnumerator::get(Context, 7, "nam")); in TEST_F()
913 DIBasicType::get(Context, dwarf::DW_TAG_base_type, "special", 33, 26, 7); in TEST_F()
920 EXPECT_EQ(N, DIBasicType::get(Context, dwarf::DW_TAG_base_type, "special", 33, in TEST_F()
923 EXPECT_NE(N, DIBasicType::get(Context, dwarf::DW_TAG_unspecified_type, in TEST_F()
926 DIBasicType::get(Context, dwarf::DW_TAG_base_type, "s", 33, 26, 7)); in TEST_F()
927 EXPECT_NE(N, DIBasicType::get(Context, dwarf::DW_TAG_base_type, "special", 32, in TEST_F()
929 EXPECT_NE(N, DIBasicType::get(Context, dwarf::DW_TAG_base_type, "special", 33, in TEST_F()
931 EXPECT_NE(N, DIBasicType::get(Context, dwarf::DW_TAG_base_type, "special", 33, in TEST_F()
939 auto *N = DIBasicType::get(Context, dwarf::DW_TAG_base_type, "special", in TEST_F()
947 DIBasicType::get(Context, dwarf::DW_TAG_unspecified_type, "unspecified"); in TEST_F()
960 DIType *N = DIBasicType::get(Context, dwarf::DW_TAG_base_type, "int", 32, 32, in TEST_F()
970 Metadata *Types = MDTuple::get(Context, TypesOps); in TEST_F()
972 DIType *D = DISubroutineType::getDistinct(Context, 0u, 0, Types); in TEST_F()
979 TempDIType T = DISubroutineType::getTemporary(Context, 0u, 0, Types); in TEST_F()
995 auto *N = DIDerivedType::get(Context, dwarf::DW_TAG_pointer_type, "something", in TEST_F()
1008 EXPECT_EQ(N, DIDerivedType::get(Context, dwarf::DW_TAG_pointer_type, in TEST_F()
1012 EXPECT_NE(N, DIDerivedType::get(Context, dwarf::DW_TAG_reference_type, in TEST_F()
1015 EXPECT_NE(N, DIDerivedType::get(Context, dwarf::DW_TAG_pointer_type, "else", in TEST_F()
1018 EXPECT_NE(N, DIDerivedType::get(Context, dwarf::DW_TAG_pointer_type, in TEST_F()
1021 EXPECT_NE(N, DIDerivedType::get(Context, dwarf::DW_TAG_pointer_type, in TEST_F()
1024 EXPECT_NE(N, DIDerivedType::get(Context, dwarf::DW_TAG_pointer_type, in TEST_F()
1028 Context, dwarf::DW_TAG_pointer_type, "something", File, 1, in TEST_F()
1030 EXPECT_NE(N, DIDerivedType::get(Context, dwarf::DW_TAG_pointer_type, in TEST_F()
1033 EXPECT_NE(N, DIDerivedType::get(Context, dwarf::DW_TAG_pointer_type, in TEST_F()
1036 EXPECT_NE(N, DIDerivedType::get(Context, dwarf::DW_TAG_pointer_type, in TEST_F()
1039 EXPECT_NE(N, DIDerivedType::get(Context, dwarf::DW_TAG_pointer_type, in TEST_F()
1042 EXPECT_NE(N, DIDerivedType::get(Context, dwarf::DW_TAG_pointer_type, in TEST_F()
1056 auto *N = DIDerivedType::get(Context, dwarf::DW_TAG_pointer_type, "something", in TEST_F()
1083 auto *N = DICompositeType::get(Context, Tag, Name, File, Line, Scope, in TEST_F()
1103 EXPECT_EQ(N, DICompositeType::get(Context, Tag, Name, File, Line, Scope, in TEST_F()
1108 EXPECT_NE(N, DICompositeType::get(Context, Tag + 1, Name, File, Line, Scope, in TEST_F()
1112 EXPECT_NE(N, DICompositeType::get(Context, Tag, "abc", File, Line, Scope, in TEST_F()
1116 EXPECT_NE(N, DICompositeType::get(Context, Tag, Name, getFile(), Line, Scope, in TEST_F()
1120 EXPECT_NE(N, DICompositeType::get(Context, Tag, Name, File, Line + 1, Scope, in TEST_F()
1125 Context, Tag, Name, File, Line, getSubprogram(), BaseType, in TEST_F()
1129 Context, Tag, Name, File, Line, Scope, getBasicType("other"), in TEST_F()
1132 EXPECT_NE(N, DICompositeType::get(Context, Tag, Name, File, Line, Scope, in TEST_F()
1136 EXPECT_NE(N, DICompositeType::get(Context, Tag, Name, File, Line, Scope, in TEST_F()
1141 Context, Tag, Name, File, Line, Scope, BaseType, SizeInBits, in TEST_F()
1145 Context, Tag, Name, File, Line, Scope, BaseType, SizeInBits, in TEST_F()
1149 Context, Tag, Name, File, Line, Scope, BaseType, SizeInBits, in TEST_F()
1153 Context, Tag, Name, File, Line, Scope, BaseType, SizeInBits, in TEST_F()
1157 Context, Tag, Name, File, Line, Scope, BaseType, SizeInBits, in TEST_F()
1160 EXPECT_NE(N, DICompositeType::get(Context, Tag, Name, File, Line, Scope, in TEST_F()
1164 EXPECT_NE(N, DICompositeType::get(Context, Tag, Name, File, Line, Scope, in TEST_F()
1170 EXPECT_FALSE(DICompositeType::get(Context, Tag, Name, File, Line, Scope, in TEST_F()
1175 EXPECT_FALSE(DICompositeType::get(Context, Tag, Name, File, Line, Scope, in TEST_F()
1202 auto *N = DICompositeType::get(Context, Tag, Name, File, Line, Scope, in TEST_F()
1226 Context, Tag, Name, File, Line, Scope, BaseType, SizeInBits, AlignInBits, in TEST_F()
1229 auto *Elements = MDTuple::getDistinct(Context, None); in TEST_F()
1243 auto *TemplateParams = MDTuple::getDistinct(Context, None); in TEST_F()
1257 auto *N = DISubroutineType::get(Context, Flags, 0, TypeArray); in TEST_F()
1261 EXPECT_EQ(N, DISubroutineType::get(Context, Flags, 0, TypeArray)); in TEST_F()
1263 EXPECT_NE(N, DISubroutineType::get(Context, Flags + 1, 0, TypeArray)); in TEST_F()
1264 EXPECT_NE(N, DISubroutineType::get(Context, Flags, 0, getTuple())); in TEST_F()
1268 Context, Flags, dwarf::DW_CC_BORLAND_msfastcall, TypeArray); in TEST_F()
1269 auto *Std = DISubroutineType::get(Context, Flags, in TEST_F()
1272 DISubroutineType::get(Context, Flags, in TEST_F()
1275 Context, Flags, dwarf::DW_CC_BORLAND_stdcall, TypeArray)); in TEST_F()
1295 auto *N = DIFile::get(Context, Filename, Directory); in TEST_F()
1300 EXPECT_EQ(N, DIFile::get(Context, Filename, Directory)); in TEST_F()
1302 EXPECT_NE(N, DIFile::get(Context, "other", Directory)); in TEST_F()
1303 EXPECT_NE(N, DIFile::get(Context, Filename, "other")); in TEST_F()
1311 DIScope *N = DIFile::get(Context, "file", "dir"); in TEST_F()
1333 Context, SourceLanguage, File, Producer, IsOptimized, Flags, in TEST_F()
1386 MDTuple *EnumTypes = MDTuple::getDistinct(Context, None); in TEST_F()
1387 MDTuple *RetainedTypes = MDTuple::getDistinct(Context, None); in TEST_F()
1388 MDTuple *ImportedEntities = MDTuple::getDistinct(Context, None); in TEST_F()
1391 Context, SourceLanguage, File, Producer, IsOptimized, Flags, in TEST_F()
1395 auto *GlobalVariables = MDTuple::getDistinct(Context, None); in TEST_F()
1402 auto *Macros = MDTuple::getDistinct(Context, None); in TEST_F()
1434 auto *N = DISubprogram::get(Context, Scope, Name, LinkageName, File, Line, in TEST_F()
1460 EXPECT_EQ(N, DISubprogram::get(Context, Scope, Name, LinkageName, File, Line, in TEST_F()
1467 Context, getCompositeType(), Name, LinkageName, File, Line, in TEST_F()
1472 Context, Scope, "other", LinkageName, File, Line, Type, in TEST_F()
1476 EXPECT_NE(N, DISubprogram::get(Context, Scope, Name, "other", File, Line, in TEST_F()
1482 Context, Scope, Name, LinkageName, getFile(), Line, Type, in TEST_F()
1487 Context, Scope, Name, LinkageName, File, Line + 1, Type, in TEST_F()
1492 DISubprogram::get(Context, Scope, Name, LinkageName, File, Line, in TEST_F()
1497 EXPECT_NE(N, DISubprogram::get(Context, Scope, Name, LinkageName, File, Line, in TEST_F()
1502 EXPECT_NE(N, DISubprogram::get(Context, Scope, Name, LinkageName, File, Line, in TEST_F()
1508 Context, Scope, Name, LinkageName, File, Line, Type, in TEST_F()
1512 EXPECT_NE(N, DISubprogram::get(Context, Scope, Name, LinkageName, File, Line, in TEST_F()
1517 EXPECT_NE(N, DISubprogram::get(Context, Scope, Name, LinkageName, File, Line, in TEST_F()
1522 EXPECT_NE(N, DISubprogram::get(Context, Scope, Name, LinkageName, File, Line, in TEST_F()
1527 EXPECT_NE(N, DISubprogram::get(Context, Scope, Name, LinkageName, File, Line, in TEST_F()
1532 EXPECT_NE(N, DISubprogram::get(Context, Scope, Name, LinkageName, File, Line, in TEST_F()
1537 EXPECT_NE(N, DISubprogram::get(Context, Scope, Name, LinkageName, File, Line, in TEST_F()
1542 EXPECT_NE(N, DISubprogram::get(Context, Scope, Name, LinkageName, File, Line, in TEST_F()
1547 EXPECT_NE(N, DISubprogram::get(Context, Scope, Name, LinkageName, File, Line, in TEST_F()
1552 EXPECT_NE(N, DISubprogram::get(Context, Scope, Name, LinkageName, File, Line, in TEST_F()
1570 auto *N = DILexicalBlock::get(Context, Scope, File, Line, Column); in TEST_F()
1577 EXPECT_EQ(N, DILexicalBlock::get(Context, Scope, File, Line, Column)); in TEST_F()
1580 DILexicalBlock::get(Context, getSubprogram(), File, Line, Column)); in TEST_F()
1581 EXPECT_NE(N, DILexicalBlock::get(Context, Scope, getFile(), Line, Column)); in TEST_F()
1582 EXPECT_NE(N, DILexicalBlock::get(Context, Scope, File, Line + 1, Column)); in TEST_F()
1583 EXPECT_NE(N, DILexicalBlock::get(Context, Scope, File, Line, Column + 1)); in TEST_F()
1593 auto *LB = DILexicalBlock::get(Context, SP, F, 2, 7); in TEST_F()
1599 auto *LB = DILexicalBlock::get(Context, SP, F, UINT32_MAX, U16 - 1); in TEST_F()
1604 auto *LB = DILexicalBlock::get(Context, SP, F, UINT32_MAX, U16); in TEST_F()
1609 auto *LB = DILexicalBlock::get(Context, SP, F, UINT32_MAX, U16 + 1); in TEST_F()
1622 auto *N = DILexicalBlockFile::get(Context, Scope, File, Discriminator); in TEST_F()
1628 EXPECT_EQ(N, DILexicalBlockFile::get(Context, Scope, File, Discriminator)); in TEST_F()
1630 EXPECT_NE(N, DILexicalBlockFile::get(Context, getSubprogram(), File, in TEST_F()
1633 DILexicalBlockFile::get(Context, Scope, getFile(), Discriminator)); in TEST_F()
1635 DILexicalBlockFile::get(Context, Scope, File, Discriminator + 1)); in TEST_F()
1649 auto *N = DINamespace::get(Context, Scope, File, Name, Line); in TEST_F()
1656 EXPECT_EQ(N, DINamespace::get(Context, Scope, File, Name, Line)); in TEST_F()
1658 EXPECT_NE(N, DINamespace::get(Context, getFile(), File, Name, Line)); in TEST_F()
1659 EXPECT_NE(N, DINamespace::get(Context, Scope, getFile(), Name, Line)); in TEST_F()
1660 EXPECT_NE(N, DINamespace::get(Context, Scope, File, "other", Line)); in TEST_F()
1661 EXPECT_NE(N, DINamespace::get(Context, Scope, File, Name, Line + 1)); in TEST_F()
1676 auto *N = DIModule::get(Context, Scope, Name, ConfigMacro, Includes, Sysroot); in TEST_F()
1684 EXPECT_EQ(N, DIModule::get(Context, Scope, Name, in TEST_F()
1686 EXPECT_NE(N, DIModule::get(Context, getFile(), Name, in TEST_F()
1688 EXPECT_NE(N, DIModule::get(Context, Scope, "other", in TEST_F()
1690 EXPECT_NE(N, DIModule::get(Context, Scope, Name, in TEST_F()
1692 EXPECT_NE(N, DIModule::get(Context, Scope, Name, in TEST_F()
1694 EXPECT_NE(N, DIModule::get(Context, Scope, Name, in TEST_F()
1707 auto *N = DITemplateTypeParameter::get(Context, Name, Type); in TEST_F()
1712 EXPECT_EQ(N, DITemplateTypeParameter::get(Context, Name, Type)); in TEST_F()
1714 EXPECT_NE(N, DITemplateTypeParameter::get(Context, "other", Type)); in TEST_F()
1716 DITemplateTypeParameter::get(Context, Name, getBasicType("other"))); in TEST_F()
1730 auto *N = DITemplateValueParameter::get(Context, Tag, Name, Type, Value); in TEST_F()
1735 EXPECT_EQ(N, DITemplateValueParameter::get(Context, Tag, Name, Type, Value)); in TEST_F()
1738 Context, dwarf::DW_TAG_GNU_template_template_param, Name, in TEST_F()
1741 DITemplateValueParameter::get(Context, Tag, "other", Type, Value)); in TEST_F()
1742 EXPECT_NE(N, DITemplateValueParameter::get(Context, Tag, Name, in TEST_F()
1744 EXPECT_NE(N, DITemplateValueParameter::get(Context, Tag, Name, Type, in TEST_F()
1766 auto *N = DIGlobalVariable::get(Context, Scope, Name, LinkageName, File, Line, in TEST_F()
1780 EXPECT_EQ(N, DIGlobalVariable::get(Context, Scope, Name, LinkageName, File, in TEST_F()
1785 DIGlobalVariable::get(Context, getSubprogram(), Name, LinkageName, in TEST_F()
1788 EXPECT_NE(N, DIGlobalVariable::get(Context, Scope, "other", LinkageName, File, in TEST_F()
1791 EXPECT_NE(N, DIGlobalVariable::get(Context, Scope, Name, "other", File, Line, in TEST_F()
1795 DIGlobalVariable::get(Context, Scope, Name, LinkageName, getFile(), in TEST_F()
1799 DIGlobalVariable::get(Context, Scope, Name, LinkageName, File, in TEST_F()
1803 DIGlobalVariable::get(Context, Scope, Name, LinkageName, File, Line, in TEST_F()
1806 EXPECT_NE(N, DIGlobalVariable::get(Context, Scope, Name, LinkageName, File, in TEST_F()
1809 EXPECT_NE(N, DIGlobalVariable::get(Context, Scope, Name, LinkageName, File, in TEST_F()
1813 DIGlobalVariable::get(Context, Scope, Name, LinkageName, File, Line, in TEST_F()
1817 DIGlobalVariable::get(Context, Scope, Name, LinkageName, File, Line, in TEST_F()
1838 DILocalVariable::get(Context, Scope, Name, File, Line, Type, Arg, Flags); in TEST_F()
1847 EXPECT_EQ(N, DILocalVariable::get(Context, Scope, Name, File, Line, Type, Arg, in TEST_F()
1851 DILocalVariable::get(Context, Scope, Name, File, Line, Type, 0, Flags) in TEST_F()
1853 EXPECT_NE(N, DILocalVariable::get(Context, getSubprogram(), Name, File, Line, in TEST_F()
1855 EXPECT_NE(N, DILocalVariable::get(Context, Scope, "other", File, Line, Type, in TEST_F()
1857 EXPECT_NE(N, DILocalVariable::get(Context, Scope, Name, getFile(), Line, Type, in TEST_F()
1859 EXPECT_NE(N, DILocalVariable::get(Context, Scope, Name, File, Line + 1, Type, in TEST_F()
1861 EXPECT_NE(N, DILocalVariable::get(Context, Scope, Name, File, Line, in TEST_F()
1863 EXPECT_NE(N, DILocalVariable::get(Context, Scope, Name, File, Line, Type, in TEST_F()
1865 EXPECT_NE(N, DILocalVariable::get(Context, Scope, Name, File, Line, Type, Arg, in TEST_F()
1873 EXPECT_EQ(255u, DILocalVariable::get(Context, getSubprogram(), "", getFile(), in TEST_F()
1876 EXPECT_EQ(256u, DILocalVariable::get(Context, getSubprogram(), "", getFile(), in TEST_F()
1879 EXPECT_EQ(257u, DILocalVariable::get(Context, getSubprogram(), "", getFile(), in TEST_F()
1883 EXPECT_EQ(Max, DILocalVariable::get(Context, getSubprogram(), "", getFile(), in TEST_F()
1892 auto *N = DIExpression::get(Context, Elements); in TEST_F()
1894 EXPECT_EQ(N, DIExpression::get(Context, Elements)); in TEST_F()
1911 EXPECT_TRUE(DIExpression::get(Context, Elements)->isValid()); \ in TEST_F()
1916 EXPECT_FALSE(DIExpression::get(Context, Elements)->isValid()); \ in TEST_F()
1920 EXPECT_TRUE(DIExpression::get(Context, None)); in TEST_F()
1954 auto *N = DIObjCProperty::get(Context, Name, File, Line, GetterName, in TEST_F()
1965 EXPECT_EQ(N, DIObjCProperty::get(Context, Name, File, Line, GetterName, in TEST_F()
1968 EXPECT_NE(N, DIObjCProperty::get(Context, "other", File, Line, GetterName, in TEST_F()
1970 EXPECT_NE(N, DIObjCProperty::get(Context, Name, getFile(), Line, GetterName, in TEST_F()
1972 EXPECT_NE(N, DIObjCProperty::get(Context, Name, File, Line + 1, GetterName, in TEST_F()
1974 EXPECT_NE(N, DIObjCProperty::get(Context, Name, File, Line, "other", in TEST_F()
1976 EXPECT_NE(N, DIObjCProperty::get(Context, Name, File, Line, GetterName, in TEST_F()
1978 EXPECT_NE(N, DIObjCProperty::get(Context, Name, File, Line, GetterName, in TEST_F()
1980 EXPECT_NE(N, DIObjCProperty::get(Context, Name, File, Line, GetterName, in TEST_F()
1997 auto *N = DIImportedEntity::get(Context, Tag, Scope, Entity, Line, Name); in TEST_F()
2004 EXPECT_EQ(N, DIImportedEntity::get(Context, Tag, Scope, Entity, Line, Name)); in TEST_F()
2007 DIImportedEntity::get(Context, dwarf::DW_TAG_imported_declaration, in TEST_F()
2009 EXPECT_NE(N, DIImportedEntity::get(Context, Tag, getSubprogram(), Entity, in TEST_F()
2011 EXPECT_NE(N, DIImportedEntity::get(Context, Tag, Scope, getCompositeType(), in TEST_F()
2014 DIImportedEntity::get(Context, Tag, Scope, Entity, Line + 1, Name)); in TEST_F()
2016 DIImportedEntity::get(Context, Tag, Scope, Entity, Line, "other")); in TEST_F()
2025 MDNode *N = MDNode::get(Context, None); in TEST_F()
2026 auto *V = MetadataAsValue::get(Context, N); in TEST_F()
2030 auto *V2 = MetadataAsValue::get(Context, N); in TEST_F()
2035 MDNode *N = MDNode::get(Context, None); in TEST_F()
2037 MDNode *N2 = MDNode::get(Context, Ops); in TEST_F()
2038 auto *V = MetadataAsValue::get(Context, N2); in TEST_F()
2042 auto *V2 = MetadataAsValue::get(Context, N2); in TEST_F()
2045 auto *V3 = MetadataAsValue::get(Context, N); in TEST_F()
2052 auto *C = ConstantInt::getTrue(Context); in TEST_F()
2055 auto *N = MDNode::get(Context, Ops); in TEST_F()
2057 auto *V = MetadataAsValue::get(Context, MD); in TEST_F()
2061 auto *V2 = MetadataAsValue::get(Context, N); in TEST_F()
2069 Type *Ty = Type::getInt1PtrTy(Context); in TEST_F()
2085 ConstantAsMetadata::get(ConstantInt::get(Context, APInt(8, 0))); in TEST_F()
2087 auto Temp1 = MDTuple::getTemporary(Context, None); in TEST_F()
2088 auto Temp2 = MDTuple::getTemporary(Context, {CI}); in TEST_F()
2089 auto *N = MDTuple::get(Context, {Temp1.get()}); in TEST_F()
2102 ConstantAsMetadata::get(ConstantInt::get(Context, APInt(8, 0))); in TEST_F()
2105 auto Temp = MDTuple::getTemporary(Context, None); in TEST_F()
2111 auto *N1 = MDTuple::get(Context, Ops1); in TEST_F()
2112 auto *N2 = MDTuple::get(Context, Ops2); in TEST_F()
2130 Type *Ty = Type::getInt1PtrTy(Context); in TEST_F()
2147 Type *Ty = Type::getInt1PtrTy(Context); in TEST_F()
2159 LLVMContext Context; in TEST() local
2161 ConstantAsMetadata::get(ConstantInt::get(Type::getInt32Ty(Context), 1)); in TEST()
2163 ConstantAsMetadata::get(ConstantInt::get(Type::getInt32Ty(Context), 2)); in TEST()
2167 MDNode *n = MDNode::get(Context, V); in TEST()
2168 MDNode *n2 = MDNode::get(Context, V2); in TEST()
2170 Module M("MyModule", Context); in TEST()
2256 EXPECT_EQ(Context.getMDKindID("other1"), MDs[2].first); in TEST_F()
2257 EXPECT_EQ(Context.getMDKindID("other2"), MDs[3].first); in TEST_F()
2281 (void)new UnreachableInst(Context, BasicBlock::Create(Context, "bb", F)); in TEST_F()
2317 auto *D = MDTuple::getDistinct(Context, Ops); in TEST_F()
2323 auto *N0 = MDTuple::get(Context, None); in TEST_F()
2324 auto *N1 = MDTuple::get(Context, N0); in TEST_F()
2335 DistinctMDOperandPlaceholder(7).replaceUseWith(MDTuple::get(Context, None)); in TEST_F()
2343 EXPECT_DEATH(MetadataAsValue::get(Context, &PH), in TEST_F()
2350 EXPECT_DEATH(MDTuple::get(Context, &PH), "Unexpected callback to owner"); in TEST_F()
2356 MDTuple::getDistinct(Context, &PH); in TEST_F()
2357 EXPECT_DEATH(MDTuple::getDistinct(Context, &PH), in TEST_F()
2370 MDTuple::getDistinct(Context, &PH); in TEST_F()
2376 EXPECT_DEATH(MDTuple::getDistinct(Context, &PH), in TEST_F()