Home
last modified time | relevance | path

Searched refs:Map (Results 1 – 25 of 430) sorted by relevance

12345678910>>...18

/llvm-project/llvm/unittests/ADT/
H A DDenseMapTest.cpp95 T Map; member in __anon95dc29540111::DenseMapTest
132 EXPECT_EQ(0u, this->Map.size()); in TYPED_TEST()
133 EXPECT_TRUE(this->Map.empty()); in TYPED_TEST()
136 EXPECT_TRUE(this->Map.begin() == this->Map.end()); in TYPED_TEST()
139 EXPECT_FALSE(this->Map.count(this->getKey())); in TYPED_TEST()
140 EXPECT_FALSE(this->Map.contains(this->getKey())); in TYPED_TEST()
141 EXPECT_TRUE(this->Map.find(this->getKey()) == this->Map.end()); in TYPED_TEST()
143 this->Map.lookup(this->getKey())); in TYPED_TEST()
148 const TypeParam &ConstMap = this->Map; in TYPED_TEST()
156 this->Map[this->getKey()] = this->getValue(); in TYPED_TEST()
[all …]
H A DStringMapTest.cpp165 llvm::StringMap<int> Map(2); in TEST_F() local
167 Map["eins"] = 1; in TEST_F()
168 Map["zwei"] = 2; in TEST_F()
169 Map["drei"] = 3; in TEST_F()
170 Map.erase("drei"); in TEST_F()
171 Map.erase("eins"); in TEST_F()
172 Map["veir"] = 4; in TEST_F()
173 Map["funf"] = 5; in TEST_F()
175 EXPECT_EQ(3u, Map.size()); in TEST_F()
176 EXPECT_EQ(0, Map in TEST_F()
184 llvm::StringMap<int> Map; TEST_F() local
211 llvm::StringMap<int> Map; TEST_F() local
327 StringMap<int> Map; TEST_F() local
341 StringMap<int> Map; TEST_F() local
588 StringMap<CountCtorCopyAndMove> Map(Size); TEST() local
606 StringMap<CountCtorCopyAndMove> Map; TEST() local
628 StringMap<NonMoveableNonCopyableType> Map; TEST() local
[all...]
/llvm-project/lldb/unittests/Utility/
H A DRangeMapTest.cpp133 RangeDataVectorT Map; in TEST()
135 Map.Append(EntryT(0, 10, NextID++)); in TEST()
136 Map.Append(EntryT(10, 10, NextID++)); in TEST()
137 Map.Append(EntryT(20, 10, NextID++)); in TEST()
138 Map.Sort(); in TEST()
140 EXPECT_THAT(Map.FindEntryThatContains(0), EntryIs(0)); in TEST()
141 EXPECT_THAT(Map.FindEntryThatContains(9), EntryIs(0)); in TEST()
142 EXPECT_THAT(Map.FindEntryThatContains(10), EntryIs(1));
143 EXPECT_THAT(Map.FindEntryThatContains(19), EntryIs(1)); in TEST()
144 EXPECT_THAT(Map in TEST()
110 RangeDataVectorT Map; TEST() local
127 RangeDataVectorT Map; TEST() local
145 auto Map = RangeDataVectorT(); TEST() local
186 RangeDataVectorT Map; TEST() local
202 RangeDataVectorT Map; TEST() local
[all...]
/llvm-project/compiler-rt/lib/sanitizer_common/tests/
H A Dsanitizer_dense_map_test.cpp105 T Map; member in __anon65fcc02b0111::DenseMapTest
133 EXPECT_EQ(0u, this->Map.size()); in TYPED_TEST()
134 EXPECT_TRUE(this->Map.empty()); in TYPED_TEST()
137 EXPECT_FALSE(this->Map.count(this->getKey())); in TYPED_TEST()
138 EXPECT_EQ(nullptr, this->Map.find(this->getKey())); in TYPED_TEST()
140 this->Map.lookup(this->getKey())); in TYPED_TEST()
145 const TypeParam &ConstMap = this->Map; in TYPED_TEST()
152 this->Map[this->getKey()] = this->getValue(); in TYPED_TEST()
155 EXPECT_EQ(1u, this->Map.size()); in TYPED_TEST()
156 EXPECT_FALSE(this->Map.empty()); in TYPED_TEST()
[all …]
/llvm-project/polly/utils/pyscop/
H A Disl.py145 class Map(IslObject): class
150 return Map(ptr=ptr)
264 ("is_empty", Map, [Map], c_int),
267 # ("is_universe", Map, [Map], c_int),
268 ("is_single_valued", Map, [Map], c_int),
269 ("is_bijective", Map, [Map], c_in
[all...]
/llvm-project/libcxx/benchmarks/
H A Dmap.bench.cpp
/llvm-project/llvm/unittests/Target/DirectX/
H A DPointerTypeAnalysisTests.cpp45 PointerTypeMap Map = PointerTypeAnalysis::run(*M); in TEST() local
46 ASSERT_EQ(Map.size(), 2u); in TEST()
50 EXPECT_THAT(Map, in TEST()
52 EXPECT_THAT(Map, Contains(Pair(IsA<Argument>(), I8Ptr))); in TEST()
68 PointerTypeMap Map = PointerTypeAnalysis::run(*M); in TEST() local
69 ASSERT_EQ(Map.size(), 2u); in TEST()
73 EXPECT_THAT(Map, in TEST()
75 EXPECT_THAT(Map, Contains(Pair(IsA<Argument>(), I32Ptr))); in TEST()
91 PointerTypeMap Map = PointerTypeAnalysis::run(*M); in TEST() local
92 ASSERT_EQ(Map.size(), 2u); in TEST()
[all …]
/llvm-project/llvm/lib/Target/DirectX/DirectXIRPasses/
H A DPointerTypeAnalysis.cpp26 Type *classifyPointerType(const Value *V, PointerTypeMap &Map) { in classifyPointerType() argument
29 auto It = Map.find(V); in classifyPointerType()
30 if (It != Map.end()) in classifyPointerType()
60 PointeeTy = classifyPointerType(User, Map); in classifyPointerType()
75 Map[V] = TypedPtrTy; in classifyPointerType()
82 Type *classifyFunctionType(const Function &F, PointerTypeMap &Map) { in classifyFunctionType() argument
83 auto It = Map.find(&F); in classifyFunctionType()
84 if (It != Map.end()) in classifyFunctionType()
97 Type *NewRetTy = classifyPointerType(RetInst->getReturnValue(), Map); in classifyFunctionType()
112 ArgTy = classifyPointerType(&A, Map); in classifyFunctionType()
[all …]
/llvm-project/llvm/utils/TableGen/Common/
H A DInfoByHwMode.h94 InfoByHwMode(const MapType &M) : Map(M) {} in InfoByHwMode()
97 iterator begin() { return Map.begin(); } in begin()
99 iterator end() { return Map.end(); } in end()
101 const_iterator begin() const { return Map.begin(); } in begin()
103 const_iterator end() const { return Map.end(); } in end()
105 bool empty() const { return Map.empty(); } in empty()
108 bool hasMode(unsigned M) const { return Map.find(M) != Map.end(); } in hasMode()
111 return !Map.empty() && Map in hasDefault()
[all...]
H A DInfoByHwMode.cpp35 auto I = Map.insert({P.first, MVT(llvm::getValueType(P.second))}); in ValueTypeByHwMode()
57 return Map == T.Map;
63 return Map < T.Map;
67 auto F = Map.find(Mode); in getOrCreateTypeForMode()
68 if (F != Map.end()) in getOrCreateTypeForMode()
72 auto D = Map.begin(); in getOrCreateTypeForMode()
73 if (D != Map.end() && D->first == DefaultMode) in getOrCreateTypeForMode()
74 return Map in getOrCreateTypeForMode()
[all...]
/llvm-project/llvm/include/llvm/IR/
H A DValueMap.h92 MapT Map; variable
103 : Map(NumInitBuckets), Data() {} in Map() function
105 : Map(NumInitBuckets), Data(Data) {} in Map() function
134 inline iterator begin() { return iterator(Map.begin()); } in begin()
135 inline iterator end() { return iterator(Map.end()); } in end()
136 inline const_iterator begin() const { return const_iterator(Map.begin()); } in begin()
137 inline const_iterator end() const { return const_iterator(Map.end()); } in end()
139 bool empty() const { return Map.empty(); } in empty()
140 size_type size() const { return Map.size(); } in size()
143 void reserve(size_t Size) { Map.reserve(Size); } in reserve()
[all …]
/llvm-project/llvm/unittests/Analysis/
H A DAssumeBundleQueriesTest.cpp224 static bool FindExactlyAttributes(RetainedKnowledgeMap &Map, Value *WasOn, in FindExactlyAttributes() argument
235 if (ShouldHaveAttr != (Map.contains(RetainedKnowledgeKey{ in FindExactlyAttributes()
242 static bool MapHasRightValue(RetainedKnowledgeMap &Map, AssumeInst *II, in MapHasRightValue() argument
244 auto LookupIt = Map.find(Key); in MapHasRightValue()
245 return (LookupIt != Map.end()) && (LookupIt->second[II].Min == MM.Min) && in MapHasRightValue()
269 RetainedKnowledgeMap Map; in TEST() local
270 fillMapFromAssume(*Assume, Map); in TEST()
271 ASSERT_TRUE(FindExactlyAttributes(Map, I->getOperand(0), in TEST()
273 ASSERT_FALSE(FindExactlyAttributes(Map, I->getOperand(1), in TEST()
275 ASSERT_TRUE(FindExactlyAttributes(Map, in TEST()
294 RetainedKnowledgeMap Map; TEST() local
317 RetainedKnowledgeMap Map; TEST() local
326 RetainedKnowledgeMap Map; TEST() local
342 RetainedKnowledgeMap Map; TEST() local
379 RetainedKnowledgeMap Map; TEST() local
398 RetainedKnowledgeMap Map; TEST() local
471 RetainedKnowledgeMap Map; RunRandTest() local
[all...]
/llvm-project/lldb/unittests/Core/
H A DUniqueCStringMapTest.cpp36 MapT Map; in TEST() local
39 Map.Append(Foo, NoDefault(42)); in TEST()
40 EXPECT_THAT(Map.Find(Foo, NoDefault(47)), NoDefault(42)); in TEST()
41 EXPECT_THAT(Map.Find(Bar, NoDefault(47)), NoDefault(47)); in TEST()
42 EXPECT_THAT(Map.FindFirstValueForName(Foo), in TEST()
44 EXPECT_THAT(Map.FindFirstValueForName(Bar), nullptr); in TEST()
47 EXPECT_THAT(Map.GetValues(Foo, Values), 1); in TEST()
51 EXPECT_THAT(Map.GetValues(Bar, Values), 0); in TEST()
56 UniqueCStringMap<int> Map; in TEST() local
60 Map.Append(Foo, 0); in TEST()
[all …]
/llvm-project/llvm/unittests/Testing/ADT/
H A DStringMapTest.cpp20 StringMap<int> Map; in TEST() local
21 Map["A"] = 42; in TEST()
22 Map["Z"] = 35; in TEST()
23 Map["B"] = 7; in TEST()
24 OS << Map; in TEST()
35 StringMap<StringMap<int>> Map; in TEST() local
36 Map["Z"]; in TEST()
37 Map["A"]["Apple"] = 5; in TEST()
38 Map["B"]["Bee"] = 3; in TEST()
39 Map["A"]["Axe"] = 3; in TEST()
[all …]
H A DStringMapEntryTest.cpp42 llvm::StringMap<int> Map = {{"A", 1}}; in TEST() local
43 EXPECT_THAT(*Map.find("A"), IsStringMapEntry("A", 1)); in TEST()
47 llvm::StringMap<int> Map = {{"A", 1}}; in TEST() local
48 EXPECT_THAT(*Map.find("A"), IsStringMapEntry(StrCaseEq("a"), Gt(0))); in TEST()
52 llvm::StringMap<int> Map = {{"A", 1}, {"B", 2}}; in TEST() local
53 EXPECT_THAT(Map, UnorderedElementsAre(IsStringMapEntry("A", 1), in TEST()
68 llvm::StringMap<int> Map = {{"A", 1}}; in TEST() local
70 EXPECT_EQ(R"(which is a match)", ExplainMatch(M, *Map.find("A"))); in TEST()
74 llvm::StringMap<int> Map = {{"B", 1}}; in TEST() local
77 ExplainMatch(M, *Map.find("B"))); in TEST()
[all …]
/llvm-project/llvm/lib/Transforms/ObjCARC/
H A DBlotMapVector.h25 MapTy Map; variable
34 assert(Vector.size() >= Map.size()); // May differ due to blotting. in ~BlotMapVector()
35 for (typename MapTy::const_iterator I = Map.begin(), E = Map.end(); I != E; in ~BlotMapVector()
42 assert(!I->first || (Map.count(I->first) && in ~BlotMapVector()
43 Map[I->first] == size_t(I - Vector.begin()))); in ~BlotMapVector()
57 Map.insert(std::make_pair(Arg, size_t(0)));
69 Map.insert(std::make_pair(InsertPair.first, size_t(0))); in insert()
80 typename MapTy::iterator It = Map.find(Key); in find()
81 if (It == Map.end()) in find()
87 typename MapTy::const_iterator It = Map.find(Key); in find()
[all …]
/llvm-project/bolt/include/bolt/Profile/
H A DBoltAddressTranslation.h55 /// Example translation Map for function foo
135 /// Helper to update \p Map by inserting one or more BAT entries reflecting
139 void writeEntriesForBB(MapTy &Map, const BinaryBasicBlock &BB,
154 APInt calculateBranchEntriesBitMask(MapTy &Map, size_t EqualElems) const;
158 size_t getNumEqualOffsets(const MapTy &Map, uint32_t Skew) const;
165 /// Map a function to its basic blocks count
168 /// Map a function to its secondary entry points vector
186 /// Map basic block input offset to a basic block index and hash pair.
193 std::map<uint32_t, EntryTy> Map; in getEntry()
195 auto It = Map in getEntry()
192 std::map<uint32_t, EntryTy> Map; global() variable
231 std::unordered_map<uint64_t, EntryTy> Map; global() variable
[all...]
/llvm-project/libcxx/test/std/containers/associative/
H A Diterator_types.pass.cpp18 template <class Map, class ValueTp, class PtrT, class CPtrT>
20 typedef typename Map::difference_type Diff; in testMap()
22 typedef typename Map::iterator It; in testMap()
29 typedef typename Map::const_iterator It; in testMap()
55 typedef std::map<int, int> Map; in main() typedef
57 testMap<Map, ValueTp, ValueTp*, ValueTp const*>(); in main()
62 typedef std::map<int, int, std::less<int>, Alloc> Map; in main() typedef
63 testMap<Map, ValueTp, ValueTp*, ValueTp const*>(); in main()
69 typedef std::map<int, int, std::less<int>, Alloc> Map; in main() typedef
70 testMap<Map, ValueTp, min_pointer<ValueTp>, min_pointer<const ValueTp>>(); in main()
[all …]
/llvm-project/clang/include/clang/StaticAnalyzer/Core/PathSensitive/
H A DFunctionSummary.h57 MapTy Map; variable
61 MapTy::iterator I = Map.find(D); in findOrInsertSummary()
62 if (I != Map.end()) in findOrInsertSummary()
67 I = Map.insert(KVPair(D, FunctionSummary())).first; in findOrInsertSummary()
68 assert(I != Map.end()); in findOrInsertSummary()
89 MapTy::const_iterator I = Map.find(D); in mayInline()
90 if (I != Map.end() && I->second.InlineChecked) in mayInline()
107 MapTy::const_iterator I = Map.find(D); in getNumVisitedBasicBlocks()
108 if (I != Map.end()) in getNumVisitedBasicBlocks()
114 MapTy::const_iterator I = Map.find(D); in getNumTimesInlined()
[all …]
/llvm-project/libcxx/test/std/containers/unord/
H A Diterator_difference_type.pass.cpp18 template <class Map, class ValueTp, class PtrT, class CPtrT>
20 typedef typename Map::difference_type Diff; in testUnorderedMap()
22 typedef typename Map::iterator It; in testUnorderedMap()
29 typedef typename Map::const_iterator It; in testUnorderedMap()
36 typedef typename Map::local_iterator It; in testUnorderedMap()
43 typedef typename Map::const_local_iterator It; in testUnorderedMap()
78 typedef std::unordered_map<int, int> Map; in main() typedef
80 testUnorderedMap<Map, ValueTp, ValueTp*, ValueTp const*>(); in main()
85 typedef std::unordered_map<int, int, std::hash<int>, std::equal_to<int>, Alloc> Map; in main() typedef
86 testUnorderedMap<Map, ValueTp, ValueTp*, ValueTp const*>(); in main()
[all …]
/llvm-project/llvm/include/llvm/ADT/
H A DMapVector.h37 MapType Map; variable
56 Map.clear(); in takeVector()
65 Map.reserve(NumEntries); in reserve()
89 Map.clear(); in clear()
94 std::swap(Map, RHS.Map); in swap()
100 std::pair<typename MapType::iterator, bool> Result = Map.insert(Pair);
113 typename MapType::const_iterator Pos = Map.find(Key); in lookup()
114 return Pos == Map.end()? ValueT() : Vector[Pos->second].second; in lookup()
119 auto [It, Inserted] = Map.insert(std::make_pair(Key, 0)); in try_emplace()
130 auto [It, Inserted] = Map.insert(std::make_pair(Key, 0)); in try_emplace()
[all …]
/llvm-project/llvm/include/llvm/CodeGen/
H A DRDFRegisters.h54 IndexedSet() { Map.reserve(N); } in IndexedSet()
58 assert(Idx != 0 && !Map.empty() && Idx - 1 < Map.size()); in get()
59 return Map[Idx - 1]; in get()
64 auto F = llvm::find(Map, Val); in insert()
65 if (F != Map.end()) in insert()
66 return F - Map.begin() + 1; in insert()
67 Map.push_back(Val); in insert()
68 return Map.size(); // Return actual_index + 1. in insert()
72 auto F = llvm::find(Map, Val); in find()
73 assert(F != Map.end()); in find()
[all …]
/llvm-project/compiler-rt/lib/scudo/standalone/tests/
H A Dbytemap_test.cpp16 template <typename T> void testMap(T &Map, scudo::uptr Size) { in testMap() argument
17 Map.init(); in testMap()
19 Map.set(I, (I % 100) + 1); in testMap()
22 EXPECT_EQ(Map[J], 0); in testMap()
24 EXPECT_EQ(Map[J], (J % 100) + 1); in testMap()
30 scudo::FlatByteMap<Size> Map; in TEST() local
31 testMap(Map, Size); in TEST()
32 Map.unmapTestOnly(); in TEST()
/llvm-project/clang/include/clang/AST/
H A DDeclLookups.h79 if (StoredDeclsMap *Map = Primary->buildLookup()) in lookups() local
80 return lookups_range(all_lookups_iterator(Map->begin(), Map->end()), in lookups()
81 all_lookups_iterator(Map->end(), Map->end())); in lookups()
93 if (StoredDeclsMap *Map = Primary->getLookupPtr()) in noload_lookups() local
94 return lookups_range(all_lookups_iterator(Map->begin(), Map->end()), in noload_lookups()
95 all_lookups_iterator(Map->end(), Map->end())); in noload_lookups()
/llvm-project/llvm/unittests/Support/
H A DReverseIterationTest.cpp36 DenseMap<int, int> Map; in TEST() local
41 Map[Key] = 0; in TEST()
49 for (auto Tuple : zip(Map, IterKeys)) in TEST()
54 for (auto iter = Map.begin(), end = Map.end(); iter != end; iter++, ++i) in TEST()
93 DenseMap<PtrLikeInt *, int> Map; in TEST() local
95 Map[Key] = Key->value; in TEST()
103 for (auto Tuple : zip(Map, Keys)) in TEST()
108 for (auto iter = Map.begin(), end = Map.end(); iter != end; iter++, ++i) in TEST()

12345678910>>...18