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
e1389cac
Commit
e1389cac
authored
Sep 24, 2000
by
Richard Henderson
Committed by
Richard Henderson
Sep 24, 2000
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* emit-rtl.c (gen_lowpart_common): Use trunc_int_for_mode.
From-SVN: r36595
parent
c06aa51e
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
7 deletions
+6
-7
gcc/ChangeLog
+4
-0
gcc/emit-rtl.c
+2
-7
No files found.
gcc/ChangeLog
View file @
e1389cac
2000-09-24 Richard Henderson <rth@cygnus.com>
* emit-rtl.c (gen_lowpart_common): Use trunc_int_for_mode.
2000-09-24 Mark Mitchell <mark@codesourcery.com>
* c-tree.texi: Moved here from cp/ir.texi. Documented nested
...
...
gcc/emit-rtl.c
View file @
e1389cac
...
...
@@ -767,11 +767,7 @@ gen_lowpart_common (mode, x)
{
/* If MODE is twice the host word size, X is already the desired
representation. Otherwise, if MODE is wider than a word, we can't
do this. If MODE is exactly a word, return just one CONST_INT.
If MODE is smaller than a word, clear the bits that don't belong
in our mode, unless they and our sign bit are all one. So we get
either a reasonable negative value or a reasonable unsigned value
for this mode. */
do this. If MODE is exactly a word, return just one CONST_INT. */
if
(
GET_MODE_BITSIZE
(
mode
)
>=
2
*
HOST_BITS_PER_WIDE_INT
)
return
x
;
...
...
@@ -783,12 +779,11 @@ gen_lowpart_common (mode, x)
else
{
/* MODE must be narrower than HOST_BITS_PER_WIDE_INT. */
int
width
=
GET_MODE_BITSIZE
(
mode
);
HOST_WIDE_INT
val
=
(
GET_CODE
(
x
)
==
CONST_INT
?
INTVAL
(
x
)
:
CONST_DOUBLE_LOW
(
x
));
/* Sign extend to HOST_WIDE_INT. */
val
=
val
<<
(
HOST_BITS_PER_WIDE_INT
-
width
)
>>
(
HOST_BITS_PER_WIDE_INT
-
width
);
val
=
trunc_int_for_mode
(
val
,
mode
);
return
(
GET_CODE
(
x
)
==
CONST_INT
&&
INTVAL
(
x
)
==
val
?
x
:
GEN_INT
(
val
));
...
...
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