1 #ifndef SkBenchTimer_DEFINED 2 #define SkBenchTimer_DEFINED 3 4 class BenchSysTimer; 5 class BenchGpuTimer; 6 7 /** 8 * SysTimers and GpuTimers are implemented orthogonally. 9 * This class combines a SysTimer and a GpuTimer into one single, 10 * platform specific, Timer with a simple interface. 11 */ 12 class BenchTimer { 13 public: 14 BenchTimer(); 15 ~BenchTimer(); 16 void start(); 17 void end(); 18 double fCpu; 19 double fWall; 20 double fGpu; 21 22 private: 23 BenchSysTimer *fSysTimer; 24 BenchGpuTimer *fGpuTimer; 25 }; 26 27 #endif 28