Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
3a29e876
Commit
3a29e876
authored
Jan 06, 2013
by
André Hentschel
Committed by
Alexandre Julliard
Jan 07, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winedbg: Use a switch-case style implementation in thumb2_disasm_dataprocessing.
parent
2b9555fb
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
12 deletions
+15
-12
be_arm.c
programs/winedbg/be_arm.c
+15
-12
No files found.
programs/winedbg/be_arm.c
View file @
3a29e876
...
...
@@ -1057,7 +1057,9 @@ static UINT thumb2_disasm_dataprocessing(UINT inst, ADDRESS64 *addr)
WORD
op
=
(
inst
>>
20
)
&
0x1f
;
WORD
imm5
=
((
inst
>>
10
)
&
0x1c
)
+
((
inst
>>
6
)
&
0x03
);
if
(
op
==
0
)
switch
(
op
)
{
case
0
:
{
WORD
offset
=
((
inst
>>
15
)
&
0x0800
)
+
((
inst
>>
4
)
&
0x0700
)
+
(
inst
&
0xff
);
if
(
get_nibble
(
inst
,
4
)
==
15
)
...
...
@@ -1070,8 +1072,8 @@ static UINT thumb2_disasm_dataprocessing(UINT inst, ADDRESS64 *addr)
tbl_regs
[
get_nibble
(
inst
,
4
)],
offset
);
return
0
;
}
if
(
op
==
4
||
op
==
12
)
case
4
:
case
12
:
{
WORD
offset
=
((
inst
>>
15
)
&
0x0800
)
+
((
inst
>>
4
)
&
0xf000
)
+
((
inst
>>
4
)
&
0x0700
)
+
(
inst
&
0xff
);
...
...
@@ -1079,8 +1081,7 @@ static UINT thumb2_disasm_dataprocessing(UINT inst, ADDRESS64 *addr)
offset
);
return
0
;
}
if
(
op
==
10
)
case
10
:
{
int
offset
=
((
inst
>>
15
)
&
0x0800
)
+
((
inst
>>
4
)
&
0x0700
)
+
(
inst
&
0xff
);
if
(
get_nibble
(
inst
,
4
)
==
15
)
...
...
@@ -1094,8 +1095,10 @@ static UINT thumb2_disasm_dataprocessing(UINT inst, ADDRESS64 *addr)
tbl_regs
[
get_nibble
(
inst
,
4
)],
offset
);
return
0
;
}
if
(
op
==
16
||
op
==
18
||
op
==
24
||
op
==
26
)
case
16
:
case
18
:
case
24
:
case
26
:
{
BOOL
sign
=
op
<
24
;
WORD
sh
=
(
inst
>>
21
)
&
0x01
;
...
...
@@ -1110,16 +1113,15 @@ static UINT thumb2_disasm_dataprocessing(UINT inst, ADDRESS64 *addr)
sat
,
tbl_regs
[
get_nibble
(
inst
,
4
)]);
return
0
;
}
if
(
op
==
20
||
op
==
28
)
case
20
:
case
28
:
{
WORD
width
=
(
inst
&
0x1f
)
+
1
;
dbg_printf
(
"
\n\t
%s
\t
%s, %s, #%u, #%u"
,
op
==
28
?
"ubfx"
:
"sbfx"
,
tbl_regs
[
get_nibble
(
inst
,
2
)],
tbl_regs
[
get_nibble
(
inst
,
4
)],
imm5
,
width
);
return
0
;
}
if
(
op
==
22
)
case
22
:
{
WORD
msb
=
(
inst
&
0x1f
)
+
1
-
imm5
;
if
(
get_nibble
(
inst
,
4
)
==
15
)
...
...
@@ -1129,8 +1131,9 @@ static UINT thumb2_disasm_dataprocessing(UINT inst, ADDRESS64 *addr)
tbl_regs
[
get_nibble
(
inst
,
4
)],
imm5
,
msb
);
return
0
;
}
default:
return
inst
;
}
}
static
UINT
thumb2_disasm_dataprocessingmod
(
UINT
inst
,
ADDRESS64
*
addr
)
...
...
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