[M3devel] Alpha is 32bits!

Jay K jay.krell at cornell.edu
Wed Apr 21 09:56:22 CEST 2010


Huh. I found that OpenVMS on Alpha is a hybrid 32bit/64bit system.

The default pointer size is 32 bits. You can change it to 64 bits with compiler command line option.
I guess this is for greater compatibility with VAX.
There are two of many functions. Some are missing in 64 bits.
size_t is always 32 bits!

http://www.openvms.compaq.com/doc/72final/6467/6467pro_contents.html
esp. http://www.openvms.compaq.com/doc/72final/6467/6467pro_006.html#64_bit_obtaining_long_ptrs_sec

and newer similar: http://www.openvms.compaq.com/doc/83final/5763/5763pro_007.html#the_64_bit_sec

WALLIS> type jmpbuf.c

#include <setjmp.h>

#include <stdio.h>

#include <stddef.h>



#define SIZE(x) ((unsigned)sizeof(x))



int main()

{

  printf("%u %u %u %u %u\n",

    SIZE(int),

    SIZE(long),

    SIZE(void*),

    SIZE(size_t),

    SIZE(jmp_buf));

  return 0;

}



WALLIS> cc jmpbuf.c

WALLIS> link jmpbuf.obj

WALLIS> run jmpbuf

4 4 4 4 544



WALLIS> cc /pointer_size=64 jmpbuf.c

WALLIS> link jmpbuf.obj

WALLIS> run jmpbuf

4 4 8 4 544



I still haven't found the actual header files!


So I'm going to work toward ALPHA32_VMS for now.
I can try ALPHA64_VMS later.
Assuming m3cg offers -m32 and -m64 to handle this. :)

 - Jay
 		 	   		  


More information about the M3devel mailing list