chromium/third_party/angle/src/libANGLE/renderer/vulkan/SyncVk.cpp

//
// Copyright 2016 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
// SyncVk.cpp:
//    Implements the class methods for SyncVk.
//

#include "libANGLE/renderer/vulkan/SyncVk.h"

#include "common/debug.h"
#include "libANGLE/Context.h"
#include "libANGLE/Display.h"
#include "libANGLE/renderer/vulkan/ContextVk.h"
#include "libANGLE/renderer/vulkan/DisplayVk.h"

#if !defined(ANGLE_PLATFORM_WINDOWS)
#    include <poll.h>
#    include <unistd.h>
#else
#    include <io.h>
#endif

namespace
{
// Wait for file descriptor to be signaled
VkResult SyncWaitFd(int fd, uint64_t timeoutNs, VkResult timeoutResult = VK_TIMEOUT)
{}

// Map VkResult to GLenum
void MapVkResultToGlenum(VkResult vkResult, angle::Result angleResult, void *outResult)
{}

// Map VkResult to EGLint
void MapVkResultToEglint(VkResult result, angle::Result angleResult, void *outResult)
{}

}  // anonymous namespace

namespace rx
{
namespace vk
{
SyncHelper::SyncHelper() {}

SyncHelper::~SyncHelper() {}

void SyncHelper::releaseToRenderer(Renderer *renderer) {}

angle::Result SyncHelper::initialize(ContextVk *contextVk, SyncFenceScope scope)
{}

angle::Result SyncHelper::prepareForClientWait(Context *context,
                                               ContextVk *contextVk,
                                               bool flushCommands,
                                               uint64_t timeout,
                                               VkResult *resultOut)
{}

angle::Result SyncHelper::clientWait(Context *context,
                                     ContextVk *contextVk,
                                     bool flushCommands,
                                     uint64_t timeout,
                                     MapVkResultToApiType mappingFunction,
                                     void *resultOut)
{}

angle::Result SyncHelper::finish(ContextVk *contextVk)
{}

angle::Result SyncHelper::serverWait(ContextVk *contextVk)
{}

angle::Result SyncHelper::getStatus(Context *context, ContextVk *contextVk, bool *signaledOut)
{}

angle::Result SyncHelper::submitSyncIfDeferred(ContextVk *contextVk, RenderPassClosureReason reason)
{}

ExternalFence::ExternalFence()
    :{}

ExternalFence::~ExternalFence()
{}

VkResult ExternalFence::init(VkDevice device, const VkFenceCreateInfo &createInfo)
{}

void ExternalFence::init(int fenceFd)
{}

VkResult ExternalFence::getStatus(VkDevice device) const
{}

VkResult ExternalFence::wait(VkDevice device, uint64_t timeout) const
{}

void ExternalFence::exportFd(VkDevice device, const VkFenceGetFdInfoKHR &fenceGetFdInfo)
{}

SyncHelperNativeFence::SyncHelperNativeFence()
{}

SyncHelperNativeFence::~SyncHelperNativeFence() {}

void SyncHelperNativeFence::releaseToRenderer(Renderer *renderer)
{}

angle::Result SyncHelperNativeFence::initializeWithFd(ContextVk *contextVk, int inFd)
{}

angle::Result SyncHelperNativeFence::prepareForClientWait(Context *context,
                                                          ContextVk *contextVk,
                                                          bool flushCommands,
                                                          uint64_t timeout,
                                                          VkResult *resultOut)
{}

angle::Result SyncHelperNativeFence::clientWait(Context *context,
                                                ContextVk *contextVk,
                                                bool flushCommands,
                                                uint64_t timeout,
                                                MapVkResultToApiType mappingFunction,
                                                void *resultOut)
{}

angle::Result SyncHelperNativeFence::serverWait(ContextVk *contextVk)
{}

angle::Result SyncHelperNativeFence::getStatus(Context *context,
                                               ContextVk *contextVk,
                                               bool *signaledOut)
{}

angle::Result SyncHelperNativeFence::dupNativeFenceFD(Context *context, int *fdOut) const
{}

}  // namespace vk

SyncVk::SyncVk() :{}

SyncVk::~SyncVk() {}

void SyncVk::onDestroy(const gl::Context *context)
{}

angle::Result SyncVk::set(const gl::Context *context, GLenum condition, GLbitfield flags)
{}

angle::Result SyncVk::clientWait(const gl::Context *context,
                                 GLbitfield flags,
                                 GLuint64 timeout,
                                 GLenum *outResult)
{}

angle::Result SyncVk::serverWait(const gl::Context *context, GLbitfield flags, GLuint64 timeout)
{}

angle::Result SyncVk::getStatus(const gl::Context *context, GLint *outResult)
{}

EGLSyncVk::EGLSyncVk() :{}

EGLSyncVk::~EGLSyncVk() {}

void EGLSyncVk::onDestroy(const egl::Display *display)
{}

egl::Error EGLSyncVk::initialize(const egl::Display *display,
                                 const gl::Context *context,
                                 EGLenum type,
                                 const egl::AttributeMap &attribs)
{}

egl::Error EGLSyncVk::clientWait(const egl::Display *display,
                                 const gl::Context *context,
                                 EGLint flags,
                                 EGLTime timeout,
                                 EGLint *outResult)
{}

egl::Error EGLSyncVk::serverWait(const egl::Display *display,
                                 const gl::Context *context,
                                 EGLint flags)
{}

egl::Error EGLSyncVk::getStatus(const egl::Display *display, EGLint *outStatus)
{}

egl::Error EGLSyncVk::dupNativeFenceFD(const egl::Display *display, EGLint *fdOut) const
{}

}  // namespace rx