Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
I
igt-gpu-tools
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
56
Issues
56
List
Boards
Labels
Service Desk
Milestones
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
drm
igt-gpu-tools
Commits
aa0a346d
Commit
aa0a346d
authored
Nov 29, 2010
by
Chris Wilson
🤔
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
decode: Improve parsing of i915 fixed-length indexed primitives
Signed-off-by:
Chris Wilson
<
chris@chris-wilson.co.uk
>
parent
d4d769a4
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
12 deletions
+11
-12
tools/intel_decode.c
tools/intel_decode.c
+11
-12
No files found.
tools/intel_decode.c
View file @
aa0a346d
...
...
@@ -1145,7 +1145,7 @@ decode_3d_primitive(uint32_t *data, int count, uint32_t hw_offset,
int
*
failures
)
{
char
immediate
=
(
data
[
0
]
&
(
1
<<
23
))
==
0
;
unsigned
int
len
,
i
,
ret
;
unsigned
int
len
,
i
,
j
,
ret
;
char
*
primtype
;
int
original_s2
=
saved_s2
;
int
original_s4
=
saved_s4
;
...
...
@@ -1283,19 +1283,18 @@ decode_3d_primitive(uint32_t *data, int count, uint32_t hw_offset,
for
(
i
=
1
;
i
<
count
;
i
++
)
{
if
((
data
[
i
]
&
0xffff
)
==
0xffff
)
{
instr_out
(
data
,
hw_offset
,
i
,
"
indices: (terminator)
\n
"
);
" indices: (terminator)
\n
"
);
ret
=
i
;
goto
out
;
}
else
if
((
data
[
i
]
>>
16
)
==
0xffff
)
{
instr_out
(
data
,
hw_offset
,
i
,
" indices: 0x%04x, "
"(terminator)
\n
"
,
" indices: 0x%04x, (terminator)
\n
"
,
data
[
i
]
&
0xffff
);
ret
=
i
;
goto
out
;
}
else
{
instr_out
(
data
,
hw_offset
,
i
,
"
indices: 0x%04x, 0x%04x
\n
"
,
" indices: 0x%04x, 0x%04x
\n
"
,
data
[
i
]
&
0xffff
,
data
[
i
]
>>
16
);
}
}
...
...
@@ -1306,15 +1305,15 @@ decode_3d_primitive(uint32_t *data, int count, uint32_t hw_offset,
goto
out
;
}
else
{
/* fixed size vertex index buffer */
for
(
i
=
0
;
i
<
len
;
i
+=
2
)
{
for
(
j
=
1
,
i
=
0
;
i
<
len
;
i
+=
2
,
j
++
)
{
if
(
i
*
2
==
len
-
1
)
{
instr_out
(
data
,
hw_offset
,
i
,
"
indices: 0x%04x
\n
"
,
data
[
i
]
&
0xffff
);
instr_out
(
data
,
hw_offset
,
j
,
" indices: 0x%04x
\n
"
,
data
[
j
]
&
0xffff
);
}
else
{
instr_out
(
data
,
hw_offset
,
i
,
"
indices: 0x%04x, 0x%04x
\n
"
,
data
[
i
]
&
0xffff
,
data
[
i
]
>>
16
);
instr_out
(
data
,
hw_offset
,
j
,
" indices: 0x%04x, 0x%04x
\n
"
,
data
[
j
]
&
0xffff
,
data
[
j
]
>>
16
);
}
}
}
...
...
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