search for: opaquetyp

Displaying 20 results from an estimated 64 matches for "opaquetyp".

Did you mean: opaquetype
2018 Aug 24
3
OpaqueType:: get()
I have code that uses OpaqueType::get(), it was used to be in llvm/IR/DerivedType.h , but it is removed now. What should I use for it replacement. Also, it is using #include <llvm/Bytecode/WriteBytecodePass.h> , but I do not found any WriteBytecodePass.h in my source code. Please tell me, what should I use in replacement...
2011 Jul 19
3
[LLVMdev] dragonegg svn still broken
On 18 July 2011 15:23, David Blaikie <dblaikie at gmail.com> wrote: > Looks like that break came > from http://llvm.org/viewvc/llvm-project?view=rev&revision=135154 > Judging by this ArrayRef ctor you should be able to simplify those calls by > changing the last two arguments from "&foo, 1" to, simply, "foo". I've done this in r135472. Jay.
2011 Jul 19
0
[LLVMdev] dragonegg svn still broken
...> Jay. Jay, I don't know if this is from a new commit but at r135473, dragonegg svn fails to compile against FSF gcc 4.5.3 with the error... Compiling DefaultABI.cpp /sw/src/fink.build/dragonegg-gcc45-3.0-1/dragonegg-3.0/src/DefaultABI.cpp:194:18: error: use of undeclared identifier 'OpaqueType' Type *OpTy = OpaqueType::get(getGlobalContext()); ^ Jack
2005 Mar 08
0
[LLVMdev] Recursive Types using the llvm support library
...ve type by passing in a pointer to the type you are > constucting. > > An example where something really simple like the line below was output > would be perfect. > > %struct.linked_list = type { %struct.linked_list*, %sbyte* } Use something like this: PATypeHolder StructTy = OpaqueType::get(); std::vector<const Type*> Elts; Elts.push_back(PointerType::get(StructTy)); Elts.push_back(PointerType::get(Type::SByteTy)); StructType *NewSTy = StructType::get(Elts); // At this point, NewSTy = "{ opaque*, sbyte* }", tell VMCore that // the struct and th...
2005 Mar 08
2
[LLVMdev] Recursive Types using the llvm support library
>> An example where something really simple like the line below was output >> would be perfect. >> >> %struct.linked_list = type { %struct.linked_list*, %sbyte* } > > Use something like this: > > PATypeHolder StructTy = OpaqueType::get(); > std::vector<const Type*> Elts; > Elts.push_back(PointerType::get(StructTy)); > Elts.push_back(PointerType::get(Type::SByteTy)); > StructType *NewSTy = StructType::get(Elts); > > // At this point, NewSTy = "{ opaque*, sbyte* }", tell VMCore tha...
2005 Mar 08
3
[LLVMdev] Recursive Types using the llvm support library
As far as I can tell, when you construct a type using the support library StructType::get, you have to pass in a list of types. How can you make a Recursive type by passing in a pointer to the type you are constucting. An example where something really simple like the line below was output would be perfect. %struct.linked_list = type { %struct.linked_list*, %sbyte* } Thanks for any help,
2012 Jul 06
2
[LLVMdev] Self-referential function pointer
...n. This becomes an issue when I have a function which can take a pointer to itself as an argument... our terminology for this is "a recursive procedure". That is, of course, in a context where C-like recursion is not intrinsic to the language. With LLVM 2.9, the solution was to create an OpaqueType when creating the function type signature, use the OpaqueType as the function pointer argument type, and then finish the function type signature later. No problem. If I'm not mistaken, only StructType can be self-referential in LLVM 3.0 and beyond. So, is it not possible to have a self-refere...
2005 Mar 15
2
[LLVMdev] Dynamic Creation of a simple program
Thanks for the information I am trying to use one of your examples for recursive data structures: ========================= PATypeHolder StructTy = OpaqueType::get(); std::vector<const Type*> Elts; Elts.push_back(PointerType::get(StructTy)); Elts.push_back(PointerType::get(Type::SByteTy)); StructType *NewSTy = StructType::get(Elts); // At this point, NewSTy = "{ opaque*, sbyte* }", tell VMCore that // the struct and the opaque type are...
2011 Jul 18
0
[LLVMdev] [Frustration] API breakage
...4/2011 11:23 AM, Jay Foad wrote: > I've updated the release notes for all API changes I've made since 2.9 > was branched: > > http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20110711/123990.html Thanks. But what about the API changes related to the new type system (OpaqueType gone, etc.)? Is that documented somewhere? Shouldn't it be in the release notes as well? I'd really appreciate some hints on how to migrate sources to accommodate these changes. Albert -- Dr. Albert Gr"af Dept. of Music-Informatics, University of Mainz, Germany Email: Dr.Graef a...
2005 Mar 08
0
[LLVMdev] Recursive Types using the llvm support library
...rote: >>> An example where something really simple like the line below was output >>> would be perfect. >>> >>> %struct.linked_list = type { %struct.linked_list*, %sbyte* } >> >> Use something like this: >> >> PATypeHolder StructTy = OpaqueType::get(); >> std::vector<const Type*> Elts; >> Elts.push_back(PointerType::get(StructTy)); >> Elts.push_back(PointerType::get(Type::SByteTy)); >> StructType *NewSTy = StructType::get(Elts); >> >> // At this point, NewSTy = "{ opaque*, sbyte*...
2008 Jan 14
1
[LLVMdev] Opaque type
...ode in LLVM code. I have some problems with the "opaque type", I think because I did not understand how to use. So, the java code is: int[] ai; .... ai = new int[1]; I am using LLVM API in this way: //I create a pointer of Opaque type, because I don't know yet the array size! OpaqueType* ot = OpaqueType::get(); AllocaInst* ptr_addrOP = new AllocaInst(ot, "ai_addr", label_entry); //I create pointer of Array type when it is initialized ArrayType* art = ArrayType::get(Type::IntTy, 1); AllocaInst* ptr_addrAr = new AllocaInst(art, "ai_addr", label_entry); //I tr...
2011 Jul 14
4
[LLVMdev] [Frustration] API breakage
I've updated the release notes for all API changes I've made since 2.9 was branched: http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20110711/123990.html > Preferably all in the same place, in order, with (approx.) revision > numbers where it happened. It'd make our jobs much easier to merge our > local base with trunk. I haven't gone into quite that much
2011 Jun 25
0
[LLVMdev] inefficiencies in ConstantUniqueMap ?
...25 June 2011 13:00, Duncan Sands <baldrick at free.fr> wrote: >> 3. Clang/dragonegg need to adapt to the new API (help appreciated!) > > what needs to be done exactly? Background info: http://www.nondot.org/sabre/LLVMNotes/TypeSystemRewrite.txt As I understand it, PATypeHolder, OpaqueType and the Module's TypeSymbolTable are gone. Instead, StructTypes can optionally be named, and if they are then: - they use name equivalence instead of structural equivalence. - you can create them without any fields, and then add the fields later when the struct is complete. I've played w...
2011 Jun 25
3
[LLVMdev] inefficiencies in ConstantUniqueMap ?
Hi Chris, > 3. Clang/dragonegg need to adapt to the new API (help appreciated!) what needs to be done exactly? Ciao, Duncan.
2005 Mar 15
0
[LLVMdev] Dynamic Creation of a simple program
On Tue, 15 Mar 2005, xavier wrote: > Thanks for the information > I am trying to use one of your examples for recursive data structures: > > ========================= > PATypeHolder StructTy = OpaqueType::get(); > std::vector<const Type*> Elts; > Elts.push_back(PointerType::get(StructTy)); > Elts.push_back(PointerType::get(Type::SByteTy)); > StructType *NewSTy = StructType::get(Elts); > > // At this point, NewSTy = "{ opaque*, sbyte* }", tell VMCore that > // t...
2009 Sep 15
0
[LLVMdev] Opaque types in function parameters
...find an explanation for this? > > Thanks a lot, > > Carlos > _______________________________________________ > LLVM Developers mailing list > LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu > http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev > Every time you call OpaqueType::get, you get a distinct opaque type... they compare unequal. If you call OpaqueType::get once and store the result, and use that same instance in declaring your function and in calling it, it'll match and the assert will go away. In other words, while there is only one i32 type, and using t...
2009 May 07
3
[LLVMdev] Set alignment of a structure?
Hello, Is it possible to set the alignment of a StructType in llvm? Especially in the case that it may contain OpaqueTypes? Thanks, -- Nick Johnson
2008 Jun 13
1
[LLVMdev] code generation order revisited.
...on Henriksen wrote: > > Partially opaque types can be refined. This section of the programmer's > manual is applicable: > > http://llvm.org/docs/ProgrammersManual.html#BuildRecType > > — Gordon Here it is: : // Create the initial outer struct : PATypeHolder StructTy = OpaqueType::get(); : std::vector<const Type*> Elts; : Elts.push_back(PointerType::get(StructTy)); : Elts.push_back(Type::Int32Ty); : StructType *NewSTy = StructType::get(Elts); Here NewSTy is a pointer to StructType. : // At this point, NewSTy = "{ opaque*, i32 }". Tell VMCore that : // the...
2009 Sep 15
2
[LLVMdev] Opaque types in function parameters
Hi all, I am creating a function and trying to call it using the LLVM API. It seems that whenever the function type includes an opaque-typed parameter, the CallInst::Create call causes an assert: Assertion failed: ((i >= FTy->getNumParams() || FTy->getParamType(i) == Params[i]->getType()) && "Calling a function with a bad signature!"), function init, file
2007 May 03
1
[LLVMdev] which g++ to compile LLVM CVS on Linux/AMD64?
....h:1041: warning: type qualifiers ignored on function return type /usr/src/Lang/llvm/include/llvm/ADT/APInt.h:1047: warning: type qualifiers ignored on function return type In file included from APInt.cpp:17: /usr/src/Lang/llvm/include/llvm/DerivedTypes.h: In member function 'virtual void llvm::OpaqueType::refineAbstractType(const llvm::DerivedType*, const llvm::Type*)': /usr/src/Lang/llvm/include/llvm/DerivedTypes.h:412: error: 'abort' was not declared in this scope /usr/src/Lang/llvm/include/llvm/DerivedTypes.h: In member function 'virtual void llvm::OpaqueType::typeBecameConcrete...