@@ -188,38 +188,41 @@ static unsafe int Main(string[] args)
188
188
testResult = Fail ;
189
189
}
190
190
}
191
-
192
- using ( TestTable < long > longTable = new TestTable < long > ( new long [ 4 ] { long . MaxValue , long . MaxValue , long . MaxValue , long . MaxValue } ) )
191
+
192
+ if ( Environment . Is64BitProcess )
193
193
{
194
- var vf1 = Avx . SetVector256 ( 1 , 2 , 3 , 4 ) ;
195
- Unsafe . Write ( longTable . outArrayPtr , vf1 ) ;
196
-
197
- if ( ! longTable . CheckResult ( ( x ) => ( x [ 0 ] == 4 ) && ( x [ 1 ] == 3 ) && ( x [ 2 ] == 2 ) && ( x [ 3 ] == 1 ) ) )
194
+ using ( TestTable < long > longTable = new TestTable < long > ( new long [ 4 ] { long . MaxValue , long . MaxValue , long . MaxValue , long . MaxValue } ) )
198
195
{
199
- Console . WriteLine ( "AVX SetVector256 failed on long:" ) ;
200
- foreach ( var item in longTable . outArray )
196
+ var vf1 = Avx . SetVector256 ( 1 , 2 , 3 , 4 ) ;
197
+ Unsafe . Write ( longTable . outArrayPtr , vf1 ) ;
198
+
199
+ if ( ! longTable . CheckResult ( ( x ) => ( x [ 0 ] == 4 ) && ( x [ 1 ] == 3 ) && ( x [ 2 ] == 2 ) && ( x [ 3 ] == 1 ) ) )
201
200
{
202
- Console . Write ( item + ", " ) ;
201
+ Console . WriteLine ( "AVX SetVector256 failed on long:" ) ;
202
+ foreach ( var item in longTable . outArray )
203
+ {
204
+ Console . Write ( item + ", " ) ;
205
+ }
206
+ Console . WriteLine ( ) ;
207
+ testResult = Fail ;
203
208
}
204
- Console . WriteLine ( ) ;
205
- testResult = Fail ;
206
209
}
207
- }
208
-
209
- using ( TestTable < ulong > ulongTable = new TestTable < ulong > ( new ulong [ 4 ] { ulong . MaxValue , ulong . MaxValue , ulong . MaxValue , ulong . MaxValue } ) )
210
- {
211
- Vector256 < ulong > vf1 = Avx . SetVector256 ( ( ulong ) 1 , 2 , 3 , 4 ) ;
212
- Unsafe . Write ( ulongTable . outArrayPtr , vf1 ) ;
213
210
214
- if ( ! ulongTable . CheckResult ( ( x ) => ( x [ 0 ] == 4 ) && ( x [ 1 ] == 3 ) && ( x [ 2 ] == 2 ) && ( x [ 3 ] == 1 ) ) )
211
+ using ( TestTable < ulong > ulongTable = new TestTable < ulong > ( new ulong [ 4 ] { ulong . MaxValue , ulong . MaxValue , ulong . MaxValue , ulong . MaxValue } ) )
215
212
{
216
- Console . WriteLine ( "AVX SetVector256 failed on ulong:" ) ;
217
- foreach ( var item in ulongTable . outArray )
213
+ Vector256 < ulong > vf1 = Avx . SetVector256 ( ( ulong ) 1 , 2 , 3 , 4 ) ;
214
+ Unsafe . Write ( ulongTable . outArrayPtr , vf1 ) ;
215
+
216
+ if ( ! ulongTable . CheckResult ( ( x ) => ( x [ 0 ] == 4 ) && ( x [ 1 ] == 3 ) && ( x [ 2 ] == 2 ) && ( x [ 3 ] == 1 ) ) )
218
217
{
219
- Console . Write ( item + ", " ) ;
218
+ Console . WriteLine ( "AVX SetVector256 failed on ulong:" ) ;
219
+ foreach ( var item in ulongTable . outArray )
220
+ {
221
+ Console . Write ( item + ", " ) ;
222
+ }
223
+ Console . WriteLine ( ) ;
224
+ testResult = Fail ;
220
225
}
221
- Console . WriteLine ( ) ;
222
- testResult = Fail ;
223
226
}
224
227
}
225
228
}
0 commit comments