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
5720520f
Commit
5720520f
authored
Nov 20, 2002
by
Richard Sandiford
Committed by
Richard Sandiford
Nov 20, 2002
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* sched-deps.c (sched_analyze): Check HARD_REGNO_CALL_PART_CLOBBERED.
From-SVN: r59300
parent
4392ebd3
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
40 additions
and
2 deletions
+40
-2
gcc/ChangeLog
+4
-0
gcc/sched-deps.c
+6
-2
gcc/testsuite/ChangeLog
+4
-0
gcc/testsuite/gcc.c-torture/execute/20021120-3.c
+26
-0
No files found.
gcc/ChangeLog
View file @
5720520f
2002
-
11
-
20
Richard
Sandiford
<
rsandifo
@redhat
.
com
>
2002
-
11
-
20
Richard
Sandiford
<
rsandifo
@redhat
.
com
>
*
sched
-
deps
.
c
(
sched_analyze
)
:
Check
HARD_REGNO_CALL_PART_CLOBBERED
.
2002
-
11
-
20
Richard
Sandiford
<
rsandifo
@redhat
.
com
>
*
config
/
sh
/
sh
.
md
(
udivsi3
)
:
Don
'
t
put
udivsi3_i4_media
instructions
*
config
/
sh
/
sh
.
md
(
udivsi3
)
:
Don
'
t
put
udivsi3_i4_media
instructions
into
a
libcall
block
.
into
a
libcall
block
.
(
divsi3
)
:
Likewise
divsi3_i4_media
.
(
divsi3
)
:
Likewise
divsi3_i4_media
.
...
...
gcc/sched-deps.c
View file @
5720520f
...
@@ -1287,8 +1287,12 @@ sched_analyze (deps, head, tail)
...
@@ -1287,8 +1287,12 @@ sched_analyze (deps, head, tail)
SET_REGNO_REG_SET
(
reg_pending_sets
,
i
);
SET_REGNO_REG_SET
(
reg_pending_sets
,
i
);
SET_REGNO_REG_SET
(
reg_pending_uses
,
i
);
SET_REGNO_REG_SET
(
reg_pending_uses
,
i
);
}
}
/* Other call-clobbered hard regs may be clobbered. */
/* Other call-clobbered hard regs may be clobbered.
else
if
(
TEST_HARD_REG_BIT
(
regs_invalidated_by_call
,
i
))
Since we only have a choice between 'might be clobbered'
and 'definitely not clobbered', we must include all
partly call-clobbered registers here. */
else
if
(
HARD_REGNO_CALL_PART_CLOBBERED
(
i
,
reg_raw_mode
[
i
])
||
TEST_HARD_REG_BIT
(
regs_invalidated_by_call
,
i
))
SET_REGNO_REG_SET
(
reg_pending_clobbers
,
i
);
SET_REGNO_REG_SET
(
reg_pending_clobbers
,
i
);
/* We don't know what set of fixed registers might be used
/* We don't know what set of fixed registers might be used
by the function, but it is certain that the stack pointer
by the function, but it is certain that the stack pointer
...
...
gcc/testsuite/ChangeLog
View file @
5720520f
2002-11-20 Richard Sandiford <rsandifo@redhat.com>
2002-11-20 Richard Sandiford <rsandifo@redhat.com>
* gcc.c-torture/execute/20021120-3.c: New test.
2002-11-20 Richard Sandiford <rsandifo@redhat.com>
* gcc.c-torture/execute/20021120-2.c: New test.
* gcc.c-torture/execute/20021120-2.c: New test.
2002-11-20 Richard Sandiford <rsandifo@redhat.com>
2002-11-20 Richard Sandiford <rsandifo@redhat.com>
...
...
gcc/testsuite/gcc.c-torture/execute/20021120-3.c
0 → 100644
View file @
5720520f
/* Test whether a partly call-clobbered register will be moved over a call.
Although the original test case didn't use any GNUisms, it proved
difficult to reduce without the named register extension. */
#if __SH64__ == 32
#define LOC asm ("r10")
#else
#define LOC
#endif
unsigned
int
foo
(
char
*
c
,
unsigned
int
x
,
unsigned
int
y
)
{
register
unsigned
int
z
LOC
;
sprintf
(
c
,
"%d"
,
x
/
y
);
z
=
x
+
1
;
return
z
/
(
y
+
1
);
}
int
main
()
{
char
c
[
16
];
if
(
foo
(
c
,
~
1U
,
4
)
!=
(
~
0U
/
5
))
abort
();
exit
(
0
);
}
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