37 device_index(
const std::string &backend_name, std::size_t device_id);
89 lhs.get_backend_name() == rhs.get_backend_name();
95 return lhs.get_device_id() != rhs.get_device_id() ||
96 lhs.get_backend_name() != rhs.get_backend_name();
100 operator<(
const device_index &lhs,
const device_index &rhs)
noexcept
102 if (lhs.get_backend_name() < rhs.get_backend_name())
106 else if(lhs.get_backend_name() == rhs.get_backend_name())
108 return lhs.get_device_id() < rhs.get_device_id();
114 operator<=(
const device_index &lhs,
const device_index &rhs)
noexcept
116 if (lhs.get_backend_name() < rhs.get_backend_name())
120 else if(lhs.get_backend_name() == rhs.get_backend_name())
122 return lhs.get_device_id() <= rhs.get_device_id();
128 operator>(
const device_index &lhs,
const device_index &rhs)
noexcept
134 operator>=(
const device_index &lhs,
const device_index &rhs)
noexcept
140 operator<<(std::ostream &os,
const device_index &index)
142 return os << index.get_backend_name() <<
':' << index.get_device_id();
146 std::string m_backend_name;
147 std::size_t m_device_id;
Arrays, the operations on them and the devices that run those operations.
Definition cpu_device.hpp:10