[PATCH] D43281: [AMDGPU] fixes for lds f32 builtins

Daniil Fukalov via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Feb 26 07:29:27 PST 2018


dfukalov added a comment.

In https://reviews.llvm.org/D43281#1018657, @arsenm wrote:

> Can’t you just change the description to be the LangAS value? I also thought these happened to be the same already


Am I right that you mean to change the semantic of the addrspace number in a description string for all targets?

At the moment it's finally checked in `ASTContext::getAddrSpaceQualType` that `LangAS` is equal addrspace returned by `QualType`.
And for addrspace "2" specified in description, this `QualType` is "__attribute__((address_space(3))) float". And returns "11" since it's target addrspace, defined in `LangAS` after `FirstTargetAddressSpace`.
So `ASTContext::getAddrSpaceQualType` goes through check `CanT.getAddressSpace() == AddressSpace` and then hits assertions that the parameter already has addrspace specified.


https://reviews.llvm.org/D43281





More information about the cfe-commits mailing list