Skip to content

Commit bdfead3

Browse files
committed
Slowly converting mim from RIOT
1 parent 4babddc commit bdfead3

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

57 files changed

+2153
-1122
lines changed

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
MIT License
22

3-
Copyright (c) 2022 Ian Pike & Contributors
3+
Copyright (c) 2022-2023 Ian Pike & Contributors
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

header_list.cmake

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,17 @@ set(mim_detail_headers
8484
include/mim/detail/qualifier.hpp
8585
)
8686

87+
set(mim_internal_config_headers
88+
include/mim/internal/config/architecture.hpp
89+
include/mim/internal/config/compiler.hpp
90+
include/mim/internal/config/compiler_features.hpp
91+
include/mim/internal/config/compiler_traits.hpp
92+
include/mim/internal/config/platform.hpp
93+
)
94+
8795
set(mim_internal_headers
96+
${mim_internal_config_headers}
97+
8898
include/mim/internal/float16compressor.hpp
8999
include/mim/internal/functionpacker.hpp
90100
include/mim/internal/functionpacker.inl

include/mim/detail/qualifier.hpp

Lines changed: 27 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
1-
// Copyright WizWorks, Inc. All Rights Reserved.
1+
// Copyright (c) 2023-Present Mim contributors (see LICENSE)
22

33
#pragma once
44

5-
#include "system/core.hpp"
6-
#include "math/internal/setup.hpp"
7-
#include "math/simd/simdSetup.hpp"
5+
#include "mim/internal/setup.hpp"
6+
#include "mim/simd/simdSetup.hpp"
87

98
namespace mim
109
{
@@ -15,7 +14,7 @@ namespace mim
1514
packed_mediump,
1615
packed_lowp,
1716

18-
#if defined(RIOT_SIMD)
17+
#if defined(MIM_SIMD)
1918
aligned_highp,
2019
aligned_mediump,
2120
aligned_lowp,
@@ -27,7 +26,7 @@ namespace mim
2726
lowp = packed_lowp,
2827
packed = packed_highp,
2928

30-
#if defined(RIOT_SIMD)
29+
#if MIM_SIMD
3130
defaultp = aligned_highp,
3231
#else
3332
defaultp = packed_highp,
@@ -42,27 +41,27 @@ namespace mim
4241

4342
namespace detail
4443
{
45-
template <riot::qualifier P>
44+
template <qualifier P>
4645
struct IsAligned
4746
{
4847
static const bool value = false;
4948
};
5049

51-
#if RIOT_SIMD
50+
#if MIM_SIMD
5251
template <>
53-
struct IsAligned<riot::aligned_highp>
52+
struct IsAligned<aligned_highp>
5453
{
5554
static const bool value = true;
5655
};
5756

5857
template <>
59-
struct IsAligned<riot::aligned_mediump>
58+
struct IsAligned<aligned_mediump>
6059
{
6160
static const bool value = true;
6261
};
6362

6463
template <>
65-
struct IsAligned<riot::aligned_lowp>
64+
struct IsAligned<aligned_lowp>
6665
{
6766
static const bool value = true;
6867
};
@@ -77,7 +76,7 @@ namespace mim
7776
};
7877
};
7978

80-
#if !defined(RIOT_COMPILER_NO_ALIGNOF)
79+
#if !defined(MIM_COMPILER_NO_ALIGNOF)
8180
template<size_t S, typename T>
8281
struct Storage<S, T, true>
8382
{
@@ -97,82 +96,82 @@ namespace mim
9796
};
9897
#endif
9998

100-
#if RIOT_SIMD_SSE2
99+
#if MIM_SIMD_SSE2
101100

102101
template<>
103102
struct Storage<4, float, true>
104103
{
105-
using type = riot_f32vec4;
104+
using type = MIM_f32vec4;
106105
};
107106

108107
template<>
109108
struct Storage<4, int32_t, true>
110109
{
111-
using type = riot_i32vec4;
110+
using type = MIM_i32vec4;
112111
};
113112

114113
template<>
115114
struct Storage<4, uint32_t, true>
116115
{
117-
using type = riot_u32vec4;
116+
using type = MIM_u32vec4;
118117
};
119118

120119
template<>
121120
struct Storage<2, double, true>
122121
{
123-
using type = riot_f32vec2;
122+
using type = MIM_f32vec2;
124123
};
125124

126125
template<>
127126
struct Storage<2, int64_t, true>
128127
{
129-
using type = riot_i64vec2;
128+
using type = MIM_i64vec2;
130129
};
131130

132131
template<>
133132
struct Storage<2, uint64_t, true>
134133
{
135-
using type = riot_u64vec2;
134+
using type = MIM_u64vec2;
136135
};
137136
#endif
138-
#if RIOT_SIMD_AVX
137+
#if MIM_SIMD_AVX
139138
template<>
140139
struct Storage<4, double, true>
141140
{
142-
using type = riot_f64vec4;
141+
using type = MIM_f64vec4;
143142
};
144143
#endif
145-
#if RIOT_SIMD_AVX2
144+
#if MIM_SIMD_AVX2
146145
template<>
147146
struct Storage<4, int64_t, true>
148147
{
149-
using type = riot_i64vec4;
148+
using type = MIM_i64vec4;
150149
};
151150

152151
template<>
153152
struct Storage<4, uint64_t, true>
154153
{
155-
using type = riot_u64vec4;
154+
using type = MIM_u64vec4;
156155
};
157156
#endif
158-
#if RIOT_SIMD_NEON
157+
#if MIM_SIMD_NEON
159158

160159
template<>
161160
struct Storage<4, float, true>
162161
{
163-
using type = riot_f32vec4;
162+
using type = MIM_f32vec4;
164163
};
165164

166165
template<>
167166
struct Storage<4, int32_t, true>
168167
{
169-
using type = riot_i32vec4;
168+
using type = MIM_i32vec4;
170169
};
171170

172171
template<>
173172
struct Storage<4, uint32_t, true>
174173
{
175-
using type = riot_u32vec4;
174+
using type = MIM_u32vec4;
176175
};
177176
#endif
178177

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
1-
// Copyright WizWorks, Inc. All Rights Reserved.
1+
// Copyright (c) 2023-Present Mim contributors (see LICENSE)
22

33
#pragma once
44

5-
#include "system/core.hpp"
5+
#include "mim/detail/qualifier.hpp"
6+
7+
namespace mim
8+
{
9+
10+
}
Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
1-
// Copyright WizWorks, Inc. All Rights Reserved.
1+
// Copyright (c) 2023-Present Mim contributors (see LICENSE)
22

33
#pragma once
44

5-
#include "system/core.hpp"
5+
#include "mim/detail/qualifier.hpp"
6+
7+
namespace mim
8+
{
9+
10+
}
Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
1-
// Copyright WizWorks, Inc. All Rights Reserved.
1+
// Copyright (c) 2023-Present Mim contributors (see LICENSE)
22

33
#pragma once
44

5-
#include "system/core.hpp"
5+
#include "mim/detail/qualifier.hpp"
6+
7+
namespace mim
8+
{
9+
10+
}
Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
1-
// Copyright WizWorks, Inc. All Rights Reserved.
1+
// Copyright (c) 2023-Present Mim contributors (see LICENSE)
22

33
#pragma once
44

5-
#include "system/core.hpp"
5+
#include "mim/detail/qualifier.hpp"
6+
7+
namespace mim
8+
{
9+
10+
}
Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
1-
// Copyright WizWorks, Inc. All Rights Reserved.
1+
// Copyright (c) 2023-Present Mim contributors (see LICENSE)
22

33
#pragma once
44

5-
#include "system/core.hpp"
5+
#include "mim/detail/qualifier.hpp"
6+
7+
namespace mim
8+
{
9+
10+
}
Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
1-
// Copyright WizWorks, Inc. All Rights Reserved.
1+
// Copyright (c) 2023-Present Mim contributors (see LICENSE)
22

33
#pragma once
44

5-
#include "system/core.hpp"
5+
#include "mim/detail/qualifier.hpp"
6+
7+
namespace mim
8+
{
9+
10+
}
Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
1-
// Copyright WizWorks, Inc. All Rights Reserved.
1+
// Copyright (c) 2023-Present Mim contributors (see LICENSE)
22

33
#pragma once
44

5-
#include "system/core.hpp"
5+
#include "mim/detail/qualifier.hpp"
6+
7+
namespace mim
8+
{
9+
10+
}

0 commit comments

Comments
 (0)