<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">awesome, thanks! will check as soon as it merges into our tree.<div class=""><br class=""></div><div class="">—escha</div><div class=""><br class=""><div><blockquote type="cite" class=""><div class="">On Aug 31, 2017, at 10:07 AM, Topper, Craig <<a href="mailto:craig.topper@intel.com" class="">craig.topper@intel.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div class="WordSection1" style="page: WordSection1; font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px;"><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 11pt; font-family: Calibri, sans-serif; color: rgb(31, 73, 125);" class="">Hopefully fixed with r312253. My attempt at preventing element splits wasn’t’ strong enough.<o:p class=""></o:p></span></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><a name="_MailEndCompose" class=""><span style="font-size: 11pt; font-family: Calibri, sans-serif; color: rgb(31, 73, 125);" class=""><o:p class=""> </o:p></span></a></div><div class=""><div style="border-style: solid none none; border-top-width: 1pt; border-top-color: rgb(225, 225, 225); padding: 3pt 0in 0in;" class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><a name="_____replyseparator" class=""></a><b class=""><span style="font-size: 11pt; font-family: Calibri, sans-serif;" class="">From:</span></b><span style="font-size: 11pt; font-family: Calibri, sans-serif;" class=""><span class="Apple-converted-space"> </span><a href="mailto:fglaser@apple.com" class="">fglaser@apple.com</a> [<a href="mailto:fglaser@apple.com" class="">mailto:fglaser@apple.com</a>]<span class="Apple-converted-space"> </span><b class="">On Behalf Of<span class="Apple-converted-space"> </span></b><a href="mailto:escha@apple.com" class="">escha@apple.com</a><br class=""><b class="">Sent:</b><span class="Apple-converted-space"> </span>Thursday, August 31, 2017 1:41 AM<br class=""><b class="">To:</b><span class="Apple-converted-space"> </span>Topper, Craig <craig.topper@intel.com><br class=""><b class="">Cc:</b><span class="Apple-converted-space"> </span>llvm-commits@lists.llvm.org<br class=""><b class="">Subject:</b><span class="Apple-converted-space"> </span>Re: [llvm] r311892 - [DAGCombiner] Teach visitEXTRACT_SUBVECTOR to turn extracts of BUILD_VECTOR into smaller BUILD_VECTORs<o:p class=""></o:p></span></div></div></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><o:p class=""> </o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class="">Here’s what it looks like.<o:p class=""></o:p></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><o:p class=""> </o:p></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class="">I added debug statements as follows:<o:p class=""></o:p></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><o:p class=""> </o:p></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">  </span><span style="font-size: 8.5pt; font-family: Menlo, serif; color: rgb(62, 30, 129);" class="">fprintf</span><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">(</span><span style="font-size: 8.5pt; font-family: Menlo, serif; color: rgb(120, 73, 42);" class="">stderr</span><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">,</span><span style="font-size: 8.5pt; font-family: Menlo, serif; color: rgb(209, 47, 27);" class="">"foo\n"</span><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">);</span><span style="font-size: 8.5pt; font-family: Menlo, serif; color: rgb(62, 30, 129);" class=""><o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">  V.<span style="color: rgb(49, 89, 93);" class="">dump</span>();<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class=""> <span class="Apple-converted-space"> </span></span><span style="font-size: 8.5pt; font-family: Menlo, serif; color: rgb(0, 132, 0);" class="">// Skip bitcasting<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">  V =<span class="Apple-converted-space"> </span></span><span style="font-size: 8.5pt; font-family: Menlo, serif; color: rgb(49, 89, 93);" class="">peekThroughBitcast</span><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">(V);</span><span style="font-size: 8.5pt; font-family: Menlo, serif; color: rgb(49, 89, 93);" class=""><o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">  V.<span style="color: rgb(49, 89, 93);" class="">dump</span>();<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><o:p class=""> </o:p></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class=""> <span class="Apple-converted-space"> </span></span><span style="font-size: 8.5pt; font-family: Menlo, serif; color: rgb(0, 132, 0);" class="">// If the input is a build vector. Try to make a smaller build vector.<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class=""> <span class="Apple-converted-space"> </span></span><span style="font-size: 8.5pt; font-family: Menlo, serif; color: rgb(186, 45, 162);" class="">if</span><span style="font-size: 8.5pt; font-family: Menlo, serif;" class=""><span class="Apple-converted-space"> </span>(V-></span><span style="font-size: 8.5pt; font-family: Menlo, serif; color: rgb(49, 89, 93);" class="">getOpcode</span><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">() ==<span class="Apple-converted-space"> </span></span><span style="font-size: 8.5pt; font-family: Menlo, serif; color: rgb(79, 129, 135);" class="">ISD</span><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">::</span><span style="font-size: 8.5pt; font-family: Menlo, serif; color: rgb(49, 89, 93);" class="">BUILD_VECTOR</span><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">) {</span><span style="font-size: 8.5pt; font-family: Menlo, serif; color: rgb(49, 89, 93);" class=""><o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">   <span class="Apple-converted-space"> </span><span style="color: rgb(186, 45, 162);" class="">if</span><span class="Apple-converted-space"> </span>(<span style="color: rgb(186, 45, 162);" class="">auto</span><span class="Apple-converted-space"> </span>*Idx = dyn_cast<ConstantSDNode>(N->getOperand(<span style="color: rgb(39, 42, 216);" class="">1</span>))) {<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">     <span class="Apple-converted-space"> </span><span style="color: rgb(79, 129, 135);" class="">EVT</span><span class="Apple-converted-space"> </span>InVT = V-><span style="color: rgb(49, 89, 93);" class="">getValueType</span>(<span style="color: rgb(39, 42, 216);" class="">0</span>);<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">     <span class="Apple-converted-space"> </span><span style="color: rgb(186, 45, 162);" class="">unsigned</span><span class="Apple-converted-space"> </span>NumElems = NVT.<span style="color: rgb(49, 89, 93);" class="">getSizeInBits</span>() / InVT.<span style="color: rgb(49, 89, 93);" class="">getScalarSizeInBits</span>();<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">     <span class="Apple-converted-space"> </span><span style="color: rgb(62, 30, 129);" class="">fprintf</span>(<span style="color: rgb(120, 73, 42);" class="">stderr</span>,<span style="color: rgb(209, 47, 27);" class="">"%d %d %d\n"</span>, NVT.<span style="color: rgb(49, 89, 93);" class="">getSizeInBits</span>(), InVT.<span style="color: rgb(49, 89, 93);" class="">getScalarSizeInBits</span>(), NumElems);<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">     <span class="Apple-converted-space"> </span><span style="color: rgb(186, 45, 162);" class="">if</span><span class="Apple-converted-space"> </span>(NumElems ><span class="Apple-converted-space"> </span><span style="color: rgb(39, 42, 216);" class="">0</span>) {<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">       <span class="Apple-converted-space"> </span><span style="color: rgb(79, 129, 135);" class="">EVT</span><span class="Apple-converted-space"> </span>ExtractVT =<span class="Apple-converted-space"> </span><span style="color: rgb(79, 129, 135);" class="">EVT</span>::<span style="color: rgb(49, 89, 93);" class="">getVectorVT</span>(*<span style="color: rgb(79, 129, 135);" class="">DAG</span>.<span style="color: rgb(49, 89, 93);" class="">getContext</span>(),<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">                                         InVT.<span style="color: rgb(49, 89, 93);" class="">getVectorElementType</span>(), NumElems);<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">       <span class="Apple-converted-space"> </span><span style="color: rgb(186, 45, 162);" class="">if</span><span class="Apple-converted-space"> </span>(!LegalOperations ||<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">            TLI.isOperationLegal(ISD::BUILD_VECTOR, ExtractVT)) {<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">         <span class="Apple-converted-space"> </span><span style="color: rgb(186, 45, 162);" class="">unsigned</span><span class="Apple-converted-space"> </span>IdxVal = Idx->getZExtValue() * NVT.getScalarSizeInBits() /<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">                            InVT.getScalarSizeInBits();<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">         <span class="Apple-converted-space"> </span><span style="color: rgb(62, 30, 129);" class="">fprintf</span>(<span style="color: rgb(120, 73, 42);" class="">stderr</span>,<span style="color: rgb(209, 47, 27);" class="">"%d\n"</span>, IdxVal);<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><o:p class=""> </o:p></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">         <span class="Apple-converted-space"> </span></span><span style="font-size: 8.5pt; font-family: Menlo, serif; color: rgb(0, 132, 0);" class="">// Extract the pieces from the original build_vector.<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">         <span class="Apple-converted-space"> </span><span style="color: rgb(79, 129, 135);" class="">SDValue</span><span class="Apple-converted-space"> </span>BuildVec = DAG.getBuildVector(ExtractVT, SDLoc(N),<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">                                            makeArrayRef(V->op_begin() + IdxVal,<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">                                                         NumElems));<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">          BuildVec.<span style="color: rgb(49, 89, 93);" class="">dump</span>();<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">         <span class="Apple-converted-space"> </span><span style="color: rgb(186, 45, 162);" class="">return</span><span class="Apple-converted-space"> </span><span style="color: rgb(79, 129, 135);" class="">DAG</span>.<span style="color: rgb(49, 89, 93);" class="">getBitcast</span>(NVT, BuildVec);<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">        }<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">      }<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">    }<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">  }<o:p class=""></o:p></span></div></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class=""><o:p class=""> </o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">This results in the following printout<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><o:p class=""> </o:p></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">Combining: t12: v3f16 = extract_subvector t168, Constant:i32<0><o:p class=""></o:p></span></div></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">foo<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">t168: v4f16 = bitcast t167<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">t167: v2f32 = BUILD_VECTOR t164, t166<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">48 32 1<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">0<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">Creating new node: t170: v1f32 = BUILD_VECTOR t164<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">t170: v1f32 = BUILD_VECTOR t164<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">Assertion failed: (VT.getSizeInBits() == Operand.getValueSizeInBits() && "Cannot BITCAST between types of different sizes!"), function getNode, file ../lib/CodeGen/SelectionDAG/SelectionDAG.cpp, line 37<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">97.<o:p class=""></o:p></span></div></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><br class=""><br class=""><o:p class=""></o:p></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class="">Note how what it’s attempting to do here just… doesn’t seem to make much sense, per the printout.<o:p class=""></o:p></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><br class=""><br class=""><o:p class=""></o:p></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class="">—escha<o:p class=""></o:p></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><o:p class=""> </o:p></div><div class=""><blockquote style="margin-top: 5pt; margin-bottom: 5pt;" class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class="">On Aug 30, 2017, at 3:34 PM, Topper, Craig <<a href="mailto:craig.topper@intel.com" style="color: purple; text-decoration: underline;" class="">craig.topper@intel.com</a>> wrote:<o:p class=""></o:p></div></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><o:p class=""> </o:p></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 11pt; font-family: Calibri, sans-serif; color: rgb(31, 73, 125);" class="">Hi Escha,</span><o:p class=""></o:p></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 11pt; font-family: Calibri, sans-serif; color: rgb(31, 73, 125);" class=""> </span><o:p class=""></o:p></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 11pt; font-family: Calibri, sans-serif; color: rgb(31, 73, 125);" class="">This should be calculating the type for the BUILD_VECTOR with same scalar size but less elements. It uses NVT to get the result vector width, and InVT to get the scalar size of the original BUILD_VECTOR. If InVT’s element size is bigger than NVT it gives up.</span><o:p class=""></o:p></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 11pt; font-family: Calibri, sans-serif; color: rgb(31, 73, 125);" class=""> </span><o:p class=""></o:p></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 11pt; font-family: 'Courier New'; color: rgb(31, 73, 125);" class="">      unsigned NumElems = NVT.getSizeInBits() / InVT.getScalarSizeInBits();</span><o:p class=""></o:p></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 11pt; font-family: 'Courier New'; color: rgb(31, 73, 125);" class="">      if (NumElems > 0) {</span><o:p class=""></o:p></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 11pt; font-family: 'Courier New'; color: rgb(31, 73, 125);" class="">        EVT ExtractVT = EVT::getVectorVT(*DAG.getContext(),</span><o:p class=""></o:p></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 11pt; font-family: 'Courier New'; color: rgb(31, 73, 125);" class="">                                         InVT.getVectorElementType(), NumElems);</span><o:p class=""></o:p></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 11pt; font-family: 'Courier New'; color: rgb(31, 73, 125);" class=""> </span><o:p class=""></o:p></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 11pt; font-family: Calibri, sans-serif; color: rgb(31, 73, 125);" class="">Do you have any additional information?</span><o:p class=""></o:p></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 11pt; font-family: Calibri, sans-serif; color: rgb(31, 73, 125);" class=""> </span><o:p class=""></o:p></div></div><div class=""><div style="border-style: solid none none; border-top-width: 1pt; border-top-color: rgb(225, 225, 225); padding: 3pt 0in 0in;" class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><b class=""><span style="font-size: 11pt; font-family: Calibri, sans-serif;" class="">From:</span></b><span class="apple-converted-space"><span style="font-size: 11pt; font-family: Calibri, sans-serif;" class=""> </span></span><span style="font-size: 11pt; font-family: Calibri, sans-serif;" class=""><a href="mailto:fglaser@apple.com" style="color: purple; text-decoration: underline;" class="">fglaser@apple.com</a><span class="Apple-converted-space"> </span>[<a href="mailto:fglaser@apple.com" style="color: purple; text-decoration: underline;" class="">mailto:fglaser@apple.com</a>]<span class="apple-converted-space"> </span><b class="">On Behalf Of<span class="apple-converted-space"> </span></b><a href="mailto:escha@apple.com" style="color: purple; text-decoration: underline;" class="">escha@apple.com</a><br class=""><b class="">Sent:</b><span class="apple-converted-space"> </span>Wednesday, August 30, 2017 3:05 PM<br class=""><b class="">To:</b><span class="apple-converted-space"> </span>Topper, Craig <<a href="mailto:craig.topper@intel.com" style="color: purple; text-decoration: underline;" class="">craig.topper@intel.com</a>><br class=""><b class="">Cc:</b><span class="apple-converted-space"> </span><a href="mailto:llvm-commits@lists.llvm.org" style="color: purple; text-decoration: underline;" class="">llvm-commits@lists.llvm.org</a><br class=""><b class="">Subject:</b><span class="apple-converted-space"> </span>Re: [llvm] r311892 - [DAGCombiner] Teach visitEXTRACT_SUBVECTOR to turn extracts of BUILD_VECTOR into smaller BUILD_VECTORs</span><o:p class=""></o:p></div></div></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""> <o:p class=""></o:p></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class="">This breaks a test on our backend, but I suspect the patch is slightly bugged. Note the following:<o:p class=""></o:p></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""> <o:p class=""></o:p></div></div></div><div class=""><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">  <span style="color: rgb(0, 132, 0);" class="">// Skip bitcasting</span></span><o:p class=""></o:p></div></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">  V =<span class="apple-converted-space"> </span><span style="color: rgb(49, 89, 93);" class="">peekThroughBitcast</span>(V);</span><o:p class=""></o:p></div></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""> <o:p class=""></o:p></div></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class=""> <span class="apple-converted-space"> </span><span style="color: rgb(0, 132, 0);" class="">// If the input is a build vector. Try to make a smaller build vector.</span></span><o:p class=""></o:p></div></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class=""> <span class="apple-converted-space"> </span><span style="color: rgb(186, 45, 162);" class="">if</span><span class="apple-converted-space"> </span>(V-><span style="color: rgb(49, 89, 93);" class="">getOpcode</span>() ==<span class="apple-converted-space"> </span><span style="color: rgb(79, 129, 135);" class="">ISD</span>::<span style="color: rgb(49, 89, 93);" class="">BUILD_VECTOR</span>) {</span><o:p class=""></o:p></div></div></div></div><div class=""><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">    <span style="color: rgb(186, 45, 162);" class="">if</span><span class="apple-converted-space"> </span>(<span style="color: rgb(186, 45, 162);" class="">auto</span><span class="apple-converted-space"> </span>*Idx = dyn_cast<ConstantSDNode>(N->getOperand(<span style="color: rgb(39, 42, 216);" class="">1</span>))) {</span><o:p class=""></o:p></div></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">     <span class="apple-converted-space"> </span><span style="color: rgb(79, 129, 135);" class="">EVT</span><span class="apple-converted-space"> </span>InVT = V-><span style="color: rgb(49, 89, 93);" class="">getValueType</span>(<span style="color: rgb(39, 42, 216);" class="">0</span>);</span><o:p class=""></o:p></div></div></div><div class=""><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">      <span style="color: rgb(186, 45, 162);" class="">unsigned</span><span class="apple-converted-space"> </span>NumElems = NVT.<span style="color: rgb(49, 89, 93);" class="">getSizeInBits</span>() / InVT.<span style="color: rgb(49, 89, 93);" class="">getScalarSizeInBits</span>();</span><o:p class=""></o:p></div></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">     <span class="apple-converted-space"> </span><span style="color: rgb(186, 45, 162);" class="">if</span><span class="apple-converted-space"> </span>(NumElems ><span class="apple-converted-space"> </span><span style="color: rgb(39, 42, 216);" class="">0</span>) {</span><o:p class=""></o:p></div></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">       <span class="apple-converted-space"> </span><span style="color: rgb(79, 129, 135);" class="">EVT</span><span class="apple-converted-space"> </span>ExtractVT =<span class="apple-converted-space"> </span><span style="color: rgb(79, 129, 135);" class="">EVT</span>::<span style="color: rgb(49, 89, 93);" class="">getVectorVT</span>(*<span style="color: rgb(79, 129, 135);" class="">DAG</span>.<span style="color: rgb(49, 89, 93);" class="">getContext</span>(),</span><o:p class=""></o:p></div></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">                                         InVT.<span style="color: rgb(49, 89, 93);" class="">getVectorElementType</span>(), NumElems);</span><o:p class=""></o:p></div></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">       <span class="apple-converted-space"> </span><span style="color: rgb(186, 45, 162);" class="">if</span><span class="apple-converted-space"> </span>(!LegalOperations ||</span><o:p class=""></o:p></div></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">            TLI.isOperationLegal(ISD::BUILD_VECTOR, ExtractVT)) {</span><o:p class=""></o:p></div></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">         <span class="apple-converted-space"> </span><span style="color: rgb(186, 45, 162);" class="">unsigned</span><span class="apple-converted-space"> </span>IdxVal = Idx->getZExtValue() * NVT.getScalarSizeInBits() /</span><o:p class=""></o:p></div></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">                            InVT.getScalarSizeInBits();</span><o:p class=""></o:p></div></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 9pt; font-family: Helvetica, sans-serif;" class=""> </span><o:p class=""></o:p></div></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">         <span class="apple-converted-space"> </span><span style="color: rgb(0, 132, 0);" class="">// Extract the pieces from the original build_vector.</span></span><o:p class=""></o:p></div></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">         <span class="apple-converted-space"> </span><span style="color: rgb(79, 129, 135);" class="">SDValue</span><span class="apple-converted-space"> </span>BuildVec = DAG.getBuildVector(ExtractVT, SDLoc(N),</span><o:p class=""></o:p></div></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">                                            makeArrayRef(V->op_begin() + IdxVal,</span><o:p class=""></o:p></div></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; background-color: white;" class=""><span style="font-size: 8.5pt; font-family: Menlo, serif;" class="">                                                         NumElems));</span><o:p class=""></o:p></div></div></div></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""> <o:p class=""></o:p></div></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class="">Note how we peak through a bitcast, but then use the original type for much of these calculations. So if the element size changed, we break (in this case, a bitcast from v2f32 to v4f16).<o:p class=""></o:p></div></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""> <o:p class=""></o:p></div></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class="">—escha<o:p class=""></o:p></div></div></div><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""> <o:p class=""></o:p></div></div><div class=""><blockquote style="margin-top: 5pt; margin-bottom: 5pt;" class=""><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class="">On Aug 28, 2017, at 8:28 AM, Craig Topper via llvm-commits <<a href="mailto:llvm-commits@lists.llvm.org" style="color: purple; text-decoration: underline;" class=""><span style="color: purple;" class="">llvm-commits@lists.llvm.org</span></a>> wrote:<o:p class=""></o:p></div></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""> <o:p class=""></o:p></div></div><div class=""><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class="">Author: ctopper<br class="">Date: Mon Aug 28 08:28:33 2017<br class="">New Revision: 311892<br class=""><br class="">URL:<span class="apple-converted-space"> </span><a href="http://llvm.org/viewvc/llvm-project?rev=311892&view=rev" style="color: purple; text-decoration: underline;" class=""><span style="color: purple;" class="">http://llvm.org/viewvc/llvm-project?rev=311892&view=rev</span></a><br class="">Log:<br class="">[DAGCombiner] Teach visitEXTRACT_SUBVECTOR to turn extracts of BUILD_VECTOR into smaller BUILD_VECTORs<br class=""><br class="">Only do this before operations are legalized of BUILD_VECTOR is Legal for the target.<br class=""><br class="">Differential Revision:<span class="apple-converted-space"> </span><a href="https://reviews.llvm.org/D37186" style="color: purple; text-decoration: underline;" class=""><span style="color: purple;" class="">https://reviews.llvm.org/D37186</span></a><br class=""><br class="">Modified:<br class="">   llvm/trunk/lib/CodeGen/SelectionDAG/DAGCombiner.cpp<br class="">   llvm/trunk/test/CodeGen/X86/fold-vector-sext-zext.ll<br class="">   llvm/trunk/test/CodeGen/X86/widen_extract-1.ll<br class=""><br class="">Modified: llvm/trunk/lib/CodeGen/SelectionDAG/DAGCombiner.cpp<br class="">URL:<span class="apple-converted-space"> </span><a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/DAGCombiner.cpp?rev=311892&r1=311891&r2=311892&view=diff" style="color: purple; text-decoration: underline;" class=""><span style="color: purple;" class="">http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/DAGCombiner.cpp?rev=311892&r1=311891&r2=311892&view=diff</span></a><br class="">==============================================================================<br class="">--- llvm/trunk/lib/CodeGen/SelectionDAG/DAGCombiner.cpp (original)<br class="">+++ llvm/trunk/lib/CodeGen/SelectionDAG/DAGCombiner.cpp Mon Aug 28 08:28:33 2017<br class="">@@ -15157,6 +15157,29 @@ SDValue DAGCombiner::visitEXTRACT_SUBVEC<br class="">  // Skip bitcasting<br class="">  V = peekThroughBitcast(V);<br class=""><br class="">+  // If the input is a build vector. Try to make a smaller build vector.<br class="">+  if (V->getOpcode() == ISD::BUILD_VECTOR) {<br class="">+    if (auto *Idx = dyn_cast<ConstantSDNode>(N->getOperand(1))) {<br class="">+      EVT InVT = V->getValueType(0);<br class="">+      unsigned NumElems = NVT.getSizeInBits() / InVT.getScalarSizeInBits();<br class="">+      if (NumElems > 0) {<br class="">+        EVT ExtractVT = EVT::getVectorVT(*DAG.getContext(),<br class="">+                                         InVT.getVectorElementType(), NumElems);<br class="">+        if (!LegalOperations ||<br class="">+            TLI.isOperationLegal(ISD::BUILD_VECTOR, ExtractVT)) {<br class="">+          unsigned IdxVal = Idx->getZExtValue() * NVT.getScalarSizeInBits() /<br class="">+                            InVT.getScalarSizeInBits();<br class="">+<br class="">+          // Extract the pieces from the original build_vector.<br class="">+          SDValue BuildVec = DAG.getBuildVector(ExtractVT, SDLoc(N),<br class="">+                                            makeArrayRef(V->op_begin() + IdxVal,<br class="">+                                                         NumElems));<br class="">+          return DAG.getBitcast(NVT, BuildVec);<br class="">+        }<br class="">+      }<br class="">+    }<br class="">+  }<br class="">+<br class="">  if (V->getOpcode() == ISD::INSERT_SUBVECTOR) {<br class="">    // Handle only simple case where vector being inserted and vector<br class="">    // being extracted are of same size.<br class=""><br class="">Modified: llvm/trunk/test/CodeGen/X86/fold-vector-sext-zext.ll<br class="">URL:<span class="apple-converted-space"> </span><a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/fold-vector-sext-zext.ll?rev=311892&r1=311891&r2=311892&view=diff" style="color: purple; text-decoration: underline;" class=""><span style="color: purple;" class="">http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/fold-vector-sext-zext.ll?rev=311892&r1=311891&r2=311892&view=diff</span></a><br class="">==============================================================================<br class="">--- llvm/trunk/test/CodeGen/X86/fold-vector-sext-zext.ll (original)<br class="">+++ llvm/trunk/test/CodeGen/X86/fold-vector-sext-zext.ll Mon Aug 28 08:28:33 2017<br class="">@@ -83,8 +83,7 @@ define <4 x i32> @test_sext_4i8_4i32_und<br class="">define <4 x i64> @test_sext_4i8_4i64() {<br class="">; X32-LABEL: test_sext_4i8_4i64:<br class="">; X32:       # BB#0:<br class="">-; X32-NEXT:    vmovaps {{.*#+}} xmm0 = [0,0,4294967295,4294967295]<br class="">-; X32-NEXT:    vinsertf128 $1, {{\.LCPI.*}}, %ymm0, %ymm0<br class="">+; X32-NEXT:    vmovaps {{.*#+}} ymm0 = [0,0,4294967295,4294967295,2,0,4294967293,4294967295]<br class="">; X32-NEXT:    retl<br class="">;<br class="">; X64-LABEL: test_sext_4i8_4i64:<br class="">@@ -102,8 +101,7 @@ define <4 x i64> @test_sext_4i8_4i64() {<br class="">define <4 x i64> @test_sext_4i8_4i64_undef() {<br class="">; X32-LABEL: test_sext_4i8_4i64_undef:<br class="">; X32:       # BB#0:<br class="">-; X32-NEXT:    vpcmpeqd %xmm0, %xmm0, %xmm0<br class="">-; X32-NEXT:    vinsertf128 $1, {{\.LCPI.*}}, %ymm0, %ymm0<br class="">+; X32-NEXT:    vmovaps {{.*#+}} ymm0 = <u,u,4294967295,4294967295,u,u,4294967293,4294967295><br class="">; X32-NEXT:    retl<br class="">;<br class="">; X64-LABEL: test_sext_4i8_4i64_undef:<br class="">@@ -245,8 +243,7 @@ define <4 x i32> @test_zext_4i8_4i32() {<br class="">define <4 x i64> @test_zext_4i8_4i64() {<br class="">; X32-LABEL: test_zext_4i8_4i64:<br class="">; X32:       # BB#0:<br class="">-; X32-NEXT:    vmovaps {{.*#+}} xmm0 = [0,0,255,0]<br class="">-; X32-NEXT:    vinsertf128 $1, {{\.LCPI.*}}, %ymm0, %ymm0<br class="">+; X32-NEXT:    vmovaps {{.*#+}} ymm0 = [0,0,255,0,2,0,253,0]<br class="">; X32-NEXT:    retl<br class="">;<br class="">; X64-LABEL: test_zext_4i8_4i64:<br class="">@@ -300,10 +297,7 @@ define <4 x i32> @test_zext_4i8_4i32_und<br class="">define <4 x i64> @test_zext_4i8_4i64_undef() {<br class="">; X32-LABEL: test_zext_4i8_4i64_undef:<br class="">; X32:       # BB#0:<br class="">-; X32-NEXT:    vmovaps {{.*#+}} xmm0 = <u,u,255,0><br class="">-; X32-NEXT:    movl $2, %eax<br class="">-; X32-NEXT:    vmovd %eax, %xmm1<br class="">-; X32-NEXT:    vinsertf128 $1, %xmm1, %ymm0, %ymm0<br class="">+; X32-NEXT:    vmovaps {{.*#+}} ymm0 = <u,u,255,0,2,0,u,u><br class="">; X32-NEXT:    retl<br class="">;<br class="">; X64-LABEL: test_zext_4i8_4i64_undef:<br class=""><br class="">Modified: llvm/trunk/test/CodeGen/X86/widen_extract-1.ll<br class="">URL:<span class="apple-converted-space"> </span><a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/widen_extract-1.ll?rev=311892&r1=311891&r2=311892&view=diff" style="color: purple; text-decoration: underline;" class=""><span style="color: purple;" class="">http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/widen_extract-1.ll?rev=311892&r1=311891&r2=311892&view=diff</span></a><br class="">==============================================================================<br class="">--- llvm/trunk/test/CodeGen/X86/widen_extract-1.ll (original)<br class="">+++ llvm/trunk/test/CodeGen/X86/widen_extract-1.ll Mon Aug 28 08:28:33 2017<br class="">@@ -7,8 +7,8 @@<br class="">define void @convert(<2 x double>* %dst.addr, <3 x double> %src)  {<br class="">; X32-LABEL: convert:<br class="">; X32:       # BB#0: # %entry<br class="">-; X32-NEXT:    movups {{[0-9]+}}(%esp), %xmm0<br class="">; X32-NEXT:    movl {{[0-9]+}}(%esp), %eax<br class="">+; X32-NEXT:    movups {{[0-9]+}}(%esp), %xmm0<br class="">; X32-NEXT:    movaps %xmm0, (%eax)<br class="">; X32-NEXT:    retl<br class="">;<br class=""><br class=""><br class="">_______________________________________________<br class="">llvm-commits mailing list<br class=""><a href="mailto:llvm-commits@lists.llvm.org" style="color: purple; text-decoration: underline;" class=""><span style="color: purple;" class="">llvm-commits@lists.llvm.org</span></a><br class=""><a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits" style="color: purple; text-decoration: underline;" class=""><span style="color: purple;" class="">http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits</span></a></div></div></div></div></blockquote></div></div></div></blockquote></div></div></div></div></blockquote></div><br class=""></div></body></html>