Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
go
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
go
Commits
2c35e548
Commit
2c35e548
authored
Jan 15, 2011
by
Ken Thompson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
arm reg bug MOVW into bool variable
R=r CC=golang-dev
https://golang.org/cl/4034042
parent
7b4495c0
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
15 deletions
+17
-15
src/cmd/5g/reg.c
src/cmd/5g/reg.c
+17
-15
No files found.
src/cmd/5g/reg.c
View file @
2c35e548
...
...
@@ -137,18 +137,16 @@ regopt(Prog *firstp)
uint32
vreg
;
Bits
bit
;
return
;
if
(
first
==
0
)
{
fmtinstall
(
'Q'
,
Qconv
);
}
first
++
;
if
(
debug
[
'K'
])
{
if
(
first
!=
2
0
)
if
(
first
!=
2
)
return
;
//
debug['R'] = 2;
//
debug['P'] = 2;
debug
[
'R'
]
=
2
;
debug
[
'P'
]
=
2
;
print
(
"optimizing %S
\n
"
,
curfn
->
nname
->
sym
);
}
...
...
@@ -480,7 +478,7 @@ brk:
* peep-hole on basic block
*/
if
(
!
debug
[
'R'
]
||
debug
[
'P'
])
{
peep
();
//
peep();
}
/*
...
...
@@ -562,20 +560,24 @@ addmove(Reg *r, int bn, int rn, int f)
default:
print
(
"What is this %E
\n
"
,
v
->
etype
);
case
TINT32
:
case
TUINT32
:
case
TPTR32
:
case
TBOOL
:
p1
->
as
=
AMOVW
;
break
;
case
TINT8
:
case
TUINT8
:
p1
->
as
=
AMOVB
;
break
;
case
TBOOL
:
case
TUINT8
:
p1
->
as
=
AMOVBU
;
break
;
case
TINT16
:
case
TUINT16
:
p1
->
as
=
AMOVH
;
break
;
case
TUINT16
:
p1
->
as
=
AMOVHU
;
break
;
case
TINT32
:
case
TUINT32
:
case
TPTR32
:
p1
->
as
=
AMOVW
;
break
;
case
TFLOAT32
:
p1
->
as
=
AMOVF
;
break
;
...
...
@@ -599,7 +601,7 @@ addmove(Reg *r, int bn, int rn, int f)
a
->
type
=
D_FREG
;
a
->
reg
=
rn
-
NREG
;
}
if
(
v
->
etype
==
TUINT8
)
if
(
v
->
etype
==
TUINT8
||
v
->
etype
==
TBOOL
)
p1
->
as
=
AMOVBU
;
if
(
v
->
etype
==
TUINT16
)
p1
->
as
=
AMOVHU
;
...
...
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