HomePhabricator

[OpenCL] Handle AddressSpaceConversion when target address space does not…

Description

[OpenCL] Handle AddressSpaceConversion when target address space does not change.

In codegen different address spaces may be mapped to the same address
space for a target, e.g. in x86/x86-64 all address spaces are mapped
to 0. Therefore AddressSpaceConversion should be translated by
CreatePointerBitCastOrAddrSpaceCast instead of CreateAddrSpaceCast.

Differential Revision: http://reviews.llvm.org/D18713

Details

Committed
yaxunlApr 12 2016, 12:03 PM
Differential Revision
D18713: [OpenCL] Generate bitcast when target address space does not change.
Branches
Unknown
Tags
Unknown