1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> 2<html> 3 4<head> 5<META http-equiv="Content-Type" content="text/html; charset=windows-1252"> 6<META name="GENERATOR" content="Microsoft FrontPage 5.0"> 7<META http-equiv="Content-Style-Type" content="text/css"> 8<LINK rel="stylesheet" type="text/css" href="../../CSS/revolution.css"> 9<title>GXClearMemMetric</title> 10</head> 11 12<body> 13 14<h1 align="left">GXClearMemMetric</h1> 15 16<h2>Syntax</h2> 17<dl><dd><pre class="construction"> 18#include <revolution/gx.h> 19 20void GXClearMemMetric( void ); 21</pre></dd></dl> 22 23<h2>Arguments</h2> 24<p>None.</p> 25 26<h2>Return Values</h2> 27<p>None.</p> 28 29<H2>Description</H2> 30<P>The graphics processor (GP) can count many internal events that give detailed information on performance. This function clears the memory request counters. These counters can be read by calling the <A href="GXReadMemMetric.html"><CODE>GXReadMemMetric</CODE></A> function. Since the counters are cleared by writing CPU-accessible registers, this function should <strong>not</strong> be used in a display list.</P> 31<DL><DD><CODE>u32 cp_req, tc_req, cpu_rd_req, cpu_wr_req, dsp_req, io_req, vi_req, pe_req;<BR> u32 rf_req, fi_req;<BR> <BR> GXReadClearMetric();<BR> <BR> // Draw Object(s)</CODE></DD></DL> 32<DL><DD><CODE>// wait until object drawn<BR> GXSetDrawSync(0xbeef);<BR> while (0xbeef != GXReadDrawSync())<BR> ;<BR> <BR> metric = GXReadMemMetric(&cp_req,<BR> &tc_req,<BR> &cpu_rd_req,<BR> &cpu_wr_req,<BR> &dsp_req,<BR> &io_req,<BR> &vi_req,<BR> &pe_req,<BR> &rf_req,<BR> &fi_req ); // returns request counter<BR> <BR> OSReport("Number command processor requests: %d\n", cp_req);</CODE></DD></DL> 33 34<h2>See Also</h2> 35<P class="reference"> 36<a href="GXReadPixMetric.html">GXReadPixMetric</a>, 37<a href="GXClearPixMetric.html">GXClearPixMetric</a>, 38<a href="GXSetVCacheMetric.html">GXSetVCacheMetric</a>, 39<a href="GXReadVCacheMetric.html">GXReadVCacheMetric</a>, 40<a href="GXClearVCacheMetric.html">GXClearVCacheMetric</a>, 41<a href="GXSetGPMetric.html">GXSetGPMetric</a>, 42<a href="GXReadGPMetric.html">GXReadGPMetric</a>, 43<a href="GXClearGPMetric.html">GXClearGPMetric</a> 44</p> 45 46<H2>Revision History</H2> 47<P> 482006/03/01 Initial version.<br> 49</P> 50 51<hr><p>CONFIDENTIAL</p></body> 52</html>