Lines Matching refs:G
23 LinkGraph G("foo", 8, support::little); in TEST() local
24 EXPECT_EQ(G.getName(), "foo"); in TEST()
25 EXPECT_EQ(G.getPointerSize(), 8U); in TEST()
26 EXPECT_EQ(G.getEndianness(), support::little); in TEST()
27 EXPECT_TRUE(llvm::empty(G.external_symbols())); in TEST()
28 EXPECT_TRUE(llvm::empty(G.absolute_symbols())); in TEST()
29 EXPECT_TRUE(llvm::empty(G.defined_symbols())); in TEST()
30 EXPECT_TRUE(llvm::empty(G.blocks())); in TEST()
41 LinkGraph G("foo", 8, support::little); in TEST() local
42 auto &Sec1 = G.createSection("__data.1", RWFlags); in TEST()
43 auto &B1 = G.createContentBlock(Sec1, BlockContent, 0x1000, 8, 0); in TEST()
44 auto &B2 = G.createContentBlock(Sec1, BlockContent, 0x2000, 8, 0); in TEST()
45 auto &S1 = G.addDefinedSymbol(B1, 0, "S1", 4, Linkage::Strong, Scope::Default, in TEST()
47 auto &S2 = G.addDefinedSymbol(B2, 4, "S2", 4, Linkage::Strong, Scope::Default, in TEST()
50 auto &Sec2 = G.createSection("__data.1", RWFlags); in TEST()
51 auto &B3 = G.createContentBlock(Sec2, BlockContent, 0x3000, 8, 0); in TEST()
52 auto &B4 = G.createContentBlock(Sec2, BlockContent, 0x4000, 8, 0); in TEST()
53 auto &S3 = G.addDefinedSymbol(B3, 0, "S3", 4, Linkage::Strong, Scope::Default, in TEST()
55 auto &S4 = G.addDefinedSymbol(B4, 4, "S4", 4, Linkage::Strong, Scope::Default, in TEST()
69 EXPECT_EQ(std::distance(G.blocks().begin(), G.blocks().end()), 4); in TEST()
70 EXPECT_TRUE(llvm::count(G.blocks(), &B1)); in TEST()
71 EXPECT_TRUE(llvm::count(G.blocks(), &B2)); in TEST()
72 EXPECT_TRUE(llvm::count(G.blocks(), &B3)); in TEST()
73 EXPECT_TRUE(llvm::count(G.blocks(), &B4)); in TEST()
78 std::distance(G.defined_symbols().begin(), G.defined_symbols().end()), 4); in TEST()
79 EXPECT_TRUE(llvm::count(G.defined_symbols(), &S1)); in TEST()
80 EXPECT_TRUE(llvm::count(G.defined_symbols(), &S2)); in TEST()
81 EXPECT_TRUE(llvm::count(G.defined_symbols(), &S3)); in TEST()
82 EXPECT_TRUE(llvm::count(G.defined_symbols(), &S4)); in TEST()
93 LinkGraph G("foo", 8, support::little); in TEST() local
94 auto &Sec = G.createSection("__data", RWFlags); in TEST()
97 auto &B1 = G.createContentBlock(Sec, BlockContent, 0x1000, 8, 0); in TEST()
100 auto &S1 = G.addDefinedSymbol(B1, 0, "S1", 4, Linkage::Strong, Scope::Default, in TEST()
102 auto &S2 = G.addDefinedSymbol(B1, 4, "S2", 4, Linkage::Strong, Scope::Default, in TEST()
104 auto &S3 = G.addDefinedSymbol(B1, 8, "S3", 4, Linkage::Strong, Scope::Default, in TEST()
106 auto &S4 = G.addDefinedSymbol(B1, 12, "S4", 4, Linkage::Strong, in TEST()
111 auto &EB = G.createContentBlock(Sec, BlockContent, 0x2000, 8, 0); in TEST()
112 auto &ES1 = G.addDefinedSymbol(EB, 0, "TS1", 4, Linkage::Strong, in TEST()
114 auto &ES2 = G.addDefinedSymbol(EB, 4, "TS2", 4, Linkage::Strong, in TEST()
116 auto &ES3 = G.addDefinedSymbol(EB, 8, "TS3", 4, Linkage::Strong, in TEST()
118 auto &ES4 = G.addDefinedSymbol(EB, 12, "TS4", 4, Linkage::Strong, in TEST()
128 auto &B2 = G.splitBlock(B1, 8); in TEST()