mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-05 09:09:04 +08:00
Unify programming of binding table base address command
Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
011a0dd497
commit
1b9d50660a
@@ -505,13 +505,9 @@ void EncodeStateBaseAddress<Family>::encode(CommandContainer &container, STATE_B
|
||||
|
||||
if (container.isHeapDirty(HeapType::SURFACE_STATE)) {
|
||||
auto heap = container.getIndirectHeap(HeapType::SURFACE_STATE);
|
||||
auto cmd = Family::cmdInitStateBindingTablePoolAlloc;
|
||||
cmd.setBindingTablePoolBaseAddress(heap->getHeapGpuBase());
|
||||
cmd.setBindingTablePoolBufferSize(heap->getHeapSizeInPages());
|
||||
cmd.setSurfaceObjectControlStateIndexToMocsTables(gmmHelper->getMOCS(GMM_RESOURCE_USAGE_OCL_STATE_HEAP_BUFFER));
|
||||
|
||||
auto buffer = container.getCommandStream()->getSpace(sizeof(cmd));
|
||||
*(typename Family::_3DSTATE_BINDING_TABLE_POOL_ALLOC *)buffer = cmd;
|
||||
StateBaseAddressHelper<Family>::programBindingTableBaseAddress(*container.getCommandStream(),
|
||||
*heap,
|
||||
gmmHelper);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user