server: Simplify the naming of the YMM regs.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
f626349c0a
commit
6b86b41912
|
@ -215,8 +215,7 @@ static NTSTATUS context_to_server( context_t *to, const void *src, USHORT machin
|
|||
const XSTATE *xs = (const XSTATE *)((const char *)xctx + xctx->XState.Offset);
|
||||
|
||||
to->flags |= SERVER_CTX_YMM_REGISTERS;
|
||||
if (xs->Mask & 4)
|
||||
memcpy( &to->ymm.ymm_high_regs.ymm_high, &xs->YmmContext, sizeof(xs->YmmContext) );
|
||||
if (xs->Mask & 4) memcpy( &to->ymm.regs.ymm_high, &xs->YmmContext, sizeof(xs->YmmContext) );
|
||||
}
|
||||
return STATUS_SUCCESS;
|
||||
}
|
||||
|
@ -283,8 +282,7 @@ static NTSTATUS context_to_server( context_t *to, const void *src, USHORT machin
|
|||
const XSTATE *xs = (const XSTATE *)((const char *)xctx + xctx->XState.Offset);
|
||||
|
||||
to->flags |= SERVER_CTX_YMM_REGISTERS;
|
||||
if (xs->Mask & 4)
|
||||
memcpy( &to->ymm.ymm_high_regs.ymm_high, &xs->YmmContext, sizeof(xs->YmmContext) );
|
||||
if (xs->Mask & 4) memcpy( &to->ymm.regs.ymm_high, &xs->YmmContext, sizeof(xs->YmmContext) );
|
||||
}
|
||||
return STATUS_SUCCESS;
|
||||
}
|
||||
|
@ -526,11 +524,10 @@ static NTSTATUS context_from_server( void *dst, const context_t *from, USHORT ma
|
|||
|
||||
xs->Mask &= ~4;
|
||||
if (user_shared_data->XState.CompactionEnabled) xs->CompactionMask = 0x8000000000000004;
|
||||
for (i = 0; i < ARRAY_SIZE( from->ymm.ymm_high_regs.ymm_high); i++)
|
||||
for (i = 0; i < ARRAY_SIZE( from->ymm.regs.ymm_high); i++)
|
||||
{
|
||||
if (!from->ymm.ymm_high_regs.ymm_high[i].low && !from->ymm.ymm_high_regs.ymm_high[i].high)
|
||||
continue;
|
||||
memcpy( &xs->YmmContext, &from->ymm.ymm_high_regs, sizeof(xs->YmmContext) );
|
||||
if (!from->ymm.regs.ymm_high[i].low && !from->ymm.regs.ymm_high[i].high) continue;
|
||||
memcpy( &xs->YmmContext, &from->ymm.regs, sizeof(xs->YmmContext) );
|
||||
xs->Mask |= 4;
|
||||
break;
|
||||
}
|
||||
|
@ -604,11 +601,10 @@ static NTSTATUS context_from_server( void *dst, const context_t *from, USHORT ma
|
|||
|
||||
xs->Mask &= ~4;
|
||||
if (user_shared_data->XState.CompactionEnabled) xs->CompactionMask = 0x8000000000000004;
|
||||
for (i = 0; i < ARRAY_SIZE( from->ymm.ymm_high_regs.ymm_high); i++)
|
||||
for (i = 0; i < ARRAY_SIZE( from->ymm.regs.ymm_high); i++)
|
||||
{
|
||||
if (!from->ymm.ymm_high_regs.ymm_high[i].low && !from->ymm.ymm_high_regs.ymm_high[i].high)
|
||||
continue;
|
||||
memcpy( &xs->YmmContext, &from->ymm.ymm_high_regs, sizeof(xs->YmmContext) );
|
||||
if (!from->ymm.regs.ymm_high[i].low && !from->ymm.regs.ymm_high[i].high) continue;
|
||||
memcpy( &xs->YmmContext, &from->ymm.regs, sizeof(xs->YmmContext) );
|
||||
xs->Mask |= 4;
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -156,7 +156,7 @@ typedef struct
|
|||
} ext;
|
||||
union
|
||||
{
|
||||
struct { struct { unsigned __int64 low, high; } ymm_high[16]; } ymm_high_regs;
|
||||
struct { struct { unsigned __int64 low, high; } ymm_high[16]; } regs;
|
||||
} ymm;
|
||||
} context_t;
|
||||
|
||||
|
|
|
@ -172,7 +172,7 @@ typedef struct
|
|||
} ext; /* selected by SERVER_CTX_EXTENDED_REGISTERS */
|
||||
union
|
||||
{
|
||||
struct { struct { unsigned __int64 low, high; } ymm_high[16]; } ymm_high_regs;
|
||||
struct { struct { unsigned __int64 low, high; } ymm_high[16]; } regs;
|
||||
} ymm; /* selected by SERVER_CTX_YMM_REGISTERS */
|
||||
} context_t;
|
||||
|
||||
|
|
|
@ -666,8 +666,8 @@ static void dump_varargs_context( const char *prefix, data_size_t size )
|
|||
dump_uints( ",extended=", (const unsigned int *)ctx.ext.i386_regs,
|
||||
sizeof(ctx.ext.i386_regs) / sizeof(int) );
|
||||
if (ctx.flags & SERVER_CTX_YMM_REGISTERS)
|
||||
dump_uints( ",ymm_high=", (const unsigned int *)ctx.ymm.ymm_high_regs.ymm_high,
|
||||
sizeof(ctx.ymm.ymm_high_regs) / sizeof(int) );
|
||||
dump_uints( ",ymm_high=", (const unsigned int *)ctx.ymm.regs.ymm_high,
|
||||
sizeof(ctx.ymm.regs) / sizeof(int) );
|
||||
break;
|
||||
case IMAGE_FILE_MACHINE_AMD64:
|
||||
fprintf( stderr, "%s{machine=x86_64", prefix );
|
||||
|
@ -719,8 +719,8 @@ static void dump_varargs_context( const char *prefix, data_size_t size )
|
|||
(unsigned int)ctx.fp.x86_64_regs.fpregs[i].low );
|
||||
}
|
||||
if (ctx.flags & SERVER_CTX_YMM_REGISTERS)
|
||||
dump_uints( ",ymm_high=", (const unsigned int *)ctx.ymm.ymm_high_regs.ymm_high,
|
||||
sizeof(ctx.ymm.ymm_high_regs) / sizeof(int) );
|
||||
dump_uints( ",ymm_high=", (const unsigned int *)ctx.ymm.regs.ymm_high,
|
||||
sizeof(ctx.ymm.regs) / sizeof(int) );
|
||||
break;
|
||||
case IMAGE_FILE_MACHINE_ARMNT:
|
||||
fprintf( stderr, "%s{machine=arm", prefix );
|
||||
|
|
Loading…
Reference in New Issue