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
f94d0f60
Commit
f94d0f60
authored
Aug 11, 2000
by
Richard Henderson
Committed by
Richard Henderson
Aug 11, 2000
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* combine.c (simplify_shift_const): Obey SHIFT_COUNT_TRUNCATED.
From-SVN: r35622
parent
9c683c2a
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
4 deletions
+14
-4
gcc/ChangeLog
+4
-0
gcc/combine.c
+10
-4
No files found.
gcc/ChangeLog
View file @
f94d0f60
2000-08-11 Richard Henderson <rth@cygnus.com>
* combine.c (simplify_shift_const): Obey SHIFT_COUNT_TRUNCATED.
Thu Aug 10 22:47:09 2000 Ovidiu Predescu <ovidiu@cup.hp.com>
* configure.in:
...
...
gcc/combine.c
View file @
f94d0f60
...
...
@@ -8879,10 +8879,11 @@ simplify_shift_const (x, code, result_mode, varop, input_count)
?
result_mode
:
mode
);
/* Handle cases where the count is greater than the size of the mode
minus 1. For ASHIFT, use the size minus one as the count (this can
occur when simplifying (lshiftrt (ashiftrt ..))). For rotates,
take the count modulo the size. For other shifts, the result is
zero.
minus 1. If SHIFT_COUNT_TRUNCATED, there aren't really any such
cases. Otherwise, for ASHIFT, use the size minus one as the count
(this can occur when simplifying (lshiftrt (ashiftrt ..))). For
rotates, take the count modulo the size. For other shifts, the
result is zero.
Since these shifts are being produced by the compiler by combining
multiple operations, each of which are defined, we know what the
...
...
@@ -8890,6 +8891,11 @@ simplify_shift_const (x, code, result_mode, varop, input_count)
if
(
count
>
GET_MODE_BITSIZE
(
shift_mode
)
-
1
)
{
#ifdef SHIFT_COUNT_TRUNCATED
if
(
SHIFT_COUNT_TRUNCATED
)
count
%=
GET_MODE_BITSIZE
(
shift_mode
);
else
#endif
if
(
code
==
ASHIFTRT
)
count
=
GET_MODE_BITSIZE
(
shift_mode
)
-
1
;
else
if
(
code
==
ROTATE
||
code
==
ROTATERT
)
...
...
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