[LLVMdev] Inconsistency in the LLVM docs

Villmow, Micah Micah.Villmow at amd.com
Wed Oct 10 12:06:29 PDT 2012


Yes I know, I'm having problems with these tests because they violate the documentation. :)

Micah

From: Nadav Rotem [mailto:nrotem at apple.com]
Sent: Wednesday, October 10, 2012 11:52 AM
To: Villmow, Micah
Cc: llvmdev at cs.uiuc.edu
Subject: Re: [LLVMdev] Inconsistency in the LLVM docs

Hi Micah,

We need to fix the documentation here.  We want to be able to convert vectors of integers to vectors of pointers and back.

There are a few tests such as (/InstCombine/vector_gep1.ll) that check for these conversions.

Nadav

On Oct 10, 2012, at 11:11 AM, "Villmow, Micah" <Micah.Villmow at amd.com<mailto:Micah.Villmow at amd.com>> wrote:


http://llvm.org/docs/LangRef.html#i_inttoptr

The 'inttoptr' instruction takes an integer<http://llvm.org/docs/LangRef.html#t_integer> value to cast, and a type to cast it to, which must be a pointer<http://llvm.org/docs/LangRef.html#t_pointer> type.

The final example is:
%Z = inttoptr <4 x i32> %G to <4 x i8*>; yields truncation of vector G to four pointers


The result is not a pointer type, but a vector of pointer types. This violates the restriction of the arguments.

Is this an overview, or should this instruction type be illegal?

Micah
_______________________________________________
LLVM Developers mailing list
LLVMdev at cs.uiuc.edu<mailto:LLVMdev at cs.uiuc.edu>         http://llvm.cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20121010/af1fa3f0/attachment.html>


More information about the llvm-dev mailing list