[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [4485] Fix TCG alignment problems on Sparc64 host
From: |
Fabrice Bellard |
Subject: |
Re: [Qemu-devel] [4485] Fix TCG alignment problems on Sparc64 host |
Date: |
Sun, 18 May 2008 20:18:42 +0200 |
User-agent: |
Thunderbird 1.5.0.9 (X11/20070212) |
I don't understand why TCGLabel needs further alignment. For TCGPool,
the correct fix is either to use the gcc alignment attributes or to
change the type of data to long.
Regards,
Fabrice.
Blue Swirl wrote:
> Revision: 4485
> http://svn.sv.gnu.org/viewvc/?view=rev&root=qemu&revision=4485
> Author: blueswir1
> Date: 2008-05-18 07:49:05 +0000 (Sun, 18 May 2008)
>
> Log Message:
> -----------
> Fix TCG alignment problems on Sparc64 host
>
> Modified Paths:
> --------------
> trunk/tcg/tcg.h
>
> Modified: trunk/tcg/tcg.h
> ===================================================================
> --- trunk/tcg/tcg.h 2008-05-18 06:40:16 UTC (rev 4484)
> +++ trunk/tcg/tcg.h 2008-05-18 07:49:05 UTC (rev 4485)
> @@ -71,7 +71,7 @@
> } TCGRelocation;
>
> typedef struct TCGLabel {
> - int has_value;
> + long has_value; // long instead of int to enforce alignment
> union {
> tcg_target_ulong value;
> TCGRelocation *first_reloc;
> @@ -80,7 +80,7 @@
>
> typedef struct TCGPool {
> struct TCGPool *next;
> - int size;
> + long size; // long instead of int to enforce alignment
> uint8_t data[0];
> } TCGPool;
>
>
>
>
>
>