• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 //
2 // Copyright 2019 The ANGLE Project Authors. All rights reserved.
3 // Use of this source code is governed by a BSD-style license that can be
4 // found in the LICENSE file.
5 //
6 // ANGLEPerfTestArgs.h:
7 //   Command line arguments for angle_perftests.
8 //
9 
10 #ifndef TESTS_PERF_TESTS_ANGLE_PERF_TEST_ARGS_H_
11 #define TESTS_PERF_TESTS_ANGLE_PERF_TEST_ARGS_H_
12 
13 #include <string>
14 #include <vector>
15 #include "common/Optional.h"
16 
17 namespace angle
18 {
19 extern bool gCalibration;
20 extern int gStepsPerTrial;
21 extern int gMaxStepsPerformed;
22 extern bool gEnableTrace;
23 extern const char *gTraceFile;
24 extern const char *gScreenshotDir;
25 extern bool gSaveScreenshots;
26 extern int gScreenshotFrame;
27 extern bool gRunToKeyFrame;
28 extern bool gVerboseLogging;
29 extern int gWarmupTrials;
30 extern int gWarmupSteps;
31 extern int gCalibrationTimeSeconds;
32 extern int gTrialTimeSeconds;
33 extern int gTestTrials;
34 extern bool gNoFinish;
35 extern bool gRetraceMode;
36 extern bool gMinimizeGPUWork;
37 extern bool gTraceTestValidation;
38 extern const char *gTraceInterpreter;
39 extern const char *gPerfCounters;
40 extern const char *gUseANGLE;
41 extern const char *gUseGL;
42 extern bool gOffscreen;
43 extern bool gVsync;
44 extern const char *gPrintExtensionsToFile;
45 extern const char *gRequestedExtensions;
46 
47 // Use this flag as an indicator that a trace's frame count should be used for warmup steps
48 constexpr int kAllFrames = -1;
49 
50 constexpr int kDefaultScreenshotFrame   = 1;
51 constexpr int kDefaultMaxStepsPerformed = 0;
52 
OneFrame()53 inline bool OneFrame()
54 {
55     return gStepsPerTrial == 1 || gMaxStepsPerformed == 1;
56 }
57 }  // namespace angle
58 
59 #endif  // TESTS_PERF_TESTS_ANGLE_PERF_TEST_ARGS_H_
60