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
85644414
Commit
85644414
authored
Dec 10, 1993
by
Richard Kenner
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
(modsi3): Rework to operate correctly for both POWER and PowerPC.
From-SVN: r6198
parent
34aaacec
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
10 deletions
+10
-10
gcc/config/rs6000/rs6000.md
+10
-10
No files found.
gcc/config/rs6000/rs6000.md
View file @
85644414
...
...
@@ -763,24 +763,24 @@
}")
(define_expand "modsi3"
[
(set (match_dup 3)
(div:SI (match_operand:SI 1 "gpc_reg_operand" "")
(match_operand:SI 2 "reg_or_cint_operand" "")))
(parallel
[
(set (match_dup 4) (ashift:SI (match_dup 3) (match_dup 5)))
(clobber (scratch:SI))])
(set (match_operand:SI 0 "gpc_reg_operand" "")
(minus:SI (match_dup 1) (match_dup 4)))]
[
(use (match_operand:SI 0 "gpc_reg_operand" ""))
(use (match_operand:SI 1 "gpc_reg_operand" ""))
(use (match_operand:SI 2 "reg_or_cint_operand" ""))]
""
"
{
int i = exact_log2 (INTVAL (operands
[
2
]
));
rtx temp1 = gen_reg_rtx (SImode);
rtx temp2 = gen_reg_rtx (SImode);
if (GET_CODE (operands
[
2
]
) != CONST_INT || i < 0)
FAIL;
operands
[
3
]
= gen_reg_rtx (SImode);
operands
[
4
]
= gen_reg_rtx (SImode);
operands
[
5
]
= gen_rtx (CONST_INT, VOIDmode, i);
emit_insn (gen_divsi3 (temp1, operands
[
1
]
, operands
[
2
]
));
emit_insn (gen_ashlsi3 (temp2, temp1, GEN_INT (i)));
emit_insn (gen_subsi3 (operands
[
0
]
, operands
[
1
]
, temp2));
DONE;
}")
(define_insn ""
...
...
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