[LLVMbugs] [Bug 22476] New: missed store sinking opportunity?
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Thu Feb 5 04:59:25 PST 2015
http://llvm.org/bugs/show_bug.cgi?id=22476
Bug ID: 22476
Summary: missed store sinking opportunity?
Product: libraries
Version: trunk
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P
Component: Loop Optimizer
Assignee: unassignedbugs at nondot.org
Reporter: junyer at gmail.com
CC: llvmbugs at cs.uiuc.edu
Classification: Unclassified
Created attachment 13810
--> http://llvm.org/bugs/attachment.cgi?id=13810&action=edit
function that returns true if a string contains 'a', 'b' or 'c'
It seems as though the `movb $1, %al' could be sunk from BB#3 to BB#4. :)
$ llc abc.ll
$ cat abc.s
.text
.file "abc.ll"
.globl F
.align 16, 0x90
.type F, at function
F: # @F
# BB#0: # %entry
.align 16, 0x90
.LBB0_1: # =>This Inner Loop Header: Depth=1
testl %esi, %esi
je .LBB0_2
# BB#3: # in Loop: Header=BB0_1 Depth=1
movb (%rdi), %al
incq %rdi
decl %esi
addb $-97, %al
movzbl %al, %ecx
movb $1, %al
cmpl $3, %ecx
jae .LBB0_1
# BB#4: # %return_true
# kill: AL<def> AL<kill> EAX<kill>
retq
.LBB0_2:
xorl %eax, %eax
# kill: AL<def> AL<kill> EAX<kill>
retq
.Ltmp0:
.size F, .Ltmp0-F
.section ".note.GNU-stack","", at progbits
$
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20150205/14fda5a3/attachment.html>
More information about the llvm-bugs
mailing list