<html>
<head>
<base href="https://bugs.llvm.org/">
</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 - [AArch64] SLH is completely broken with GlobalISel"
href="https://bugs.llvm.org/show_bug.cgi?id=44918">44918</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>[AArch64] SLH is completely broken with GlobalISel
</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>Windows NT
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>enhancement
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>Backend: AArch64
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>efriedma@quicinc.com
</td>
</tr>
<tr>
<th>CC</th>
<td>arnaud.degrandmaison@arm.com, kristof.beyls@arm.com, llvm-bugs@lists.llvm.org, peter.smith@linaro.org, Ties.Stuij@arm.com
</td>
</tr></table>
<p>
<div>
<pre>Testcase:
target triple = "aarch64-unknown-linux-gnu"
define void @foo(i32 %inp, void ()* nocapture %bar) speculative_load_hardening
{
entry:
%cmp = icmp slt i32 %inp, 10
br i1 %cmp, label %if.then, label %if.end
if.then:
tail call void %bar() #1
br label %if.end
if.end:
ret void
}
Build with llc -O0. Produces:
cmp w0, #10 // =10
cset w8, ge
tst w8, #0x3
str x1, [sp, #8] // 8-byte Folded Spill
b.eq .LBB0_2
(LBB0_2 is if.end).
Note the condition is backwards: we branch to if.end if the input is less than
10. Apparently nobody ever did any testing of speculative load hardening at
-O0?</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>