Class SmallMapBaseObj#
Defined in File map_base.h
Inheritance Relationships#
Base Type#
public tvm::ffi::MapBaseObj(Class MapBaseObj)
Class Documentation#
-
class SmallMapBaseObj : public tvm::ffi::MapBaseObj#
A specialization of small-sized hash map.
Public Functions
-
inline uint64_t NumSlots() const#
Return the number of usable slots for Small layout (mask off tag).
- Returns:
The number of usable slots
-
inline ~SmallMapBaseObj()#
-
inline void clear()#
clear all entries
-
inline size_t count(const key_type &key) const#
Count the number of times a key exists in the SmallMapBaseObj.
- Parameters:
key – The indexing key
- Returns:
The result, 0 or 1
-
inline const mapped_type &at(const key_type &key) const#
Index value associated with a key, throw exception if the key does not exist.
- Parameters:
key – The indexing key
- Returns:
The const reference to the value
-
inline mapped_type &at(const key_type &key)#
Index value associated with a key, throw exception if the key does not exist.
- Parameters:
key – The indexing key
- Returns:
The mutable reference to the value
-
inline iterator begin() const#
- Returns:
begin iterator
-
inline iterator end() const#
- Returns:
end iterator
-
inline iterator find(const key_type &key) const#
Index value associated with a key.
- Parameters:
key – The indexing key
- Returns:
The iterator of the entry associated with the key, end iterator if not exists
-
inline void erase(const iterator &position)#
Erase the entry associated with the iterator.
- Parameters:
position – The iterator
Friends
- friend class MapBaseObj
- friend class DenseMapBaseObj
-
inline uint64_t NumSlots() const#