Path: blob/21.2-virgl/src/gallium/drivers/svga/svga_mksstats.h
4570 views
/**********************************************************1* Copyright 2016 VMware, Inc. All rights reserved.2*3* Permission is hereby granted, free of charge, to any person4* obtaining a copy of this software and associated documentation5* files (the "Software"), to deal in the Software without6* restriction, including without limitation the rights to use, copy,7* modify, merge, publish, distribute, sublicense, and/or sell copies8* of the Software, and to permit persons to whom the Software is9* furnished to do so, subject to the following conditions:10*11* The above copyright notice and this permission notice shall be12* included in all copies or substantial portions of the Software.13*14* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,15* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF16* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND17* NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS18* BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN19* ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN20* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE21* SOFTWARE.22*23**********************************************************/2425#ifndef _SVGA_MKSSTATS_H26#define _SVGA_MKSSTATS_H2728#include "svga_winsys.h"2930#ifdef VMX86_STATS31#define SVGA_STATS_COUNT_INC(_sws, _stat) \32_sws->stats_inc(_stat);3334#define SVGA_STATS_TIME_PUSH(_sws, _stat) \35struct svga_winsys_stats_timeframe timeFrame; \36_sws->stats_time_push(_stat, &timeFrame);3738#define SVGA_STATS_TIME_POP(_sws) \39_sws->stats_time_pop();4041#else4243#define SVGA_STATS_COUNT_INC(_sws, _stat)44#define SVGA_STATS_TIME_PUSH(_sws, _stat)45#define SVGA_STATS_TIME_POP(_sws)4647#endif48#endif /* _SVGA_MKSSTATS_H */495051