RE: [Linux-ia64] C union on ia-64

From: Tang, Yu <yu.tang_at_intel.com>
Date: 2001-10-25 11:12:51
/* size.c */
#include "stido.h"
int main(int argc, char *argv[])
{
	printf("%d,%d\n",sizeof(unsigned long),sizeof(void*));
	return 0;
}

under linux:
$gcc size.c -o size
$./size
8,8

under 64-bit WinXP:
c:\temp\size
4,8

-----Original Message-----
From: KOCHI, Takayoshi [mailto:t-kouchi@mvf.biglobe.ne.jp]
Sent: 2001年10oe^25- 3:50
To: linux-64
Subject: Re: [Linux-ia64] C union on ia-64


> PS: Interestingly enought, I believe Intel's slide is actually
> wrong.  If `ULONG' is an `unsigned long' and `PVOID' is a `void *'
> then all of the data items have the same size and the two structures
> can be used interchangably on either IA32 or IA64.  It's a
> dangerous technique but it would work in this case.

I believe win64 uses P64 for its programming model.
(while we use LP64 instead)
So their ULONG is still 32bit in IA64.

Regards,
-- 
KOCHI Takayoshi <t-kouchi@cq.jp.nec.com/t-kouchi@mvf.biglobe.ne.jp>


_______________________________________________
Linux-IA64 mailing list
Linux-IA64@linuxia64.org
http://lists.linuxia64.org/lists/listinfo/linux-ia64
Received on Wed Oct 24 18:13:43 2001

This archive was generated by hypermail 2.1.8 : 2005-08-02 09:20:05 EST