<html><head><meta http-equiv="Content-Type" content="text/html charset=us-ascii"><base href="x-msg://595/"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div>Hi Micah, </div><div><br></div><div>We need to fix the documentation here.  We want to be able to convert vectors of integers to vectors of pointers and back.</div><div><br></div><div>There are a few tests such as (/InstCombine/vector_gep1.ll) that check for these conversions. </div><div><br></div><div>Nadav</div><br><div><div>On Oct 10, 2012, at 11:11 AM, "Villmow, Micah" <<a href="mailto:Micah.Villmow@amd.com">Micah.Villmow@amd.com</a>> wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div lang="EN-US" link="blue" vlink="purple" style="font-family: Helvetica; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div class="WordSection1" style="page: WordSection1; "><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; "><a href="http://llvm.org/docs/LangRef.html#i_inttoptr" style="color: purple; text-decoration: underline; ">http://llvm.org/docs/LangRef.html#i_inttoptr</a><o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; "><o:p> </o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; "><span style="font-size: 13.5pt; ">The '</span><tt style="font-family: 'Courier New'; "><span style="font-size: 10pt; ">inttoptr</span></tt><span style="font-size: 13.5pt; ">' instruction takes an<span class="apple-converted-space"> </span></span><a href="http://llvm.org/docs/LangRef.html#t_integer" style="color: purple; text-decoration: underline; "><span style="font-size: 13.5pt; ">integer</span></a><span class="apple-converted-space"><span style="font-size: 13.5pt; "> </span></span><span style="font-size: 13.5pt; ">value to cast, and a type to cast it to, which must be a<span class="apple-converted-space"> </span></span><a href="http://llvm.org/docs/LangRef.html#t_pointer" style="color: purple; text-decoration: underline; "><span style="font-size: 13.5pt; ">pointer</span></a><span class="apple-converted-space"><span style="font-size: 13.5pt; "> </span></span><span style="font-size: 13.5pt; ">type.<o:p></o:p></span></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; "><span style="font-size: 13.5pt; "> </span></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; "><span style="font-size: 13.5pt; ">The final example is:<o:p></o:p></span></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; "><span style="font-size: 10pt; font-family: 'Courier New'; ">%Z = inttoptr <4 x i32> %G to <4 x i8*><i>; yields truncation of vector G to four pointers</i><o:p></o:p></span></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; "><o:p> </o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; "><o:p> </o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; ">The result is not a pointer type, but a vector of pointer types. This violates the restriction of the arguments.<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; "><o:p> </o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; ">Is this an overview, or should this instruction type be illegal?<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; "><o:p> </o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; ">Micah<o:p></o:p></div></div>_______________________________________________<br>LLVM Developers mailing list<br><a href="mailto:LLVMdev@cs.uiuc.edu" style="color: purple; text-decoration: underline; ">LLVMdev@cs.uiuc.edu</a><span class="Apple-converted-space"> </span>        <a href="http://llvm.cs.uiuc.edu" style="color: purple; text-decoration: underline; ">http://llvm.cs.uiuc.edu</a><br><a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev" style="color: purple; text-decoration: underline; ">http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev</a><br></div></blockquote></div><br></body></html>