Re: #IFDEFs in a multi platform environment
From: Fred Kleinsorge (fred.nospam_at_nospam.dec.com)
Date: 09/30/04
- Next message: Ed Vogel: "Re: #IFDEFs in a multi platform environment"
- Previous message: Hal Kuff: "WRQ OpenVMS Survey"
- In reply to: JF Mezei: "#IFDEFs in a multi platform environment"
- Next in thread: Ed Vogel: "Re: #IFDEFs in a multi platform environment"
- Reply: Ed Vogel: "Re: #IFDEFs in a multi platform environment"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Thu, 30 Sep 2004 14:22:31 GMT
"JF Mezei" <jfmezei.spamnot@teksavvy.com> wrote in message
news:415BBFCF.A8FEB52D@teksavvy.com...
> Someone on the OSU mailing list reported that by defining __ALPHA to
compile
> the OSU software on that IA64 thing, the C compiler generated some errors.
>
> This got me to think: With VMS likely to exist on VAX, Alpha, IA64 and
AMD64,
> would it be better for applications to use __VMS32 and __VMS64 instead of
> platform specific names such as __VAX and __ALPHA?
>
> This way, they would be independant from C compiler specific definitions,
and
> one woudln't actually have to make changes to programs that run on any of
the
> 64 bit platforms VMS may be called to run on.
>
> Deep down kernel stuff can still make use of platform specific ifdefs when
> necessary, but normal user mode applications wouldn't need any
modifications
> and addition of more ifdefs for each platform.
There are specific reasons that code may need to know the precise
architecture (I do not think __AMD64 is likely to be one of them). In
general you can accomplish what you want by simply using __VAX as meaning
32-bit, and anything else as 64-bit. If you want to define specific symbols
for that meaning - that's fairly trivial.
In retrospect, most of the changes needed in porting truly are a result of
an inappropriate use of __ALPHA to mean NOT __VAX. The compiler is (I
believe) being changed so that the redefinition of __ALPHA is an
informational as opposed to a warning - for those not able or willing to
make the source code changes.
- Next message: Ed Vogel: "Re: #IFDEFs in a multi platform environment"
- Previous message: Hal Kuff: "WRQ OpenVMS Survey"
- In reply to: JF Mezei: "#IFDEFs in a multi platform environment"
- Next in thread: Ed Vogel: "Re: #IFDEFs in a multi platform environment"
- Reply: Ed Vogel: "Re: #IFDEFs in a multi platform environment"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|