From 8854f95152d82ae110ceb6b882a51d5af2212cfc Mon Sep 17 00:00:00 2001 From: Randy Heit Date: Wed, 20 Sep 2006 00:08:22 +0000 Subject: [PATCH] - Removed m_fixed.cpp - Fixed the GCC _DECLARE_TI macro to use the section name macro. SVN r332 (trunk) --- src/dobject.h | 2 +- src/m_fixed.cpp | 66 ------------------------------------------------- 2 files changed, 1 insertion(+), 67 deletions(-) delete mode 100644 src/m_fixed.cpp diff --git a/src/dobject.h b/src/dobject.h index be1fefbfc6..2cc7818843 100644 --- a/src/dobject.h +++ b/src/dobject.h @@ -177,7 +177,7 @@ private: \ # pragma data_seg() # define _DECLARE_TI(cls) __declspec(allocate(".creg$u")) ClassReg *cls::RegistrationInfoPtr = &cls::RegistrationInfo; #else -# define _DECLARE_TI(cls) ClassReg *cls::RegistrationInfoPtr __attribute__((section("creg"))) = &cls::RegistrationInfo; +# define _DECLARE_TI(cls) ClassReg *cls::RegistrationInfoPtr __attribute__((section(CREG_SECTION))) = &cls::RegistrationInfo; #endif #define _IMP_PCLASS(cls,ptrs,create) \ diff --git a/src/m_fixed.cpp b/src/m_fixed.cpp deleted file mode 100644 index 48a3162795..0000000000 --- a/src/m_fixed.cpp +++ /dev/null @@ -1,66 +0,0 @@ -// Emacs style mode select -*- C++ -*- -//----------------------------------------------------------------------------- -// -// $Id:$ -// -// Copyright (C) 1993-1996 by id Software, Inc. -// -// This source is available for distribution and/or modification -// only under the terms of the DOOM Source Code License as -// published by id Software. All rights reserved. -// -// The source is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// FITNESS FOR A PARTICULAR PURPOSE. See the DOOM Source Code License -// for more details. -// -// $Log:$ -// -// DESCRIPTION: -// Fixed point implementation. -// -//----------------------------------------------------------------------------- - - - -#include - -#include "doomtype.h" -#include "i_system.h" - -#include "m_fixed.h" - - -#ifndef USEASM - -// C routines - -fixed_t FixedMul_C (fixed_t a, fixed_t b) -{ - return (fixed_t)(((__int64) a * (__int64) b) >> FRACBITS); -} - -fixed_t FixedDiv_C (fixed_t a, fixed_t b) -{ - if ((abs (a) >> 14) >= abs (b)) - return (a^b)<0 ? FIXED_MIN : FIXED_MAX; - - { -#if 0 - long long c; - c = ((long long)a<<16) / ((long long)b); - return (fixed_t) c; -#endif - - double c; - - c = ((double)a) / ((double)b) * FRACUNIT; -/* - if (c >= 2147483648.0 || c < -2147483648.0) - I_FatalError("FixedDiv: divide by zero"); -*/ - return (fixed_t) c; - } -} - -#endif