Quasar
Moderator

Posts: 4484
Registered: 08-00 |
GhostlyDeath said:
Mingw64 works good (I use it for ReMooD's SDL and it's 64-bit compilation) but since you don't want any Mingws you might be able to compile it using the VC++ projects with little modification.
Main issue with MinGW is that SDL's support for it is horrible (configs and makefiles regularly end up broken) and the resulting DLLs have broken behaviors (such as hard-mapping my stdio to a file - if I wanted that, I would explicitly code it so - this is not something for a library to decide for me).
In response to the various arguments and discussions going on previously, I must add my own comments:
- EE has already stopped using short or long types in any place where the size of an integer variable matters, with the exception of some map data structures which I don't believe I've gotten around to changing yet.
- EE uses a 3rd-party header to provide C99 types for Visual C++. Believe it or not, GCC has given us more trouble in the transition to C99 types, as its headers are a grotesque non-standard mess that contain conflicting and incorrect definitions of the types in unnecessary/redundant places.
- Fundamental DOOM data types such as byte, fixed_t, and angle_t are typedefs for the proper C99 fixed-size type now.
- EE has eliminated all instances of pointer coercion into integers (there were VERY few of these to begin with, as they are terrible practice) outside of the Small virtual machine, which has already been identified as having intractible 64-bit portability issues, and will simply not be supported there at all (it is already considered deprecated on 32-bit and will be replaced by our currently-in-planning Aeon API on ECMAScript).
- I have taken steps to clean up any Win32-specific code to work on Win64 as well, excluding the SEH which isn't meant to be portable anyway.
- I just eliminated the undefined behavior with respect to va_list which was causing compilation failure on GCC 64-bit.
So as you can see, we are already well on the way. There are benefits to compiling any program as 64-bit, one of the key ones already having been mentioned being that the porting process cleans up stuff that is already a problem in the code (non-portable idioms).
I may be wrong, but don't x64 processors use SSE instructions for floating point? If this is the case, it may make EE's Cardboard rendering faster. I do not know if it requires major reorganization of the code to take advantage of that, or if the compiler's optimizer is smart enough to apply tweaks on its own.
At any rate, I don't feel that 64-bit integer math is the only reason to port up. 64-bit integers are rarely necessary for anything. They represent a scale of numbers that is largely outside of daily experience. How often do you even deal with 4 billion of something, for that matter? :)
Last edited by Quasar on 12-31-09 at 04:28
|