mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-05 17:41:26 +08:00
DrmGemCloseWorker - remove not used modes of operation.
Change-Id: Ie8524a8411f1022785536a523aad3e4ebea3a349
This commit is contained in:
committed by
sys_ocldev
parent
f90ced1452
commit
06287af541
@@ -78,16 +78,7 @@ FlushStamp DrmCommandStreamReceiver<GfxFamily>::flush(BatchBuffer &batchBuffer,
|
||||
batchBuffer.requiresCoherency,
|
||||
batchBuffer.low_priority);
|
||||
|
||||
if (this->gemCloseWorkerOperationMode == gemCloseWorkerMode::gemCloseWorkerConsumingCommandBuffers) {
|
||||
// Consume all space in CS to force new allocation
|
||||
batchBuffer.stream->replaceBuffer(nullptr, 0);
|
||||
batchBuffer.stream->replaceGraphicsAllocation(nullptr);
|
||||
|
||||
// Push for asynchronous cleanup
|
||||
getMemoryManager()->push(alloc);
|
||||
} else {
|
||||
bb->getResidency()->clear();
|
||||
}
|
||||
bb->getResidency()->clear();
|
||||
}
|
||||
|
||||
return flushStamp;
|
||||
@@ -105,9 +96,6 @@ void DrmCommandStreamReceiver<GfxFamily>::makeResident(GraphicsAllocation &gfxAl
|
||||
template <typename GfxFamily>
|
||||
void DrmCommandStreamReceiver<GfxFamily>::makeResident(BufferObject *bo) {
|
||||
if (bo) {
|
||||
if (this->gemCloseWorkerOperationMode == gemCloseWorkerMode::gemCloseWorkerConsumingCommandBuffers) {
|
||||
bo->reference();
|
||||
}
|
||||
residency.push_back(bo);
|
||||
}
|
||||
}
|
||||
@@ -138,11 +126,6 @@ void DrmCommandStreamReceiver<GfxFamily>::makeNonResident(GraphicsAllocation &gf
|
||||
// If makeNonResident is called before flush, vector will be cleared.
|
||||
if (gfxAllocation.residencyTaskCount != ObjectNotResident) {
|
||||
if (this->residency.size() != 0) {
|
||||
if (this->gemCloseWorkerOperationMode == gemCloseWorkerMode::gemCloseWorkerConsumingCommandBuffers) {
|
||||
for (auto it : residency) {
|
||||
getMemoryManager()->unreference(it);
|
||||
}
|
||||
}
|
||||
this->residency.clear();
|
||||
}
|
||||
if (gfxAllocation.fragmentsStorage.fragmentCount) {
|
||||
|
||||
Reference in New Issue
Block a user