mirror of
https://github.com/dhewm/dhewm3-sdk.git
synced 2024-11-21 20:21:19 +00:00
make idlib build with Visual Studio 14
This commit is contained in:
parent
746f2cb454
commit
99bbd70af5
3 changed files with 86 additions and 80 deletions
|
@ -30,6 +30,9 @@ If you have questions concerning this license or the applicable additional terms
|
|||
#define __MATH_MATRIX_H__
|
||||
|
||||
#include "idlib/math/Vector.h"
|
||||
#ifdef _WIN32
|
||||
#include <malloc.h>
|
||||
#endif
|
||||
|
||||
/*
|
||||
===============================================================================
|
||||
|
|
|
@ -31,6 +31,9 @@ If you have questions concerning this license or the applicable additional terms
|
|||
|
||||
#include "idlib/math/Complex.h"
|
||||
#include "idlib/Heap.h"
|
||||
#ifdef _WIN32
|
||||
#include <malloc.h>
|
||||
#endif
|
||||
|
||||
/*
|
||||
===============================================================================
|
||||
|
|
|
@ -289,7 +289,7 @@ void TestAdd( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->Add( float + float[] ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
bestClocksGeneric = 0;
|
||||
|
@ -314,7 +314,7 @@ void TestAdd( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->Add( float[] + float[] ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -363,7 +363,7 @@ void TestSub( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->Sub( float + float[] ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
bestClocksGeneric = 0;
|
||||
|
@ -388,7 +388,7 @@ void TestSub( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->Sub( float[] + float[] ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -437,7 +437,7 @@ void TestMul( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->Mul( float * float[] ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
|
||||
|
@ -463,7 +463,7 @@ void TestMul( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->Mul( float[] * float[] ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -515,7 +515,7 @@ void TestDiv( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->Div( float * float[] ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
|
||||
|
@ -541,7 +541,7 @@ void TestDiv( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->Div( float[] * float[] ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -596,7 +596,7 @@ void TestMulAdd( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MulAdd( float * float[%2d] ) %s", j, result ), 1, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
}
|
||||
|
@ -652,7 +652,7 @@ void TestMulSub( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MulSub( float * float[%2d] ) %s", j, result ), 1, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
}
|
||||
|
@ -718,7 +718,7 @@ void TestDot( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->Dot( idVec3 * idVec3[] ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
|
||||
|
@ -744,7 +744,7 @@ void TestDot( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->Dot( idVec3 * idPlane[] ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
|
||||
|
@ -770,7 +770,7 @@ void TestDot( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->Dot( idVec3 * idDrawVert[] ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
|
||||
|
@ -796,7 +796,7 @@ void TestDot( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->Dot( idPlane * idVec3[] ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
|
||||
|
@ -822,7 +822,7 @@ void TestDot( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->Dot( idPlane * idPlane[] ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
|
||||
|
@ -848,7 +848,7 @@ void TestDot( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->Dot( idPlane * idDrawVert[] ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
|
||||
|
@ -874,7 +874,7 @@ void TestDot( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->Dot( idVec3[] * idVec3[] ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
|
||||
|
@ -899,7 +899,7 @@ void TestDot( void ) {
|
|||
StopRecordTime( end );
|
||||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
result = idMath::Fabs( dot1 - dot2 ) < 1e-4f ? "ok" : S_COLOR_RED"X";
|
||||
result = idMath::Fabs( dot1 - dot2 ) < 1e-4f ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->Dot( float[%2d] * float[%2d] ) %s", j, j, result ), 1, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
}
|
||||
|
@ -947,7 +947,7 @@ void TestCompare( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->CmpGT( float[] >= float ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
bestClocksGeneric = 0;
|
||||
|
@ -974,7 +974,7 @@ void TestCompare( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->CmpGT( 2, float[] >= float ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
// ======================
|
||||
|
@ -1001,7 +1001,7 @@ void TestCompare( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->CmpGE( float[] >= float ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
bestClocksGeneric = 0;
|
||||
|
@ -1028,7 +1028,7 @@ void TestCompare( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->CmpGE( 2, float[] >= float ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
// ======================
|
||||
|
@ -1055,7 +1055,7 @@ void TestCompare( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->CmpLT( float[] >= float ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
bestClocksGeneric = 0;
|
||||
|
@ -1082,7 +1082,7 @@ void TestCompare( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->CmpLT( 2, float[] >= float ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
// ======================
|
||||
|
@ -1109,7 +1109,7 @@ void TestCompare( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->CmpLE( float[] >= float ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
bestClocksGeneric = 0;
|
||||
|
@ -1136,7 +1136,7 @@ void TestCompare( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->CmpLE( 2, float[] >= float ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -1192,7 +1192,7 @@ void TestMinMax( void ) {
|
|||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
|
||||
result = ( min == min2 && max == max2 ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( min == min2 && max == max2 ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MinMax( float[] ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
bestClocksGeneric = 0;
|
||||
|
@ -1212,7 +1212,7 @@ void TestMinMax( void ) {
|
|||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
|
||||
result = ( v2min == v2min2 && v2max == v2max2 ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( v2min == v2min2 && v2max == v2max2 ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MinMax( idVec2[] ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
bestClocksGeneric = 0;
|
||||
|
@ -1232,7 +1232,7 @@ void TestMinMax( void ) {
|
|||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
|
||||
result = ( vmin == vmin2 && vmax == vmax2 ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( vmin == vmin2 && vmax == vmax2 ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MinMax( idVec3[] ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
bestClocksGeneric = 0;
|
||||
|
@ -1252,7 +1252,7 @@ void TestMinMax( void ) {
|
|||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
|
||||
result = ( vmin == vmin2 && vmax == vmax2 ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( vmin == vmin2 && vmax == vmax2 ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MinMax( idDrawVert[] ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
bestClocksGeneric = 0;
|
||||
|
@ -1272,7 +1272,7 @@ void TestMinMax( void ) {
|
|||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
|
||||
result = ( vmin == vmin2 && vmax == vmax2 ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( vmin == vmin2 && vmax == vmax2 ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MinMax( idDrawVert[], indexes[] ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -1319,7 +1319,7 @@ void TestClamp( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->Clamp( float[] ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
|
||||
|
@ -1345,7 +1345,7 @@ void TestClamp( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->ClampMin( float[] ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
|
||||
|
@ -1371,7 +1371,7 @@ void TestClamp( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->ClampMax( float[] ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -1396,7 +1396,7 @@ void TestMemcpy( void ) {
|
|||
p_simd->Memcpy( test1, test0, 8192 );
|
||||
for ( j = 0; j < i; j++ ) {
|
||||
if ( test1[j] != test0[j] ) {
|
||||
idLib::common->Printf( " simd->Memcpy() "S_COLOR_RED"X\n" );
|
||||
idLib::common->Printf( " simd->Memcpy() " S_COLOR_RED "X\n" );
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
@ -1422,7 +1422,7 @@ void TestMemset( void ) {
|
|||
p_simd->Memset( test, j, i );
|
||||
for ( k = 0; k < i; k++ ) {
|
||||
if ( test[k] != (byte)j ) {
|
||||
idLib::common->Printf( " simd->Memset() "S_COLOR_RED"X\n" );
|
||||
idLib::common->Printf( " simd->Memset() " S_COLOR_RED "X\n" );
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
@ -1480,7 +1480,7 @@ void TestMatXMultiplyVecX( void ) {
|
|||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
|
||||
result = dst.Compare( tst, MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED"X";
|
||||
result = dst.Compare( tst, MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MatX_MultiplyVecX %dx%d*%dx1 %s", i, i, i, result ), 1, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -1510,7 +1510,7 @@ void TestMatXMultiplyVecX( void ) {
|
|||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
|
||||
result = dst.Compare( tst, MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED"X";
|
||||
result = dst.Compare( tst, MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MatX_MultiplyVecX %dx6*6x1 %s", i, result ), 1, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -1539,7 +1539,7 @@ void TestMatXMultiplyVecX( void ) {
|
|||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
|
||||
result = dst.Compare( tst, MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED"X";
|
||||
result = dst.Compare( tst, MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MatX_MultiplyVecX 6x%d*%dx1 %s", i, i, result ), 1, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
}
|
||||
|
@ -1591,7 +1591,7 @@ void TestMatXMultiplyAddVecX( void ) {
|
|||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
|
||||
result = dst.Compare( tst, MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED"X";
|
||||
result = dst.Compare( tst, MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MatX_MultiplyAddVecX %dx%d*%dx1 %s", i, i, i, result ), 1, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -1621,7 +1621,7 @@ void TestMatXMultiplyAddVecX( void ) {
|
|||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
|
||||
result = dst.Compare( tst, MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED"X";
|
||||
result = dst.Compare( tst, MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MatX_MultiplyAddVecX %dx6*6x1 %s", i, result ), 1, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -1651,7 +1651,7 @@ void TestMatXMultiplyAddVecX( void ) {
|
|||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
|
||||
result = dst.Compare( tst, MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED"X";
|
||||
result = dst.Compare( tst, MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MatX_MultiplyAddVecX 6x%d*%dx1 %s", i, i, result ), 1, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
}
|
||||
|
@ -1703,7 +1703,7 @@ void TestMatXTransposeMultiplyVecX( void ) {
|
|||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
|
||||
result = dst.Compare( tst, MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED"X";
|
||||
result = dst.Compare( tst, MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MatX_TransposeMulVecX %dx6*%dx1 %s", i, i, result ), 1, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -1733,7 +1733,7 @@ void TestMatXTransposeMultiplyVecX( void ) {
|
|||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
|
||||
result = dst.Compare( tst, MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED"X";
|
||||
result = dst.Compare( tst, MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MatX_TransposeMulVecX 6x%d*6x1 %s", i, result ), 1, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
}
|
||||
|
@ -1785,7 +1785,7 @@ void TestMatXTransposeMultiplyAddVecX( void ) {
|
|||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
|
||||
result = dst.Compare( tst, MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED"X";
|
||||
result = dst.Compare( tst, MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MatX_TransposeMulAddVecX %dx6*%dx1 %s", i, i, result ), 1, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -1815,7 +1815,7 @@ void TestMatXTransposeMultiplyAddVecX( void ) {
|
|||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
|
||||
result = dst.Compare( tst, MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED"X";
|
||||
result = dst.Compare( tst, MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MatX_TransposeMulAddVecX 6x%d*6x1 %s", i, result ), 1, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
}
|
||||
|
@ -1861,7 +1861,7 @@ void TestMatXMultiplyMatX( void ) {
|
|||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
|
||||
result = dst.Compare( tst, MATX_MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED"X";
|
||||
result = dst.Compare( tst, MATX_MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MatX_MultiplyMatX %dx%d*%dx6 %s", i, i, i, result ), 1, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -1892,7 +1892,7 @@ void TestMatXMultiplyMatX( void ) {
|
|||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
|
||||
result = dst.Compare( tst, MATX_MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED"X";
|
||||
result = dst.Compare( tst, MATX_MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MatX_MultiplyMatX 6x%d*%dx6 %s", i, i, result ), 1, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -1923,7 +1923,7 @@ void TestMatXMultiplyMatX( void ) {
|
|||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
|
||||
result = dst.Compare( tst, MATX_MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED"X";
|
||||
result = dst.Compare( tst, MATX_MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MatX_MultiplyMatX %dx6*6x%d %s", i, i, result ), 1, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -1954,7 +1954,7 @@ void TestMatXMultiplyMatX( void ) {
|
|||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
|
||||
result = dst.Compare( tst, MATX_MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED"X";
|
||||
result = dst.Compare( tst, MATX_MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MatX_MultiplyMatX 6x6*6x%d %s", i, result ), 1, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
}
|
||||
|
@ -1997,7 +1997,7 @@ void TestMatXTransposeMultiplyMatX( void ) {
|
|||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
|
||||
result = dst.Compare( tst, MATX_MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED"X";
|
||||
result = dst.Compare( tst, MATX_MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MatX_TransMultiplyMatX %dx6*%dx%d %s", i, i, i, result ), 1, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -2028,7 +2028,7 @@ void TestMatXTransposeMultiplyMatX( void ) {
|
|||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
|
||||
result = dst.Compare( tst, MATX_MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED"X";
|
||||
result = dst.Compare( tst, MATX_MATX_SIMD_EPSILON ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MatX_TransMultiplyMatX 6x%d*6x6 %s", i, result ), 1, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
}
|
||||
|
@ -2078,7 +2078,7 @@ void TestMatXLowerTriangularSolve( void ) {
|
|||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
|
||||
result = x.Compare( tst, MATX_LTS_SIMD_EPSILON ) ? "ok" : S_COLOR_RED"X";
|
||||
result = x.Compare( tst, MATX_LTS_SIMD_EPSILON ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MatX_LowerTriangularSolve %dx%d %s", i, i, result ), 1, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
}
|
||||
|
@ -2125,7 +2125,7 @@ void TestMatXLowerTriangularSolveTranspose( void ) {
|
|||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
|
||||
result = x.Compare( tst, MATX_LTS_SIMD_EPSILON ) ? "ok" : S_COLOR_RED"X";
|
||||
result = x.Compare( tst, MATX_LTS_SIMD_EPSILON ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MatX_LowerTriangularSolveT %dx%d %s", i, i, result ), 1, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
}
|
||||
|
@ -2175,7 +2175,7 @@ void TestMatXLDLTFactor( void ) {
|
|||
GetBest( start, end, bestClocksSIMD );
|
||||
}
|
||||
|
||||
result = mat1.Compare( mat2, MATX_LDLT_SIMD_EPSILON ) && invDiag1.Compare( invDiag2, MATX_LDLT_SIMD_EPSILON ) ? "ok" : S_COLOR_RED"X";
|
||||
result = mat1.Compare( mat2, MATX_LDLT_SIMD_EPSILON ) && invDiag1.Compare( invDiag2, MATX_LDLT_SIMD_EPSILON ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MatX_LDLTFactor %dx%d %s", i, i, result ), 1, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
}
|
||||
|
@ -2248,7 +2248,7 @@ void TestBlendJoints( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->BlendJoints() %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -2300,7 +2300,7 @@ void TestConvertJointQuatsToJointMats( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->ConvertJointQuatsToJointMats() %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -2359,7 +2359,7 @@ void TestConvertJointMatsToJointQuats( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->ConvertJointMatsToJointQuats() %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -2421,7 +2421,7 @@ void TestTransformJoints( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->TransformJoints() %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -2483,7 +2483,7 @@ void TestUntransformJoints( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->UntransformJoints() %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -2550,7 +2550,7 @@ void TestTransformVerts( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= NUMVERTS ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= NUMVERTS ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->TransformVerts() %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -2608,7 +2608,7 @@ void TestTracePointCull( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT && totalOr1 == totalOr2 ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT && totalOr1 == totalOr2 ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->TracePointCull() %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -2669,7 +2669,7 @@ void TestDecalPointCull( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->DecalPointCull() %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -2727,7 +2727,7 @@ void TestOverlayPointCull( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->OverlayPointCull() %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -2786,7 +2786,7 @@ void TestDeriveTriPlanes( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->DeriveTriPlanes() %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -2871,7 +2871,7 @@ void TestDeriveTangents( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->DeriveTangents() %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -2948,7 +2948,7 @@ void TestDeriveUnsmoothedTangents( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->DeriveUnsmoothedTangents() %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -3009,7 +3009,7 @@ void TestNormalizeTangents( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->NormalizeTangents() %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -3071,7 +3071,7 @@ void TestGetTextureSpaceLightVectors( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->CreateTextureSpaceLightVectors() %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -3136,7 +3136,7 @@ void TestGetSpecularTextureCoords( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->CreateSpecularTextureCoords() %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -3207,7 +3207,7 @@ void TestCreateShadowCache( void ) {
|
|||
}
|
||||
}
|
||||
|
||||
result = ( i >= COUNT && numVerts1 == numVerts2 ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT && numVerts1 == numVerts2 ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->CreateShadowCache() %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
bestClocksGeneric = 0;
|
||||
|
@ -3235,7 +3235,7 @@ void TestCreateShadowCache( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->CreateVertexProgramShadowCache() %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -3294,7 +3294,7 @@ void TestSoundUpSampling( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= MIXBUFFER_SAMPLES*numSpeakers ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= MIXBUFFER_SAMPLES*numSpeakers ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->UpSamplePCMTo44kHz( %d, %d ) %s", kHz, numSpeakers, result ), MIXBUFFER_SAMPLES*numSpeakers*kHz/44100, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
}
|
||||
|
@ -3324,7 +3324,7 @@ void TestSoundUpSampling( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= MIXBUFFER_SAMPLES ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= MIXBUFFER_SAMPLES ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->UpSampleOGGTo44kHz( %d, %d ) %s", kHz, numSpeakers, result ), MIXBUFFER_SAMPLES*numSpeakers*kHz/44100, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
}
|
||||
|
@ -3391,7 +3391,7 @@ void TestSoundMixing( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= MIXBUFFER_SAMPLES*6 ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= MIXBUFFER_SAMPLES*6 ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MixSoundTwoSpeakerMono() %s", result ), MIXBUFFER_SAMPLES, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
bestClocksGeneric = 0;
|
||||
|
@ -3423,7 +3423,7 @@ void TestSoundMixing( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= MIXBUFFER_SAMPLES*6 ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= MIXBUFFER_SAMPLES*6 ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MixSoundTwoSpeakerStereo() %s", result ), MIXBUFFER_SAMPLES, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
|
||||
|
@ -3456,7 +3456,7 @@ void TestSoundMixing( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= MIXBUFFER_SAMPLES*6 ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= MIXBUFFER_SAMPLES*6 ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MixSoundSixSpeakerMono() %s", result ), MIXBUFFER_SAMPLES, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
bestClocksGeneric = 0;
|
||||
|
@ -3488,7 +3488,7 @@ void TestSoundMixing( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= MIXBUFFER_SAMPLES*6 ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= MIXBUFFER_SAMPLES*6 ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MixSoundSixSpeakerStereo() %s", result ), MIXBUFFER_SAMPLES, bestClocksSIMD, bestClocksGeneric );
|
||||
|
||||
|
||||
|
@ -3524,7 +3524,7 @@ void TestSoundMixing( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= MIXBUFFER_SAMPLES*6 ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= MIXBUFFER_SAMPLES*6 ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->MixedSoundToSamples() %s", result ), MIXBUFFER_SAMPLES, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
@ -3983,7 +3983,7 @@ void TestNegate( void ) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED"X";
|
||||
result = ( i >= COUNT ) ? "ok" : S_COLOR_RED "X";
|
||||
PrintClocks( va( " simd->Negate16( float[] ) %s", result ), COUNT, bestClocksSIMD, bestClocksGeneric );
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue