<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 --- - [Win32] Incorrect alignment of spill slot"
href="http://llvm.org/bugs/show_bug.cgi?id=16126">16126</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>[Win32] Incorrect alignment of spill slot
</td>
</tr>
<tr>
<th>Product</th>
<td>new-bugs
</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>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>new bugs
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>babokin@gmail.com
</td>
</tr>
<tr>
<th>CC</th>
<td>llvmbugs@cs.uiuc.edu
</td>
</tr>
<tr>
<th>Classification</th>
<td>Unclassified
</td>
</tr></table>
<p>
<div>
<pre>Created <span class=""><a href="attachment.cgi?id=10571" name="attach_10571" title="Reproducer">attachment 10571</a> <a href="attachment.cgi?id=10571&action=edit" title="Reproducer">[details]</a></span>
Reproducer
The bug is reproduced on Win32 only, as the platform has small (4-byte) stack
alignment, though the problem may show up on other platforms with small stack
alignment.
To reproduce:
<span class="quote">>llvm-as test.ll
>llc test.bc -march=x86 -o test.s</span >
Now check test.s, which contains the following instruction:
por (%esp), %xmm2 # 16-byte Folded Reload
This is illegal, as %esp is aligned by 4, while por requires memory operand to
be aligned by 16 bytes. This causes an exception (an executable returns error
code -1073741819).
The stack slot is allocated as follows:
# *** IR Dump After Virtual Register Rewriter ***:
# Machine code for function f_fu: Post SSA
Frame Objects:
fi#-3: size=4, align=4, fixed, at location [SP+12]
fi#-2: size=4, align=4, fixed, at location [SP+8]
fi#-1: size=4, align=4, fixed, at location [SP+4]
fi#0: size=16, align=16, at location [SP+4] <<<<<<<<<<<<<<<< here's it.
But it's not clear to me how it can be SP based and aligned by 16, while SP is
aligned by 4.</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>