Displaying 4 results from an estimated 4 matches for "dispatch_object_s".
2012 Dec 14
2
[LLVMdev] StructType for dispatch_object_t changed by Linker
...ply.
> Probably the types are not defined precisely the same in each module (maybe you
> could send the exact definitions in each module to the mailing list?),
In the module loaded in Step 1 (otherModule):
%struct.dispatch_group_s = type opaque
%union.dispatch_object_t = type { %struct.dispatch_object_s* }
%struct.dispatch_object_s = type opaque
In the module generated in Step 2 (mainModule):
%struct.dispatch_group_s = type {}
%union.dispatch_object_t = type { %struct.dispatch_object_s* }
%struct.dispatch_object_s = type {}
(The LLVM API calls to generate mainModule were generated by calling `...
2012 Dec 14
0
[LLVMdev] StructType for dispatch_object_t changed by Linker
...not defined precisely the same in each module (maybe you
>> could send the exact definitions in each module to the mailing list?),
>
>
> In the module loaded in Step 1 (otherModule):
>
> %struct.dispatch_group_s = type opaque
> %union.dispatch_object_t = type { %struct.dispatch_object_s* }
> %struct.dispatch_object_s = type opaque
>
> In the module generated in Step 2 (mainModule):
>
> %struct.dispatch_group_s = type {}
> %union.dispatch_object_t = type { %struct.dispatch_object_s* }
> %struct.dispatch_object_s = type {}
>
> (The LLVM API calls to ge...
2012 Dec 14
2
[LLVMdev] StructType for dispatch_object_t changed by Linker
...re!"), function init, file Instructions.cpp, line 274.
This happens because the StructType returned by `mod->getTypeByName("union.dispatch_object_t")` is different between Step 2 and Step 4. According to `Type::dump()`, it is:
Step 2: %union.dispatch_object_t = type { %struct.dispatch_object_s* }
Step 4: %union.dispatch_object_t = type { %struct.dispatch_object_s.1* }
Code that reproduces the problem is at http://pastebin.com/pxveBUJa and http://pastebin.com/GDb9n9xA.
A workaround is to call `StructType::create(mod->getContext(), "union.dispatch_object_t")` before doing...
2012 Dec 14
0
[LLVMdev] StructType for dispatch_object_t changed by Linker
Hi Jaymie,
...
> Step 2: %union.dispatch_object_t = type { %struct.dispatch_object_s* }
> Step 4: %union.dispatch_object_t = type { %struct.dispatch_object_s.1* }
>
> Code that reproduces the problem is at http://pastebin.com/pxveBUJa and
> http://pastebin.com/GDb9n9xA.
>
> A workaround is to call
> `StructType::create(mod->getContext(), "union.dispatch...