Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
R
riscv-gcc-1
Overview
Overview
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lvzhengyang
riscv-gcc-1
Commits
e27a1019
Commit
e27a1019
authored
Jul 13, 2007
by
Kaz Kojima
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
sh.c (mark_use): Remove.
* config/sh/sh.c (mark_use): Remove. From-SVN: r126611
parent
cd7b7317
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
81 deletions
+4
-81
gcc/ChangeLog
+4
-0
gcc/config/sh/sh.c
+0
-81
No files found.
gcc/ChangeLog
View file @
e27a1019
2007-07-13 Kaz Kojima <kkojima@gcc.gnu.org>
* config/sh/sh.c (mark_use): Remove.
2007-07-12 Paul Brook <paul@codesourcery.com>
2007-07-12 Paul Brook <paul@codesourcery.com>
* config/arm/arm.c (thumb1_compute_save_reg_mask): Make sure scratch
* config/arm/arm.c (thumb1_compute_save_reg_mask): Make sure scratch
...
...
gcc/config/sh/sh.c
View file @
e27a1019
...
@@ -182,7 +182,6 @@ static rtx push (int);
...
@@ -182,7 +182,6 @@ static rtx push (int);
static
void
pop
(
int
);
static
void
pop
(
int
);
static
void
push_regs
(
HARD_REG_SET
*
,
int
);
static
void
push_regs
(
HARD_REG_SET
*
,
int
);
static
int
calc_live_regs
(
HARD_REG_SET
*
);
static
int
calc_live_regs
(
HARD_REG_SET
*
);
static
void
mark_use
(
rtx
,
rtx
*
);
static
HOST_WIDE_INT
rounded_frame_size
(
int
);
static
HOST_WIDE_INT
rounded_frame_size
(
int
);
static
rtx
mark_constant_pool_use
(
rtx
);
static
rtx
mark_constant_pool_use
(
rtx
);
const
struct
attribute_spec
sh_attribute_table
[];
const
struct
attribute_spec
sh_attribute_table
[];
...
@@ -8378,86 +8377,6 @@ expand_df_binop (rtx (*fun) (rtx, rtx, rtx, rtx), rtx *operands)
...
@@ -8378,86 +8377,6 @@ expand_df_binop (rtx (*fun) (rtx, rtx, rtx, rtx), rtx *operands)
get_fpscr_rtx
()));
get_fpscr_rtx
()));
}
}
/* ??? gcc does flow analysis strictly after common subexpression
elimination. As a result, common subexpression elimination fails
when there are some intervening statements setting the same register.
If we did nothing about this, this would hurt the precision switching
for SH4 badly. There is some cse after reload, but it is unable to
undo the extra register pressure from the unused instructions, and
it cannot remove auto-increment loads.
A C code example that shows this flow/cse weakness for (at least) SH
and sparc (as of gcc ss-970706) is this:
double
f(double a)
{
double d;
d = 0.1;
a += d;
d = 1.1;
d = 0.1;
a *= d;
return a;
}
So we add another pass before common subexpression elimination, to
remove assignments that are dead due to a following assignment in the
same basic block. */
static
void
mark_use
(
rtx
x
,
rtx
*
reg_set_block
)
{
enum
rtx_code
code
;
if
(
!
x
)
return
;
code
=
GET_CODE
(
x
);
switch
(
code
)
{
case
REG
:
{
int
regno
=
REGNO
(
x
);
int
nregs
=
(
regno
<
FIRST_PSEUDO_REGISTER
?
HARD_REGNO_NREGS
(
regno
,
GET_MODE
(
x
))
:
1
);
do
{
reg_set_block
[
regno
+
nregs
-
1
]
=
0
;
}
while
(
--
nregs
);
break
;
}
case
SET
:
{
rtx
dest
=
SET_DEST
(
x
);
if
(
GET_CODE
(
dest
)
==
SUBREG
)
dest
=
SUBREG_REG
(
dest
);
if
(
GET_CODE
(
dest
)
!=
REG
)
mark_use
(
dest
,
reg_set_block
);
mark_use
(
SET_SRC
(
x
),
reg_set_block
);
break
;
}
case
CLOBBER
:
break
;
default
:
{
const
char
*
fmt
=
GET_RTX_FORMAT
(
code
);
int
i
,
j
;
for
(
i
=
GET_RTX_LENGTH
(
code
)
-
1
;
i
>=
0
;
i
--
)
{
if
(
fmt
[
i
]
==
'e'
)
mark_use
(
XEXP
(
x
,
i
),
reg_set_block
);
else
if
(
fmt
[
i
]
==
'E'
)
for
(
j
=
XVECLEN
(
x
,
i
)
-
1
;
j
>=
0
;
j
--
)
mark_use
(
XVECEXP
(
x
,
i
,
j
),
reg_set_block
);
}
break
;
}
}
}
static
rtx
get_free_reg
(
HARD_REG_SET
);
static
rtx
get_free_reg
(
HARD_REG_SET
);
/* This function returns a register to use to load the address to load
/* This function returns a register to use to load the address to load
...
...
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