chromium/third_party/angle/src/tests/perf_tests/MultiviewPerf.cpp

//
// Copyright 2017 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.
//
// MultiviewPerfTest:
//   Performance tests for multiview rendering.
//   - MultiviewCPUBoundBenchmark issues many draw calls and state changes to stress the CPU.
//   - MultiviewGPUBoundBenchmark draws half a million quads with multiple attributes per vertex in
//   order to stress the GPU's memory system.
//

#include "ANGLEPerfTest.h"
#include "common/vector_utils.h"
#include "platform/autogen/FeaturesD3D_autogen.h"
#include "test_utils/MultiviewTest.h"
#include "test_utils/gl_raii.h"
#include "util/shader_utils.h"

#include <string.h>

usingnamespaceangle;

namespace
{

std::string GetShaderExtensionHeader(bool usesMultiview,
                                     int numViews,
                                     GLenum shaderType,
                                     ExtensionName multiviewExtension)
{}

struct Vertex
{};

enum class MultiviewOption
{};

MultiviewPerfWorkload;

struct MultiviewPerfParams final : public RenderTestParams
{};

std::ostream &operator<<(std::ostream &os, const MultiviewPerfParams &params)
{}

class MultiviewBenchmark : public ANGLERenderTest,
                           public ::testing::WithParamInterface<MultiviewPerfParams>
{};

class MultiviewCPUBoundBenchmark : public MultiviewBenchmark
{};

class MultiviewGPUBoundBenchmark : public MultiviewBenchmark
{};

void MultiviewBenchmark::initializeBenchmark()
{}

void MultiviewBenchmark::drawBenchmark()
{}

void MultiviewCPUBoundBenchmark::initializeBenchmark()
{}

void MultiviewCPUBoundBenchmark::renderScene()
{}

void MultiviewGPUBoundBenchmark::initializeBenchmark()
{}

void MultiviewGPUBoundBenchmark::renderScene()
{}

namespace
{
MultiviewPerfWorkload SmallWorkload()
{}

MultiviewPerfWorkload BigWorkload()
{}

MultiviewPerfParams NoAcceleration(const EGLPlatformParameters &eglParameters,
                                   const MultiviewPerfWorkload &workload,
                                   ExtensionName multiviewExtensionIn)
{}

MultiviewPerfParams SelectViewInGeometryShader(const MultiviewPerfWorkload &workload,
                                               ExtensionName multiviewExtensionIn)
{}

MultiviewPerfParams SelectViewInVertexShader(const EGLPlatformParameters &eglParameters,
                                             const MultiviewPerfWorkload &workload,
                                             ExtensionName multiviewExtensionIn)
{}
}  // namespace

TEST_P(MultiviewCPUBoundBenchmark, Run)
{}

ANGLE_INSTANTIATE_TEST();

TEST_P(MultiviewGPUBoundBenchmark, Run)
{}

ANGLE_INSTANTIATE_TEST();

}  // anonymous namespace