<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 - regression with i386-linux vectors of f16"
href="https://bugs.llvm.org/show_bug.cgi?id=47000">47000</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>regression with i386-linux vectors of f16
</td>
</tr>
<tr>
<th>Product</th>
<td>libraries
</td>
</tr>
<tr>
<th>Version</th>
<td>11.0
</td>
</tr>
<tr>
<th>Hardware</th>
<td>All
</td>
</tr>
<tr>
<th>OS</th>
<td>All
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>release blocker
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>Backend: X86
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>andrew@ziglang.org
</td>
</tr>
<tr>
<th>CC</th>
<td>craig.topper@gmail.com, llvm-bugs@lists.llvm.org, llvm-dev@redking.me.uk, spatel+llvm@rotateright.com
</td>
</tr></table>
<p>
<div>
<pre>Created <span class=""><a href="attachment.cgi?id=23817" name="attach_23817" title="test.ll">attachment 23817</a> <a href="attachment.cgi?id=23817&action=edit" title="test.ll">[details]</a></span>
test.ll
// Zig code:
const std = @import("std");
const Vector = std.meta.Vector;
pub fn main() noreturn {
doTheTestMod(f16, [4]f16{ 4.0, -4.0, 4.0, -4.0 }, [4]f16{ 1.0, 2.0, 0.5,
3.0 });
std.process.exit(0);
}
fn doTheTestMod(comptime T: type, x: Vector(4, T), y: Vector(4, T)) void {
const r1 = @mod(x, y);
}
pub fn panic(msg: []const u8, error_return_trace: ?*std.builtin.StackTrace)
noreturn {
std.process.exit(1);
}
// Compile with: zig build-exe test.zig -target i386-linux-none
// Expected: exit code 0
// Actual: exit code 1
In master branch zig (LLVM 10), the above test case passes. In llvm11 branch of
zig (LLVM release/11.x a9430a1c9e9c99151361374f0462d751457fa15c), it fails due
to `y` having one of the vector elements incorrectly be zero. It compiles
cleanly against a debug build of LLVM 11, not tripping any asserts. Attached is
the LLVM IR of the executable.</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>