[Mesa-dev] V2 radeonsi use STD430 packing of UBOs by default

Marek Olšák maraeo at gmail.com
Wed Aug 30 15:55:39 UTC 2017


On Wed, Aug 30, 2017 at 2:22 PM, Timothy Arceri <tarceri at itsqueeze.com> wrote:
> On 30/08/17 20:07, Marek Olšák wrote:
>>
>> If LLVM was fixed to do the correct thing, we could enable CONSTBUF
>> LOAD for LLVM 6.0 and later.
>
>
> You seem to think that the compiler *should* be placing them near where they
> are used? What part of LLVM were you expecting to do this? I'm happy to do
> some digging around but don't know where I should start looking.

I think the LLVM machine instruction scheduler should do that. The
starting point would be to add "-print-after-all" to llc or LLVM
arguments in Mesa to have visibility into what LLVM is doing. From
that point it's just about learning to understand that. By default,
LLVM assumes that most or all loads may be affected by any store. LLVM
might also think that the instruction order is OK and doesn't need
changes. I don't know what the exact issue is.

If Natural Selection 2 is the only game showing small changes in
shader-db stats and there are no differences in *real performance* of
NS2 and other apps, I'd say let's merge this.

Marek


More information about the mesa-dev mailing list