What's new

128-bit registers

blueshogun96

A lowdown dirty shame
Ok guys, I was wondering what do you think would be the most efficient way to emulate a 128-bit register? This is the best I could come up with, just wondering if there are any better solutions just in case. For those who don't know, I'm trying to emulate SSE registers. Thanks.

Code:
typedef union _SSEReg
{
 struct _o
 {
#if LITTLE_ENDIAN
  UINT64 l;
  UINT64 h;
#else
  UINT64 h;
  UINT64 l;
#endif
 }o;
} SSEReg;
 

Exophase

Emulator Developer
Ok guys, I was wondering what do you think would be the most efficient way to emulate a 128-bit register? This is the best I could come up with, just wondering if there are any better solutions just in case. For those who don't know, I'm trying to emulate SSE registers. Thanks.

Code:
typedef union _SSEReg
{
 struct _o
 {
#if LITTLE_ENDIAN
  UINT64 l;
  UINT64 h;
#else
  UINT64 h;
  UINT64 l;
#endif
 }o;
} SSEReg;

Do you want a good platform independent method? Because if so I doubt you'll get any better than what you have. If you want a good method for x86 I recommend using its XMM registers, and the datatypes associated (there are intrinsics for this).
 
OP
blueshogun96

blueshogun96

A lowdown dirty shame
Yeah, I'm working on platform independent an core. I'm hoping to see if I can get this to work on even a Mac using a Power PC processor.
 

Top