Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
llvm-epi-0.8
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Analyze
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
Roger Ferrer
llvm-epi-0.8
Commits
e82862e2
Commit
e82862e2
authored
15 years ago
by
David Goodwin
Browse files
Options
Downloads
Patches
Plain Diff
Add Thumb-2 patterns for ARMsrl_flag and ARMsra_flag.
llvm-svn: 77329
parent
bc79816f
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
llvm/lib/Target/ARM/ARMInstrThumb2.td
+10
-1
10 additions, 1 deletion
llvm/lib/Target/ARM/ARMInstrThumb2.td
llvm/test/CodeGen/Thumb2/thumb2-lsr3.ll
+19
-0
19 additions, 0 deletions
llvm/test/CodeGen/Thumb2/thumb2-lsr3.ll
with
29 additions
and
1 deletion
llvm/lib/Target/ARM/ARMInstrThumb2.td
+
10
−
1
View file @
e82862e2
...
...
@@ -715,9 +715,18 @@ defm t2ASR : T2I_sh_ir<"asr", BinOpFrag<(sra node:$LHS, node:$RHS)>>;
defm t2ROR : T2I_sh_ir<"ror", BinOpFrag<(rotr node:$LHS, node:$RHS)>>;
def t2MOVrx : T2sI<(outs GPR:$dst), (ins GPR:$src),
"
mov
", " $dst, $src
, rrx
",
"
rrx
", " $dst, $src",
[(set GPR:$dst, (ARMrrx GPR:$src))]>;
let Defs = [CPSR] in {
def t2MOVsrl_flag : T2XI<(outs GPR:$dst), (ins GPR:$src),
"lsrs.w $dst, $src, #1",
[(set GPR:$dst, (ARMsrl_flag GPR:$src))]>;
def t2MOVsra_flag : T2XI<(outs GPR:$dst), (ins GPR:$src),
"asrs.w $dst, $src, #1",
[(set GPR:$dst, (ARMsra_flag GPR:$src))]>;
}
//===----------------------------------------------------------------------===//
// Bitwise Instructions.
//
...
...
This diff is collapsed.
Click to expand it.
llvm/test/CodeGen/Thumb2/thumb2-lsr3.ll
0 → 100644
+
19
−
0
View file @
e82862e2
; RUN: llvm-as < %s | llc -march=thumb -mattr=+thumb2
define
i1
@test1
(
i64
%poscnt
,
i32
%work
)
{
entry:
; CHECK: rrx r0, r0
; CHECK: lsrs.w r1, r1, #1
%0
=
lshr
i64
%poscnt
,
1
%1
=
icmp
eq
i64
%0
,
0
ret
i1
%1
}
define
i1
@test2
(
i64
%poscnt
,
i32
%work
)
{
entry:
; CHECK: rrx r0, r0
; CHECK: asrs.w r1, r1, #1
%0
=
ashr
i64
%poscnt
,
1
%1
=
icmp
eq
i64
%0
,
0
ret
i1
%1
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment