@@ -40,7 +40,7 @@ static MLD_INLINE void mld_poly_permute_bitrev_to_custom(int32_t data[MLDSA_N])
4040{
4141 if (mld_sys_check_capability (MLD_SYS_CAP_AVX2 ))
4242 {
43- mld_nttunpack_avx2 (( __m256i * )( data ) );
43+ mld_nttunpack_avx2 (data );
4444 }
4545}
4646
@@ -51,7 +51,7 @@ static MLD_INLINE int mld_ntt_native(int32_t data[MLDSA_N])
5151 return MLD_NATIVE_FUNC_FALLBACK ;
5252 }
5353
54- mld_ntt_avx2 (( __m256i * ) data , mld_qdata . vec );
54+ mld_ntt_avx2 (data , mld_qdata );
5555 return MLD_NATIVE_FUNC_SUCCESS ;
5656}
5757static MLD_INLINE int mld_intt_native (int32_t data [MLDSA_N ])
@@ -60,7 +60,7 @@ static MLD_INLINE int mld_intt_native(int32_t data[MLDSA_N])
6060 {
6161 return MLD_NATIVE_FUNC_FALLBACK ;
6262 }
63- mld_invntt_avx2 (( __m256i * ) data , mld_qdata . vec );
63+ mld_invntt_avx2 (data , mld_qdata );
6464 return MLD_NATIVE_FUNC_SUCCESS ;
6565}
6666
@@ -137,7 +137,7 @@ static MLD_INLINE int mld_poly_decompose_32_native(int32_t *a1, int32_t *a0)
137137 {
138138 return MLD_NATIVE_FUNC_FALLBACK ;
139139 }
140- mld_poly_decompose_32_avx2 (( __m256i * ) a1 , ( __m256i * ) a0 );
140+ mld_poly_decompose_32_avx2 (a1 , a0 );
141141 return MLD_NATIVE_FUNC_SUCCESS ;
142142}
143143
@@ -147,7 +147,7 @@ static MLD_INLINE int mld_poly_decompose_88_native(int32_t *a1, int32_t *a0)
147147 {
148148 return MLD_NATIVE_FUNC_FALLBACK ;
149149 }
150- mld_poly_decompose_88_avx2 (( __m256i * ) a1 , ( __m256i * ) a0 );
150+ mld_poly_decompose_88_avx2 (a1 , a0 );
151151 return MLD_NATIVE_FUNC_SUCCESS ;
152152}
153153
@@ -167,8 +167,7 @@ static MLD_INLINE int mld_poly_use_hint_32_native(int32_t *b, const int32_t *a,
167167 {
168168 return MLD_NATIVE_FUNC_FALLBACK ;
169169 }
170- mld_poly_use_hint_32_avx2 ((__m256i * )b , (const __m256i * )a ,
171- (const __m256i * )h );
170+ mld_poly_use_hint_32_avx2 (b , a , h );
172171 return MLD_NATIVE_FUNC_SUCCESS ;
173172}
174173
@@ -179,8 +178,7 @@ static MLD_INLINE int mld_poly_use_hint_88_native(int32_t *b, const int32_t *a,
179178 {
180179 return MLD_NATIVE_FUNC_FALLBACK ;
181180 }
182- mld_poly_use_hint_88_avx2 ((__m256i * )b , (const __m256i * )a ,
183- (const __m256i * )h );
181+ mld_poly_use_hint_88_avx2 (b , a , h );
184182 return MLD_NATIVE_FUNC_SUCCESS ;
185183}
186184
@@ -190,7 +188,7 @@ static MLD_INLINE int mld_poly_chknorm_native(const int32_t *a, int32_t B)
190188 {
191189 return MLD_NATIVE_FUNC_FALLBACK ;
192190 }
193- return mld_poly_chknorm_avx2 (( const __m256i * ) a , B );
191+ return mld_poly_chknorm_avx2 (a , B );
194192}
195193
196194static MLD_INLINE int mld_polyz_unpack_17_native (int32_t * r , const uint8_t * a )
@@ -199,7 +197,7 @@ static MLD_INLINE int mld_polyz_unpack_17_native(int32_t *r, const uint8_t *a)
199197 {
200198 return MLD_NATIVE_FUNC_FALLBACK ;
201199 }
202- mld_polyz_unpack_17_avx2 (( __m256i * ) r , a );
200+ mld_polyz_unpack_17_avx2 (r , a );
203201 return MLD_NATIVE_FUNC_SUCCESS ;
204202}
205203
@@ -209,7 +207,7 @@ static MLD_INLINE int mld_polyz_unpack_19_native(int32_t *r, const uint8_t *a)
209207 {
210208 return MLD_NATIVE_FUNC_FALLBACK ;
211209 }
212- mld_polyz_unpack_19_avx2 (( __m256i * ) r , a );
210+ mld_polyz_unpack_19_avx2 (r , a );
213211 return MLD_NATIVE_FUNC_SUCCESS ;
214212}
215213
@@ -220,8 +218,7 @@ static MLD_INLINE int mld_poly_pointwise_montgomery_native(
220218 {
221219 return MLD_NATIVE_FUNC_FALLBACK ;
222220 }
223- mld_pointwise_avx2 ((__m256i * )c , (const __m256i * )a , (const __m256i * )b ,
224- mld_qdata .vec );
221+ mld_pointwise_avx2 (c , a , b , mld_qdata );
225222 return MLD_NATIVE_FUNC_SUCCESS ;
226223}
227224
@@ -233,8 +230,7 @@ static MLD_INLINE int mld_polyvecl_pointwise_acc_montgomery_l4_native(
233230 {
234231 return MLD_NATIVE_FUNC_FALLBACK ;
235232 }
236- mld_pointwise_acc_l4_avx2 ((__m256i * )w , (const __m256i * )u ,
237- (const __m256i * )v , mld_qdata .vec );
233+ mld_pointwise_acc_l4_avx2 (w , u , v , mld_qdata );
238234 return MLD_NATIVE_FUNC_SUCCESS ;
239235}
240236
@@ -246,8 +242,7 @@ static MLD_INLINE int mld_polyvecl_pointwise_acc_montgomery_l5_native(
246242 {
247243 return MLD_NATIVE_FUNC_FALLBACK ;
248244 }
249- mld_pointwise_acc_l5_avx2 ((__m256i * )w , (const __m256i * )u ,
250- (const __m256i * )v , mld_qdata .vec );
245+ mld_pointwise_acc_l5_avx2 (w , u , v , mld_qdata );
251246 return MLD_NATIVE_FUNC_SUCCESS ;
252247}
253248
@@ -259,8 +254,7 @@ static MLD_INLINE int mld_polyvecl_pointwise_acc_montgomery_l7_native(
259254 {
260255 return MLD_NATIVE_FUNC_FALLBACK ;
261256 }
262- mld_pointwise_acc_l7_avx2 ((__m256i * )w , (const __m256i * )u ,
263- (const __m256i * )v , mld_qdata .vec );
257+ mld_pointwise_acc_l7_avx2 (w , u , v , mld_qdata );
264258 return MLD_NATIVE_FUNC_SUCCESS ;
265259}
266260
0 commit comments