EXA: The "optimization" for using a fill operation instead of 1x1 copies
checked the destination drawable's dimensions (!) instead of the tile's. Really....
This commit is contained in:
parent
15f56b203d
commit
1f43d218cc
|
@ -428,7 +428,7 @@ exaCreatePixmap(ScreenPtr pScreen, int w, int h, int depth)
|
||||||
|
|
||||||
if (w > 32767 || h > 32767)
|
if (w > 32767 || h > 32767)
|
||||||
return NullPixmap;
|
return NullPixmap;
|
||||||
|
|
||||||
if (!pScrn->vtSema || pExaScr->swappedOut) {
|
if (!pScrn->vtSema || pExaScr->swappedOut) {
|
||||||
pPixmap = pExaScr->SavedCreatePixmap(pScreen, w, h, depth);
|
pPixmap = pExaScr->SavedCreatePixmap(pScreen, w, h, depth);
|
||||||
} else {
|
} else {
|
||||||
|
@ -1225,7 +1225,7 @@ exaFillRegionTiled (DrawablePtr pDrawable,
|
||||||
STRACE;
|
STRACE;
|
||||||
tileWidth = pTile->drawable.width;
|
tileWidth = pTile->drawable.width;
|
||||||
tileHeight = pTile->drawable.height;
|
tileHeight = pTile->drawable.height;
|
||||||
|
|
||||||
if (pDrawable->width > pExaScr->info->card.maxX ||
|
if (pDrawable->width > pExaScr->info->card.maxX ||
|
||||||
pDrawable->height > pExaScr->info->card.maxY ||
|
pDrawable->height > pExaScr->info->card.maxY ||
|
||||||
tileWidth > pExaScr->info->card.maxX ||
|
tileWidth > pExaScr->info->card.maxX ||
|
||||||
|
@ -1237,7 +1237,7 @@ exaFillRegionTiled (DrawablePtr pDrawable,
|
||||||
/* If we're filling with a solid color, grab it out and go to
|
/* If we're filling with a solid color, grab it out and go to
|
||||||
* FillRegionSolid, saving numerous copies.
|
* FillRegionSolid, saving numerous copies.
|
||||||
*/
|
*/
|
||||||
if (pDrawable->width == 1 && pDrawable->height == 1) {
|
if (tileWidth == 1 && tileHeight == 1) {
|
||||||
CARD32 pixel;
|
CARD32 pixel;
|
||||||
|
|
||||||
exaDrawableUseMemory(&pTile->drawable);
|
exaDrawableUseMemory(&pTile->drawable);
|
||||||
|
|
|
@ -428,7 +428,7 @@ exaCreatePixmap(ScreenPtr pScreen, int w, int h, int depth)
|
||||||
|
|
||||||
if (w > 32767 || h > 32767)
|
if (w > 32767 || h > 32767)
|
||||||
return NullPixmap;
|
return NullPixmap;
|
||||||
|
|
||||||
if (!pScrn->vtSema || pExaScr->swappedOut) {
|
if (!pScrn->vtSema || pExaScr->swappedOut) {
|
||||||
pPixmap = pExaScr->SavedCreatePixmap(pScreen, w, h, depth);
|
pPixmap = pExaScr->SavedCreatePixmap(pScreen, w, h, depth);
|
||||||
} else {
|
} else {
|
||||||
|
@ -1225,7 +1225,7 @@ exaFillRegionTiled (DrawablePtr pDrawable,
|
||||||
STRACE;
|
STRACE;
|
||||||
tileWidth = pTile->drawable.width;
|
tileWidth = pTile->drawable.width;
|
||||||
tileHeight = pTile->drawable.height;
|
tileHeight = pTile->drawable.height;
|
||||||
|
|
||||||
if (pDrawable->width > pExaScr->info->card.maxX ||
|
if (pDrawable->width > pExaScr->info->card.maxX ||
|
||||||
pDrawable->height > pExaScr->info->card.maxY ||
|
pDrawable->height > pExaScr->info->card.maxY ||
|
||||||
tileWidth > pExaScr->info->card.maxX ||
|
tileWidth > pExaScr->info->card.maxX ||
|
||||||
|
@ -1237,7 +1237,7 @@ exaFillRegionTiled (DrawablePtr pDrawable,
|
||||||
/* If we're filling with a solid color, grab it out and go to
|
/* If we're filling with a solid color, grab it out and go to
|
||||||
* FillRegionSolid, saving numerous copies.
|
* FillRegionSolid, saving numerous copies.
|
||||||
*/
|
*/
|
||||||
if (pDrawable->width == 1 && pDrawable->height == 1) {
|
if (tileWidth == 1 && tileHeight == 1) {
|
||||||
CARD32 pixel;
|
CARD32 pixel;
|
||||||
|
|
||||||
exaDrawableUseMemory(&pTile->drawable);
|
exaDrawableUseMemory(&pTile->drawable);
|
||||||
|
|
|
@ -428,7 +428,7 @@ exaCreatePixmap(ScreenPtr pScreen, int w, int h, int depth)
|
||||||
|
|
||||||
if (w > 32767 || h > 32767)
|
if (w > 32767 || h > 32767)
|
||||||
return NullPixmap;
|
return NullPixmap;
|
||||||
|
|
||||||
if (!pScrn->vtSema || pExaScr->swappedOut) {
|
if (!pScrn->vtSema || pExaScr->swappedOut) {
|
||||||
pPixmap = pExaScr->SavedCreatePixmap(pScreen, w, h, depth);
|
pPixmap = pExaScr->SavedCreatePixmap(pScreen, w, h, depth);
|
||||||
} else {
|
} else {
|
||||||
|
@ -1225,7 +1225,7 @@ exaFillRegionTiled (DrawablePtr pDrawable,
|
||||||
STRACE;
|
STRACE;
|
||||||
tileWidth = pTile->drawable.width;
|
tileWidth = pTile->drawable.width;
|
||||||
tileHeight = pTile->drawable.height;
|
tileHeight = pTile->drawable.height;
|
||||||
|
|
||||||
if (pDrawable->width > pExaScr->info->card.maxX ||
|
if (pDrawable->width > pExaScr->info->card.maxX ||
|
||||||
pDrawable->height > pExaScr->info->card.maxY ||
|
pDrawable->height > pExaScr->info->card.maxY ||
|
||||||
tileWidth > pExaScr->info->card.maxX ||
|
tileWidth > pExaScr->info->card.maxX ||
|
||||||
|
@ -1237,7 +1237,7 @@ exaFillRegionTiled (DrawablePtr pDrawable,
|
||||||
/* If we're filling with a solid color, grab it out and go to
|
/* If we're filling with a solid color, grab it out and go to
|
||||||
* FillRegionSolid, saving numerous copies.
|
* FillRegionSolid, saving numerous copies.
|
||||||
*/
|
*/
|
||||||
if (pDrawable->width == 1 && pDrawable->height == 1) {
|
if (tileWidth == 1 && tileHeight == 1) {
|
||||||
CARD32 pixel;
|
CARD32 pixel;
|
||||||
|
|
||||||
exaDrawableUseMemory(&pTile->drawable);
|
exaDrawableUseMemory(&pTile->drawable);
|
||||||
|
|
|
@ -428,7 +428,7 @@ exaCreatePixmap(ScreenPtr pScreen, int w, int h, int depth)
|
||||||
|
|
||||||
if (w > 32767 || h > 32767)
|
if (w > 32767 || h > 32767)
|
||||||
return NullPixmap;
|
return NullPixmap;
|
||||||
|
|
||||||
if (!pScrn->vtSema || pExaScr->swappedOut) {
|
if (!pScrn->vtSema || pExaScr->swappedOut) {
|
||||||
pPixmap = pExaScr->SavedCreatePixmap(pScreen, w, h, depth);
|
pPixmap = pExaScr->SavedCreatePixmap(pScreen, w, h, depth);
|
||||||
} else {
|
} else {
|
||||||
|
@ -1225,7 +1225,7 @@ exaFillRegionTiled (DrawablePtr pDrawable,
|
||||||
STRACE;
|
STRACE;
|
||||||
tileWidth = pTile->drawable.width;
|
tileWidth = pTile->drawable.width;
|
||||||
tileHeight = pTile->drawable.height;
|
tileHeight = pTile->drawable.height;
|
||||||
|
|
||||||
if (pDrawable->width > pExaScr->info->card.maxX ||
|
if (pDrawable->width > pExaScr->info->card.maxX ||
|
||||||
pDrawable->height > pExaScr->info->card.maxY ||
|
pDrawable->height > pExaScr->info->card.maxY ||
|
||||||
tileWidth > pExaScr->info->card.maxX ||
|
tileWidth > pExaScr->info->card.maxX ||
|
||||||
|
@ -1237,7 +1237,7 @@ exaFillRegionTiled (DrawablePtr pDrawable,
|
||||||
/* If we're filling with a solid color, grab it out and go to
|
/* If we're filling with a solid color, grab it out and go to
|
||||||
* FillRegionSolid, saving numerous copies.
|
* FillRegionSolid, saving numerous copies.
|
||||||
*/
|
*/
|
||||||
if (pDrawable->width == 1 && pDrawable->height == 1) {
|
if (tileWidth == 1 && tileHeight == 1) {
|
||||||
CARD32 pixel;
|
CARD32 pixel;
|
||||||
|
|
||||||
exaDrawableUseMemory(&pTile->drawable);
|
exaDrawableUseMemory(&pTile->drawable);
|
||||||
|
|
|
@ -428,7 +428,7 @@ exaCreatePixmap(ScreenPtr pScreen, int w, int h, int depth)
|
||||||
|
|
||||||
if (w > 32767 || h > 32767)
|
if (w > 32767 || h > 32767)
|
||||||
return NullPixmap;
|
return NullPixmap;
|
||||||
|
|
||||||
if (!pScrn->vtSema || pExaScr->swappedOut) {
|
if (!pScrn->vtSema || pExaScr->swappedOut) {
|
||||||
pPixmap = pExaScr->SavedCreatePixmap(pScreen, w, h, depth);
|
pPixmap = pExaScr->SavedCreatePixmap(pScreen, w, h, depth);
|
||||||
} else {
|
} else {
|
||||||
|
@ -1225,7 +1225,7 @@ exaFillRegionTiled (DrawablePtr pDrawable,
|
||||||
STRACE;
|
STRACE;
|
||||||
tileWidth = pTile->drawable.width;
|
tileWidth = pTile->drawable.width;
|
||||||
tileHeight = pTile->drawable.height;
|
tileHeight = pTile->drawable.height;
|
||||||
|
|
||||||
if (pDrawable->width > pExaScr->info->card.maxX ||
|
if (pDrawable->width > pExaScr->info->card.maxX ||
|
||||||
pDrawable->height > pExaScr->info->card.maxY ||
|
pDrawable->height > pExaScr->info->card.maxY ||
|
||||||
tileWidth > pExaScr->info->card.maxX ||
|
tileWidth > pExaScr->info->card.maxX ||
|
||||||
|
@ -1237,7 +1237,7 @@ exaFillRegionTiled (DrawablePtr pDrawable,
|
||||||
/* If we're filling with a solid color, grab it out and go to
|
/* If we're filling with a solid color, grab it out and go to
|
||||||
* FillRegionSolid, saving numerous copies.
|
* FillRegionSolid, saving numerous copies.
|
||||||
*/
|
*/
|
||||||
if (pDrawable->width == 1 && pDrawable->height == 1) {
|
if (tileWidth == 1 && tileHeight == 1) {
|
||||||
CARD32 pixel;
|
CARD32 pixel;
|
||||||
|
|
||||||
exaDrawableUseMemory(&pTile->drawable);
|
exaDrawableUseMemory(&pTile->drawable);
|
||||||
|
|
|
@ -428,7 +428,7 @@ exaCreatePixmap(ScreenPtr pScreen, int w, int h, int depth)
|
||||||
|
|
||||||
if (w > 32767 || h > 32767)
|
if (w > 32767 || h > 32767)
|
||||||
return NullPixmap;
|
return NullPixmap;
|
||||||
|
|
||||||
if (!pScrn->vtSema || pExaScr->swappedOut) {
|
if (!pScrn->vtSema || pExaScr->swappedOut) {
|
||||||
pPixmap = pExaScr->SavedCreatePixmap(pScreen, w, h, depth);
|
pPixmap = pExaScr->SavedCreatePixmap(pScreen, w, h, depth);
|
||||||
} else {
|
} else {
|
||||||
|
@ -1225,7 +1225,7 @@ exaFillRegionTiled (DrawablePtr pDrawable,
|
||||||
STRACE;
|
STRACE;
|
||||||
tileWidth = pTile->drawable.width;
|
tileWidth = pTile->drawable.width;
|
||||||
tileHeight = pTile->drawable.height;
|
tileHeight = pTile->drawable.height;
|
||||||
|
|
||||||
if (pDrawable->width > pExaScr->info->card.maxX ||
|
if (pDrawable->width > pExaScr->info->card.maxX ||
|
||||||
pDrawable->height > pExaScr->info->card.maxY ||
|
pDrawable->height > pExaScr->info->card.maxY ||
|
||||||
tileWidth > pExaScr->info->card.maxX ||
|
tileWidth > pExaScr->info->card.maxX ||
|
||||||
|
@ -1237,7 +1237,7 @@ exaFillRegionTiled (DrawablePtr pDrawable,
|
||||||
/* If we're filling with a solid color, grab it out and go to
|
/* If we're filling with a solid color, grab it out and go to
|
||||||
* FillRegionSolid, saving numerous copies.
|
* FillRegionSolid, saving numerous copies.
|
||||||
*/
|
*/
|
||||||
if (pDrawable->width == 1 && pDrawable->height == 1) {
|
if (tileWidth == 1 && tileHeight == 1) {
|
||||||
CARD32 pixel;
|
CARD32 pixel;
|
||||||
|
|
||||||
exaDrawableUseMemory(&pTile->drawable);
|
exaDrawableUseMemory(&pTile->drawable);
|
||||||
|
|
Loading…
Reference in New Issue