[PATCH] D39040: AMDGPU: Fix creating invalid copy when adjusting dmask

Marek Olšák via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Oct 25 07:30:45 PDT 2017


mareko added a comment.

In https://reviews.llvm.org/D39040#906491, @aejsmith wrote:

> With this, when dmask = 0x2, we get "image_get_lod v[0:1], ...". Based on what Marek said, wouldn't it only be returning a single value to v0? What would v1 get set to?
>
> In comparison, for image_sample with dmask = 0x2 I see only a single destination register specified. That's also what I see on the proprietary driver for image_get_lod.


You are right. dmask = 0x2 makes image_get_lod return the 2nd channel as <1 x float>, which will be in v0 in your example.


https://reviews.llvm.org/D39040





More information about the llvm-commits mailing list