[Mesa-dev] [PATCH] r300g: only allow byteswapped formats on big endian
Grazvydas Ignotas
notasas at gmail.com
Mon Feb 13 11:10:38 UTC 2017
On Mon, Feb 13, 2017 at 10:22 AM, Michel Dänzer <michel at daenzer.net> wrote:
> On 13/02/17 05:17 PM, Michel Dänzer wrote:
>> On 11/02/17 08:01 AM, Grazvydas Ignotas wrote:
>>> They cause regressions on little endian.
>>>
>>> Fixes: 172bfdaa9e ("r300g: add support for PIPE_FORMAT_x8R8G8B8_*")
>>> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=98869
>>> Signed-off-by: Grazvydas Ignotas <notasas at gmail.com>
>>> ---
>>> no commit access
>>>
>>> src/gallium/drivers/r300/r300_texture.c | 5 +++++
>>> 1 file changed, 5 insertions(+)
>>>
>>> diff --git a/src/gallium/drivers/r300/r300_texture.c b/src/gallium/drivers/r300/r300_texture.c
>>> index fbac07a..929c3fe 100644
>>> --- a/src/gallium/drivers/r300/r300_texture.c
>>> +++ b/src/gallium/drivers/r300/r300_texture.c
>>> @@ -47,6 +47,11 @@
>>> */
>>> static enum pipe_format r300_unbyteswap_array_format(enum pipe_format format)
>>> {
>>> + /* FIXME: Disabled on little endian because of a reported regression:
>>> + * https://bugs.freedesktop.org/show_bug.cgi?id=98869 */
>>> + if (PIPE_ENDIAN_NATIVE != PIPE_ENDIAN_BIG)
>>> + return format;
>>
>> Is there any reason to believe that whatever issue this avoids couldn't
>> happen on big endian hosts as well?
I don't know...
> More to the point, this seems to disable part of the logic needed for
> supporting PIPE_FORMAT_x8R8G8B8_* on little endian, but leaves those
> formats advertised as supported.
Well it just reverts to an earlier working state before Marek's patch
(172bfdaa9e) tor LE.
The patch in question which added support for those formats hasn't
done anything specific related to advertising them, and
r300_is_*_supported() end up indirectly calling
r300_unbyteswap_array_format(), so it looks like nothing specific is
needed for advertisement?
> Did you confirm that there are no
> piglit gpu profile regressions with this patch?
I don't have the hardware and can't test, I just have confirmation
from a user that the regression gets fixed.
Gražvydas
More information about the mesa-dev
mailing list