From 16871256f87b81a6e282958b00e77ae50ace7012 Mon Sep 17 00:00:00 2001 From: dhewg Date: Thu, 5 Jul 2012 22:55:05 +0200 Subject: [PATCH] Get rid of Sys_FPU_GetState() This was only implemented with MSVC style asm. Comments suggest that it was used to help catch invalid FOV calculations, which were probably only happening with ancient compiler bugs. --- d3xp/Game_local.cpp | 3 --- game/Game_local.cpp | 3 --- sys/sys_public.h | 4 ---- 3 files changed, 10 deletions(-) diff --git a/d3xp/Game_local.cpp b/d3xp/Game_local.cpp index 13c8b8a..09208e3 100644 --- a/d3xp/Game_local.cpp +++ b/d3xp/Game_local.cpp @@ -2657,7 +2657,6 @@ void idGameLocal::CalcFov( float base_fov, float &fov_x, float &fov_y ) const { float ratio_y; if ( !sys->FPU_StackIsEmpty() ) { - Printf( sys->FPU_GetState() ); Error( "idGameLocal::CalcFov: FPU stack not empty" ); } @@ -2669,7 +2668,6 @@ void idGameLocal::CalcFov( float base_fov, float &fov_x, float &fov_y ) const { // FIXME: somehow, this is happening occasionally assert( fov_y > 0 ); if ( fov_y <= 0 ) { - Printf( sys->FPU_GetState() ); Error( "idGameLocal::CalcFov: bad result" ); } @@ -2706,7 +2704,6 @@ void idGameLocal::CalcFov( float base_fov, float &fov_x, float &fov_y ) const { // FIXME: somehow, this is happening occasionally assert( ( fov_x > 0 ) && ( fov_y > 0 ) ); if ( ( fov_y <= 0 ) || ( fov_x <= 0 ) ) { - Printf( sys->FPU_GetState() ); Error( "idGameLocal::CalcFov: bad result" ); } } diff --git a/game/Game_local.cpp b/game/Game_local.cpp index 1c9d0a1..94280e8 100644 --- a/game/Game_local.cpp +++ b/game/Game_local.cpp @@ -2392,7 +2392,6 @@ void idGameLocal::CalcFov( float base_fov, float &fov_x, float &fov_y ) const { float ratio_y; if ( !sys->FPU_StackIsEmpty() ) { - Printf( sys->FPU_GetState() ); Error( "idGameLocal::CalcFov: FPU stack not empty" ); } @@ -2404,7 +2403,6 @@ void idGameLocal::CalcFov( float base_fov, float &fov_x, float &fov_y ) const { // FIXME: somehow, this is happening occasionally assert( fov_y > 0 ); if ( fov_y <= 0 ) { - Printf( sys->FPU_GetState() ); Error( "idGameLocal::CalcFov: bad result" ); } @@ -2441,7 +2439,6 @@ void idGameLocal::CalcFov( float base_fov, float &fov_x, float &fov_y ) const { // FIXME: somehow, this is happening occasionally assert( ( fov_x > 0 ) && ( fov_y > 0 ) ); if ( ( fov_y <= 0 ) || ( fov_x <= 0 ) ) { - Printf( sys->FPU_GetState() ); Error( "idGameLocal::CalcFov: bad result" ); } } diff --git a/sys/sys_public.h b/sys/sys_public.h index 0a63a69..b28fb7b 100644 --- a/sys/sys_public.h +++ b/sys/sys_public.h @@ -136,9 +136,6 @@ int Sys_GetProcessorId( void ); // returns true if the FPU stack is empty bool Sys_FPU_StackIsEmpty( void ); -// returns the FPU state as a string -const char * Sys_FPU_GetState( void ); - // sets the FPU precision void Sys_FPU_SetPrecision(); @@ -368,7 +365,6 @@ public: virtual unsigned int GetMilliseconds( void ) = 0; virtual int GetProcessorId( void ) = 0; - virtual const char * FPU_GetState( void ) = 0; virtual bool FPU_StackIsEmpty( void ) = 0; virtual void FPU_SetFTZ( bool enable ) = 0; virtual void FPU_SetDAZ( bool enable ) = 0;