[llvm-bugs] [Bug 46162] New: [DebugInfo at O2] SLP Vectorizer drops DebugInfo
via llvm-bugs
llvm-bugs at lists.llvm.org
Mon Jun 1 10:12:38 PDT 2020
https://bugs.llvm.org/show_bug.cgi?id=46162
Bug ID: 46162
Summary: [DebugInfo at O2] SLP Vectorizer drops DebugInfo
Product: libraries
Version: trunk
Hardware: PC
OS: All
Status: NEW
Severity: normal
Priority: P
Component: Scalar Optimizations
Assignee: unassignedbugs at nondot.org
Reporter: Wolfgang_Pieb at playstation.sony.com
CC: llvm-bugs at lists.llvm.org
/* Compile the following source with clang -g -O2. The SLP Vectorizer pass
drops location information for the local variables x1 and x2. */
typedef unsigned int U32;
typedef float F32;
extern "C" double log(float);
extern "C" double sqrt(float);
extern unsigned RandU32();
float RandF32()
{
U32 uRand = RandU32();
F32 fRand = ((F32)uRand / 4294967810.0f);
return(fRand);
}
void randGauss(float work[2])
{
float x1, x2, w;
do {
x1 = 2.f * RandF32() - 1.f;
x2 = 2.f * RandF32() - 1.f;
w = x1 * x1 + x2 * x2;
} while ( w >= 1.f );
w = sqrt( (-2.f * log( w ) ) / w );
work[0] = x1 * w;
work[1] = x2 * w;
}
/* This turns out to be a rather special case, where the same operation is
performed on 2 different local variables in a lexical block. The vectorizer
places the 2 variables in 2 different lanes of a vector register and performs
the operation on both simultaneously.
After some investigation I didn't see an obvious way to fix this. The current
compiler infrastructure seems insufficient to describe what's going on. Given
that ist's a corner case I would consider it low priority. */
--
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/20200601/858409f6/attachment.html>
More information about the llvm-bugs
mailing list