mirror of
https://github.com/ml-explore/mlx.git
synced 2025-08-09 18:56:39 +08:00
Fix build warning (#2033)
This commit is contained in:
parent
f98ce25ab9
commit
c23888acd7
@ -17,7 +17,7 @@ struct ScalarT<float16_t, N> {
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
template <>
|
template <>
|
||||||
static constexpr int max_size<float16_t> = N;
|
inline constexpr int max_size<float16_t> = N;
|
||||||
|
|
||||||
#define SIMD_FP16_DEFAULT_UNARY(op) \
|
#define SIMD_FP16_DEFAULT_UNARY(op) \
|
||||||
template <> \
|
template <> \
|
||||||
|
@ -83,25 +83,25 @@ struct Simd {
|
|||||||
// Values chosen based on benchmarks on M3 Max
|
// Values chosen based on benchmarks on M3 Max
|
||||||
// TODO: consider choosing these more optimally
|
// TODO: consider choosing these more optimally
|
||||||
template <>
|
template <>
|
||||||
static constexpr int max_size<int8_t> = 16;
|
inline constexpr int max_size<int8_t> = 16;
|
||||||
template <>
|
template <>
|
||||||
static constexpr int max_size<int16_t> = 16;
|
inline constexpr int max_size<int16_t> = 16;
|
||||||
template <>
|
template <>
|
||||||
static constexpr int max_size<int> = 8;
|
inline constexpr int max_size<int> = 8;
|
||||||
template <>
|
template <>
|
||||||
static constexpr int max_size<int64_t> = 4;
|
inline constexpr int max_size<int64_t> = 4;
|
||||||
template <>
|
template <>
|
||||||
static constexpr int max_size<uint8_t> = 16;
|
inline constexpr int max_size<uint8_t> = 16;
|
||||||
template <>
|
template <>
|
||||||
static constexpr int max_size<uint16_t> = 16;
|
inline constexpr int max_size<uint16_t> = 16;
|
||||||
template <>
|
template <>
|
||||||
static constexpr int max_size<uint32_t> = 8;
|
inline constexpr int max_size<uint32_t> = 8;
|
||||||
template <>
|
template <>
|
||||||
static constexpr int max_size<uint64_t> = 4;
|
inline constexpr int max_size<uint64_t> = 4;
|
||||||
template <>
|
template <>
|
||||||
static constexpr int max_size<float> = 8;
|
inline constexpr int max_size<float> = 8;
|
||||||
template <>
|
template <>
|
||||||
static constexpr int max_size<double> = 4;
|
inline constexpr int max_size<double> = 4;
|
||||||
|
|
||||||
#define SIMD_DEFAULT_UNARY(name, op) \
|
#define SIMD_DEFAULT_UNARY(name, op) \
|
||||||
template <typename T, int N> \
|
template <typename T, int N> \
|
||||||
|
Loading…
Reference in New Issue
Block a user