Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
Adam Jackson
xserver
Commits
e94ab0b5
Commit
e94ab0b5
authored
Nov 07, 2007
by
Dodji Seketeli
Browse files
Options
Browse Files
Download
Plain Diff
sync with 'master'
parents
26e1fc7b
9bee1c69
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
40 additions
and
8 deletions
+40
-8
exa/exa_migration.c
exa/exa_migration.c
+25
-8
exa/exa_priv.h
exa/exa_priv.h
+1
-0
hw/xfree86/exa/exa.man.pre
hw/xfree86/exa/exa.man.pre
+6
-0
hw/xfree86/exa/examodule.c
hw/xfree86/exa/examodule.c
+8
-0
No files found.
exa/exa_migration.c
View file @
e94ab0b5
...
...
@@ -153,22 +153,39 @@ exaCopyDirty(ExaMigrationPtr migrate, RegionPtr pValidDst, RegionPtr pValidSrc,
REGION_SUBTRACT
(
pScreen
,
&
CopyReg
,
pValidSrc
,
pValidDst
);
if
(
migrate
->
as_dst
)
{
RegionPtr
pending_damage
=
DamagePendingRegion
(
pExaPixmap
->
pDamage
);
ExaScreenPriv
(
pPixmap
->
drawable
.
pScreen
);
if
(
REGION_NIL
(
pending_damage
))
{
static
Bool
firsttime
=
TRUE
;
/* XXX: The pending damage region will be marked as damaged after the
* operation, so it should serve as an upper bound for the region that
* needs to be synchronized for the operation. Unfortunately, this
* causes corruption in some cases, e.g. when starting compiz. See
* https://bugs.freedesktop.org/show_bug.cgi?id=12916 .
*/
if
(
pExaScr
->
optimize_migration
)
{
RegionPtr
pending_damage
=
DamagePendingRegion
(
pExaPixmap
->
pDamage
);
if
(
REGION_NIL
(
pending_damage
))
{
static
Bool
firsttime
=
TRUE
;
if
(
firsttime
)
{
ErrorF
(
"%s: Pending damage region empty!
\n
"
,
__func__
);
firsttime
=
FALSE
;
if
(
firsttime
)
{
ErrorF
(
"%s: Pending damage region empty!
\n
"
,
__func__
);
firsttime
=
FALSE
;
}
}
}
REGION_INTERSECT
(
pScreen
,
&
CopyReg
,
&
CopyReg
,
pending_damage
);
REGION_INTERSECT
(
pScreen
,
&
CopyReg
,
&
CopyReg
,
pending_damage
);
}
/* The caller may provide a region to be subtracted from the calculated
* dirty region. This is to avoid migration of bits that don't
* contribute to the result of the operation.
*/
if
(
migrate
->
pReg
)
REGION_SUBTRACT
(
pScreen
,
&
CopyReg
,
&
CopyReg
,
migrate
->
pReg
);
}
else
{
/* The caller may restrict the region to be migrated for source pixmaps
* to what's relevant for the operation.
*/
if
(
migrate
->
pReg
)
REGION_INTERSECT
(
pScreen
,
&
CopyReg
,
&
CopyReg
,
migrate
->
pReg
);
}
...
...
exa/exa_priv.h
View file @
e94ab0b5
...
...
@@ -119,6 +119,7 @@ typedef struct {
enum
ExaMigrationHeuristic
migration
;
Bool
checkDirtyCorrectness
;
unsigned
disableFbCount
;
Bool
optimize_migration
;
}
ExaScreenPrivRec
,
*
ExaScreenPrivPtr
;
/*
...
...
hw/xfree86/exa/exa.man.pre
View file @
e94ab0b5
...
...
@@ -31,6 +31,12 @@ Disables acceleration of downloading of pixmap data from the framebuffer.
Not usable with drivers which rely on DownloadFromScreen succeeding.
Default: No.
.TP
.BI "Option \*qEXAOptimizeMigration\*q \*q" boolean \*q
Enables an additional optimization for migration of destination pixmaps. This
may improve performance in some cases (e.g. when switching virtual desktops with
no compositing manager) but causes corruption in others (e.g. when starting
compiz). Default: No.
.TP
.BI "Option \*qMigrationHeuristic\*q \*q" anystr \*q
Chooses an alternate pixmap migration heuristic, for debugging purposes. The
default is intended to be the best performing one for general use, though others
...
...
hw/xfree86/exa/examodule.c
View file @
e94ab0b5
...
...
@@ -50,6 +50,7 @@ typedef enum {
EXAOPT_NO_COMPOSITE
,
EXAOPT_NO_UTS
,
EXAOPT_NO_DFS
,
EXAOPT_OPTIMIZE_MIGRATION
}
EXAOpts
;
static
const
OptionInfoRec
EXAOptions
[]
=
{
...
...
@@ -61,6 +62,8 @@ static const OptionInfoRec EXAOptions[] = {
OPTV_BOOLEAN
,
{
0
},
FALSE
},
{
EXAOPT_NO_DFS
,
"EXANoDownloadFromScreen"
,
OPTV_BOOLEAN
,
{
0
},
FALSE
},
{
EXAOPT_OPTIMIZE_MIGRATION
,
"EXAOptimizeMigration"
,
OPTV_BOOLEAN
,
{
0
},
FALSE
},
{
-
1
,
NULL
,
OPTV_NONE
,
{
0
},
FALSE
}
};
...
...
@@ -144,6 +147,11 @@ exaDDXDriverInit(ScreenPtr pScreen)
heuristicName
);
}
}
pExaScr
->
optimize_migration
=
xf86ReturnOptValBool
(
pScreenPriv
->
options
,
EXAOPT_OPTIMIZE_MIGRATION
,
FALSE
);
}
if
(
xf86IsOptionSet
(
pScreenPriv
->
options
,
EXAOPT_NO_COMPOSITE
))
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment