[PATCH 01/13] dix: Re-type and reorder GCRec
Keith Packard
keithp at keithp.com
Tue Nov 23 13:26:58 PST 2010
On Tue, 23 Nov 2010 14:45:36 -0500, Adam Jackson <ajax at redhat.com> wrote:
> No change on ILP32, but shrinks from 160 to 128 bytes on LP64.
>
> Signed-off-by: Adam Jackson <ajax at redhat.com>
> ---
> include/gcstruct.h | 12 ++++++------
> 1 files changed, 6 insertions(+), 6 deletions(-)
>
> diff --git a/include/gcstruct.h b/include/gcstruct.h
> index 4fea02c..767adac 100644
> --- a/include/gcstruct.h
> +++ b/include/gcstruct.h
> @@ -291,9 +291,9 @@ typedef struct _GC {
> unsigned int freeCompClip:1; /* Free composite clip */
> unsigned int scratch_inuse:1; /* is this GC in a pool for reuse? */
> unsigned int unused:13; /* see comment above */
> - unsigned long planemask;
> - unsigned long fgPixel;
> - unsigned long bgPixel;
> + unsigned int planemask;
> + unsigned int fgPixel;
> + unsigned int bgPixel;
unit32_t seems like a better choice.
> /*
> * alas -- both tile and stipple must be here as they
> * are independently specifiable
> @@ -301,11 +301,11 @@ typedef struct _GC {
> PixUnion tile;
> PixmapPtr stipple;
> DDXPointRec patOrg; /* origin for (tile, stipple) */
> - struct _Font *font;
> DDXPointRec clipOrg;
> + struct _Font *font;
> pointer clientClip;
> - unsigned long stateChanges; /* masked with GC_<kind> */
> - unsigned long serialNumber;
> + unsigned int stateChanges; /* masked with GC_<kind> */
> + unsigned int serialNumber;
Looks good, although you could use uint32_t here as well.
--
keith.packard at intel.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://lists.x.org/archives/xorg-devel/attachments/20101123/916064e4/attachment-0001.pgp>
More information about the xorg-devel
mailing list