[llvm-bugs] [Bug 31630] New: Use AVX-512 packed instructions for scalar FP<->64-bit integer conversions on x86
via llvm-bugs
llvm-bugs at lists.llvm.org
Fri Jan 13 07:37:13 PST 2017
https://llvm.org/bugs/show_bug.cgi?id=31630
Bug ID: 31630
Summary: Use AVX-512 packed instructions for scalar FP<->64-bit
integer conversions on x86
Product: libraries
Version: trunk
Hardware: PC
OS: All
Status: NEW
Severity: normal
Priority: P
Component: Backend: X86
Assignee: unassignedbugs at nondot.org
Reporter: david.l.kreitzer at intel.com
CC: llvm-bugs at lists.llvm.org
Classification: Unclassified
The scalar FP<->64-bit integer conversions are only available for 64-bit
targets, but the packed AVX-512 versions can be used in lieu of the x87
sequences we are currently using in all the following cases. When converting in
the fp->int direction, we should take care to blend in safe values for the
upper elements, zero being the obvious choice.
Compile as "clang -m32 -O2 -S -march=skx" to reproduce.
#include <stdint.h>
uint64_t f1(double x) {
return x;
}
double f2(uint64_t x) {
return x;
}
int64_t f3(double x) {
return x;
}
double f4(int64_t x) {
return x;
}
uint64_t f5(float x) {
return x;
}
float f6(uint64_t x) {
return x;
}
int64_t f7(float x) {
return x;
}
float f8(int64_t x) {
return x;
}
--
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/20170113/d157c8b3/attachment.html>
More information about the llvm-bugs
mailing list