<html>
<head>
<base href="http://llvm.org/bugs/" />
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW --- - lencod miscompiled on Cortex-A15 (byval issue)"
href="http://llvm.org/bugs/show_bug.cgi?id=16393">16393</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>lencod miscompiled on Cortex-A15 (byval issue)
</td>
</tr>
<tr>
<th>Product</th>
<td>libraries
</td>
</tr>
<tr>
<th>Version</th>
<td>trunk
</td>
</tr>
<tr>
<th>Hardware</th>
<td>PC
</td>
</tr>
<tr>
<th>OS</th>
<td>All
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>Backend: ARM
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>benny.kra@gmail.com
</td>
</tr>
<tr>
<th>CC</th>
<td>llvmbugs@cs.uiuc.edu, mren@apple.com, renato.golin@linaro.org, stpworld@narod.ru
</td>
</tr>
<tr>
<th>Classification</th>
<td>Unclassified
</td>
</tr></table>
<p>
<div>
<pre>Created <span class=""><a href="attachment.cgi?id=10717" name="attach_10717" title="the miscompiled function">attachment 10717</a> <a href="attachment.cgi?id=10717&action=edit" title="the miscompiled function">[details]</a></span>
the miscompiled function
MultiSource/Applications/JM/lencod has been failing on the arm-lnt buildbot
since r184105. After some investigation it looks like this is caused by broken
byval handling, r184105 only changed spilling decisions and uncovered the
issue.
Attached is IR for the miscompiled function (compile with llc
-mcpu=cortex-a15). It passes a very large object byval. Of particular interest
is the part:
mov r0, #1
mov r1, #2
bl RestoreMVBlock8x8
add sp, sp, #24
add sp, sp, #8192
sub sp, sp, #24
sub sp, sp, #8192
ldm r10, {r2, r3}
mov r1, sp
str r6, [sp, r8]
ldr r0, .LCPI0_0
.LBB0_57: @ %if.then248
@ =>This Inner Loop Header: Depth=1
ldr r7, [r5], #4
subs r0, r0, #4
str r7, [r1], #4
bne .LBB0_57
@ BB#58: @ %if.then248
mov r0, #1
mov r1, #3
bl RestoreMVBlock8x8
add sp, sp, #24
add sp, sp, #8192
sub lr, sp, #4096
sub r0, sp, #4096
ldr r3, [lr, #-4084] @ 4-byte Reload
movw r5, :lower16:img
ldr r12, [r0, #-4068] @ 4-byte Reload
The upper part just looks inefficient, after the second part we end up with a
corrupted stack.</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are on the CC list for the bug.</li>
</ul>
</body>
</html>