[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [Xen-devel] Definition of eax and rax

And I don't think it can work for none GCC compiler, since we use eax from time 
to time :-(
#ifdef __GNUC__
/* Anonymous union includes both 32- and 64-bit names (e.g., eax/rax). */
#define __DECL_REG(name) union { uint64_t r ## name, e ## name; }
/* Non-gcc sources must always use the proper 64-bit name (e.g., rax). */
#define __DECL_REG(name) uint64_t r ## name

Am I right?

>-----Original Message-----
>From: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx 
>[mailto:xen-devel-bounces@xxxxxxxxxxxxxxxxxxx] On Behalf Of Li, Xin B
>Sent: 2006年12月13日 20:13
>To: Keir Fraser
>Cc: Xen Development Mailing List
>Subject: [Xen-devel] Definition of eax and rax
>Keir, just noticed the macro:
>#define __DECL_REG(name) union { uint64_t r ## name, e ## name; }
>So, rax and eax are both 64bit, but I think we'd better define eax to
>32bit, how do you think?
>Xen-devel mailing list

Xen-devel mailing list



Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.