diff options
author | Adam Jackson <ajax@redhat.com> | 2014-10-09 09:58:06 +0200 |
---|---|---|
committer | Keith Packard <keithp@keithp.com> | 2014-10-23 17:30:32 -0700 |
commit | cffd4e4a4ee615d8583eae78b35017e0d1bfa4f0 (patch) | |
tree | 18ba3c9e5dfe9e3b3bb4ba3f1831c41dc10544e7 /mi | |
parent | de55aafa8f6a9e0dec364bec920d6f91ef2b39f0 (diff) |
mi: Mark the span blit routines as _X_COLD
On gcc, __attribute__((cold)) means:
- consider calls to the function to be unlikely for branch prediction
- optimize the function for size
- emit the function in a dedicated cold text section
It's not worth deleting these routines even though there are no longer
in-tree consumers, but we can at least keep them out of i$ at runtime.
Signed-off-by: Adam Jackson <ajax@redhat.com>
Reviewed-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
Diffstat (limited to 'mi')
-rw-r--r-- | mi/mibitblt.c | 13 | ||||
-rw-r--r-- | mi/mifillrct.c | 2 |
2 files changed, 7 insertions, 8 deletions
diff --git a/mi/mibitblt.c b/mi/mibitblt.c index 08bd1c5b2..114f72d5b 100644 --- a/mi/mibitblt.c +++ b/mi/mibitblt.c @@ -72,7 +72,7 @@ extern int ffs(int); * set them in the destination with SetSpans * We let SetSpans worry about clipping to the destination. */ -RegionPtr +_X_COLD RegionPtr miCopyArea(DrawablePtr pSrcDrawable, DrawablePtr pDstDrawable, GCPtr pGC, @@ -261,8 +261,7 @@ miCopyArea(DrawablePtr pSrcDrawable, * This should be replaced with something more general. mi shouldn't have to * care about such things as scanline padding et alia. */ -static -MiBits * +_X_COLD static MiBits * miGetPlane(DrawablePtr pDraw, int planeNum, /* number of the bitPlane */ int sx, int sy, int w, int h, MiBits * result) { @@ -368,7 +367,7 @@ miGetPlane(DrawablePtr pDraw, int planeNum, /* number of the bitPlane */ * Note how the clipped out bits of the bitmap are always the background * color so that the stipple never causes FillRect to draw them. */ -static void +_X_COLD static void miOpqStipDrawable(DrawablePtr pDraw, GCPtr pGC, RegionPtr prgnSrc, MiBits * pbits, int srcx, int w, int h, int dstx, int dsty) { @@ -510,7 +509,7 @@ miOpqStipDrawable(DrawablePtr pDraw, GCPtr pGC, RegionPtr prgnSrc, * build a source clip * Use the bitmap we've built up as a Stipple for the destination */ -RegionPtr +_X_COLD RegionPtr miCopyPlane(DrawablePtr pSrcDrawable, DrawablePtr pDstDrawable, GCPtr pGC, @@ -599,7 +598,7 @@ miCopyPlane(DrawablePtr pSrcDrawable, * XY format: * get the single plane specified in planemask */ -void +_X_COLD void miGetImage(DrawablePtr pDraw, int sx, int sy, int w, int h, unsigned int format, unsigned long planeMask, char *pDst) { @@ -689,7 +688,7 @@ miGetImage(DrawablePtr pDraw, int sx, int sy, int w, int h, * ZPixmap format: * This part is simple, just call SetSpans */ -void +_X_COLD void miPutImage(DrawablePtr pDraw, GCPtr pGC, int depth, int x, int y, int w, int h, int leftPad, int format, char *pImage) { diff --git a/mi/mifillrct.c b/mi/mifillrct.c index 79c4057d7..faf60498b 100644 --- a/mi/mifillrct.c +++ b/mi/mifillrct.c @@ -65,7 +65,7 @@ SOFTWARE. * then call FillSpans to fill each rectangle. We let FillSpans worry about * clipping to the destination */ -void +_X_COLD void miPolyFillRect(DrawablePtr pDrawable, GCPtr pGC, int nrectFill, /* number of rectangles to fill */ xRectangle *prectInit /* Pointer to first rectangle to fill */ ) |