From 40475087a5ee80f5251dac6087142458d8dc7d99 Mon Sep 17 00:00:00 2001 From: Paolo Bonzini Date: Fri, 12 Oct 2012 16:40:41 +0200 Subject: test-i386: QEMU_PACKED is not defined here Signed-off-by: Paolo Bonzini Signed-off-by: Richard Henderson --- tests/tcg/test-i386.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'tests') diff --git a/tests/tcg/test-i386.c b/tests/tcg/test-i386.c index 6dc730d882..b18fe20c76 100644 --- a/tests/tcg/test-i386.c +++ b/tests/tcg/test-i386.c @@ -925,7 +925,7 @@ void test_fbcd(double a) void test_fenv(void) { - struct QEMU_PACKED { + struct __attribute__((__packed__)) { uint16_t fpuc; uint16_t dummy1; uint16_t fpus; @@ -935,7 +935,7 @@ void test_fenv(void) uint32_t ignored[4]; long double fpregs[8]; } float_env32; - struct QEMU_PACKED { + struct __attribute__((__packed__)) { uint16_t fpuc; uint16_t fpus; uint16_t fptag; @@ -1280,7 +1280,7 @@ void test_segs(void) struct { uint32_t offset; uint16_t seg; - } QEMU_PACKED segoff; + } __attribute__((__packed__)) segoff; ldt.entry_number = 1; ldt.base_addr = (unsigned long)&seg_data1; -- cgit v1.2.3-55-g7522 From 1b99f83e3946c447eefb3417ec1ea4c2f3b44582 Mon Sep 17 00:00:00 2001 From: Paolo Bonzini Date: Fri, 12 Oct 2012 16:40:21 +0200 Subject: test-i386: make it compile with a recent gcc Signed-off-by: Paolo Bonzini Signed-off-by: Richard Henderson --- tests/tcg/test-i386.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'tests') diff --git a/tests/tcg/test-i386.c b/tests/tcg/test-i386.c index b18fe20c76..b05572b734 100644 --- a/tests/tcg/test-i386.c +++ b/tests/tcg/test-i386.c @@ -209,7 +209,7 @@ static inline long i2l(long v) #define TEST_LEA16(STR)\ {\ asm(".code16 ; .byte 0x67 ; leal " STR ", %0 ; .code32"\ - : "=wq" (res)\ + : "=r" (res)\ : "a" (eax), "b" (ebx), "c" (ecx), "d" (edx), "S" (esi), "D" (edi));\ printf("lea %s = %08lx\n", STR, res);\ } @@ -1828,7 +1828,7 @@ void test_exceptions(void) printf("lock nop exception:\n"); if (setjmp(jmp_env) == 0) { /* now execute an invalid instruction */ - asm volatile(".byte 0xf0, 0x90"); /* lock nop */ + asm volatile(".byte 0xf0, 0x90"); } printf("INT exception:\n"); -- cgit v1.2.3-55-g7522