chromium/third_party/skia/src/gpu/graphite/QueueManager.cpp

/*
 * Copyright 2022 Google LLC
 *
 * Use of this source code is governed by a BSD-style license that can be
 * found in the LICENSE file.
 */

#include "src/gpu/graphite/QueueManager.h"

#include "include/gpu/graphite/Recording.h"
#include "src/core/SkTraceEvent.h"
#include "src/gpu/RefCntedCallback.h"
#include "src/gpu/graphite/Buffer.h"
#include "src/gpu/graphite/Caps.h"
#include "src/gpu/graphite/CommandBuffer.h"
#include "src/gpu/graphite/ContextPriv.h"
#include "src/gpu/graphite/GpuWorkSubmission.h"
#include "src/gpu/graphite/Log.h"
#include "src/gpu/graphite/RecordingPriv.h"
#include "src/gpu/graphite/Surface_Graphite.h"
#include "src/gpu/graphite/UploadBufferManager.h"
#include "src/gpu/graphite/task/Task.h"

namespace skgpu::graphite {

// This constant determines how many OutstandingSubmissions are allocated together as a block in
// the deque. As such it needs to balance allocating too much memory vs. incurring
// allocation/deallocation thrashing. It should roughly correspond to the max number of outstanding
// submissions we expect to see.
static constexpr int kDefaultOutstandingAllocCnt =;

QueueManager::QueueManager(const SharedContext* sharedContext)
        :{}

QueueManager::~QueueManager() {}

bool QueueManager::setupCommandBuffer(ResourceProvider* resourceProvider) {}

bool QueueManager::addRecording(const InsertRecordingInfo& info, Context* context) {}

bool QueueManager::addTask(Task* task,
                           Context* context) {}

bool QueueManager::addFinishInfo(const InsertFinishInfo& info,
                                 ResourceProvider* resourceProvider,
                                 SkSpan<const sk_sp<Buffer>> buffersToAsyncMap) {}

bool QueueManager::submitToGpu() {}

bool QueueManager::hasUnfinishedGpuWork() {}

void QueueManager::checkForFinishedWork(SyncToCpu sync) {}

void QueueManager::returnCommandBuffer(std::unique_ptr<CommandBuffer> commandBuffer) {}

void QueueManager::addUploadBufferManagerRefs(UploadBufferManager* uploadManager) {}


} // namespace skgpu::graphite