Displaying 6 results from an estimated 6 matches for "ptraddrspac".
Did you mean:
ptraddrspace
2013 Apr 10
0
[LLVMdev] How to call the llvm.prefetch intrinsic ?
Alexandra,
I'm not sure what you mean by "replace", but I have code that does this to insert prefetches:
Type *I8Ptr = Type::getInt8PtrTy((*I)->getContext(), PtrAddrSpace);
Value *PrefPtrValue = ...
IRBuilder<> Builder(MemI);
Module *M = (*I)->getParent()->getParent();
Type *I32 = Type::getInt32Ty((*I)->getContext());
Value *PrefetchFunc = Intrinsic::getDeclaration(M, Intrinsic::prefetch);
Builder.CreateCall4(Pref...
2013 Apr 10
2
[LLVMdev] How to call the llvm.prefetch intrinsic ?
Hello,
Can anyone please guide me how can I replace a load instruction with a prefetch. I was looking at the intrinsic creation methods of the IRBuilder, but I can only find functions corresponding to memset, memcpy and memmove intrinsics, not for prefetching.
Also, I target x86-64 architectures. Is it sufficient to insert a call to the intrinsic in the LLVM IR to have the corresponding prefetch
2012 Sep 08
2
[LLVMdev] Bitcasts between pointers with different address spaces
...s sense to me. It's more cumbersome to implement, what
with being a new instruction, but I guess that's the price for doing it
right.
The name also needs a bit of work; bitcast works for pointer-to-pointer
conversions, this is specifically changing the address space. Ideas?
'%bar = ptraddrspace i32 addrspace(5)* %foo to i32 addrspace(6)*' and
the types must match except for the addrspace?
Nick
>>> If the address spaces overlap, one should be able to bticast between them.
>>
>> I am not okay with having the verifier accept or reject a bitcast based on the conte...
2012 Sep 08
0
[LLVMdev] Bitcasts between pointers with different address spaces
...e to me. It's more cumbersome to implement, what with being a new instruction, but I guess that's the price for doing it right.
>
> The name also needs a bit of work; bitcast works for pointer-to-pointer conversions, this is specifically changing the address space. Ideas? '%bar = ptraddrspace i32 addrspace(5)* %foo to i32 addrspace(6)*' and the types must match except for the addrspace?
>
I think you have the semantics right here that the types must match expect for the addrspace. How about addrspacecast since it is only changing the address space?
-- Mon Ping
> Nick
&g...
2012 Sep 08
0
[LLVMdev] Bitcasts between pointers with different address spaces
On Sep 7, 2012, at 11:10 PM, Nick Lewycky <nicholas at mxc.ca> wrote:
> Mon Ping Wang wrote:
>> Hi,
>>
>> I don't think we should make bit casts between pointers with different
>> address spaces illegal. Address spaces are not required to be disjoint.
>> In the N1169 spec, it says
>> A non-null pointer into an address space A can be cast to a
2012 Sep 08
2
[LLVMdev] Bitcasts between pointers with different address spaces
Mon Ping Wang wrote:
> Hi,
>
> I don't think we should make bit casts between pointers with different
> address spaces illegal. Address spaces are not required to be disjoint.
> In the N1169 spec, it says
> A non-null pointer into an address space A can be cast to a pointer into
> another address space B, but such a cast is undefined if the source
> pointer does not