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
a39a7484
Commit
a39a7484
authored
Mar 24, 1996
by
Richard Kenner
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
(negate_rtx): Don't try to negate a constant ourself; instead call
simplify_unary_operation. From-SVN: r11611
parent
3ef00709
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
15 deletions
+6
-15
gcc/expmed.c
+6
-15
No files found.
gcc/expmed.c
View file @
a39a7484
...
...
@@ -185,21 +185,12 @@ negate_rtx (mode, x)
enum
machine_mode
mode
;
rtx
x
;
{
if
(
GET_CODE
(
x
)
==
CONST_INT
)
{
HOST_WIDE_INT
val
=
-
INTVAL
(
x
);
if
(
GET_MODE_BITSIZE
(
mode
)
<
HOST_BITS_PER_WIDE_INT
)
{
/* Sign extend the value from the bits that are significant. */
if
(
val
&
((
HOST_WIDE_INT
)
1
<<
(
GET_MODE_BITSIZE
(
mode
)
-
1
)))
val
|=
(
HOST_WIDE_INT
)
(
-
1
)
<<
GET_MODE_BITSIZE
(
mode
);
else
val
&=
((
HOST_WIDE_INT
)
1
<<
GET_MODE_BITSIZE
(
mode
))
-
1
;
}
return
GEN_INT
(
val
);
}
else
return
expand_unop
(
GET_MODE
(
x
),
neg_optab
,
x
,
NULL_RTX
,
0
);
rtx
result
=
simplify_unary_operation
(
NEG
,
mode
,
x
,
mode
);
if
(
result
=
0
)
result
=
expand_unop
(
mode
,
neg_optab
,
x
,
NULL_RTX
,
0
);
return
result
;
}
/* Generate code to store value from rtx VALUE
...
...
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