<?php
include_once $_SERVER['DOCUMENT_ROOT'] . '/include/shared-manual.inc';
$TOC = array();
$TOC_DEPRECATED = array();
$PARENTS = array();
include_once dirname(__FILE__) ."/toc/ref.info.inc";
$setup = array (
  'home' => 
  array (
    0 => 'index.php',
    1 => 'PHP Manual',
  ),
  'head' => 
  array (
    0 => 'UTF-8',
    1 => 'ja',
  ),
  'this' => 
  array (
    0 => 'function.memory-reset-peak-usage.php',
    1 => 'memory_reset_peak_usage',
    2 => 'メモリの最大値をリセットする',
  ),
  'up' => 
  array (
    0 => 'ref.info.php',
    1 => 'PHP オプション/情報 関数',
  ),
  'prev' => 
  array (
    0 => 'function.memory-get-usage.php',
    1 => 'memory_get_usage',
  ),
  'next' => 
  array (
    0 => 'function.php-ini-loaded-file.php',
    1 => 'php_ini_loaded_file',
  ),
  'alternatives' => 
  array (
  ),
  'source' => 
  array (
    'lang' => 'ja',
    'path' => 'reference/info/functions/memory-reset-peak-usage.xml',
  ),
  'history' => 
  array (
  ),
);
$setup["toc"] = $TOC;
$setup["toc_deprecated"] = $TOC_DEPRECATED;
$setup["parents"] = $PARENTS;
manual_setup($setup);

contributors($setup);

?>
<div id="function.memory-reset-peak-usage" class="refentry">
 <div class="refnamediv">
  <h1 class="refname">memory_reset_peak_usage</h1>
  <p class="verinfo">(PHP 8 &gt;= 8.2.0)</p><p class="refpurpose"><span class="refname">memory_reset_peak_usage</span> &mdash; <span class="dc-title">メモリの最大値をリセットする</span></p>

 </div>

 <div class="refsect1 description" id="refsect1-function.memory-reset-peak-usage-description">
  <h3 class="title">説明</h3>
  <div class="methodsynopsis dc-description">
   <span class="methodname"><strong>memory_reset_peak_usage</strong></span>(): <span class="type"><a href="language.types.void.php" class="type void">void</a></span></div>

  <p class="para rdfs-comment">
   <span class="function"><a href="function.memory-get-peak-usage.php" class="function">memory_get_peak_usage()</a></span>
   が返したメモリの最大値をリセットします。
  </p>
 </div>


 <div class="refsect1 parameters" id="refsect1-function.memory-reset-peak-usage-parameters">
  <h3 class="title">パラメータ</h3>
  <p class="para">この関数にはパラメータはありません。</p>
 </div>


 <div class="refsect1 returnvalues" id="refsect1-function.memory-reset-peak-usage-returnvalues">
  <h3 class="title">戻り値</h3>
  <p class="para">
   値を返しません。
  </p>
 </div>


 <div class="refsect1 examples" id="refsect1-function.memory-reset-peak-usage-examples">
  <h3 class="title">例</h3>
  <p class="para">
   <div class="example" id="example-1">
    <p><strong>例1 <span class="function"><strong>memory_reset_peak_usage()</strong></span> の例</strong></p>
    <div class="example-contents">
<div class="phpcode"><code><span style="color: #000000"><span style="color: #0000BB">&lt;?php<br /><br />var_dump</span><span style="color: #007700">(</span><span style="color: #0000BB">memory_get_peak_usage</span><span style="color: #007700">());<br /><br /></span><span style="color: #0000BB">$a </span><span style="color: #007700">= </span><span style="color: #0000BB">str_repeat</span><span style="color: #007700">(</span><span style="color: #DD0000">"Hello"</span><span style="color: #007700">, </span><span style="color: #0000BB">424242</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">var_dump</span><span style="color: #007700">(</span><span style="color: #0000BB">memory_get_peak_usage</span><span style="color: #007700">());<br /><br />unset(</span><span style="color: #0000BB">$a</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">memory_reset_peak_usage</span><span style="color: #007700">();<br /><br /></span><span style="color: #0000BB">$a </span><span style="color: #007700">= </span><span style="color: #0000BB">str_repeat</span><span style="color: #007700">(</span><span style="color: #DD0000">"Hello"</span><span style="color: #007700">, </span><span style="color: #0000BB">2424</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">var_dump</span><span style="color: #007700">(</span><span style="color: #0000BB">memory_get_peak_usage</span><span style="color: #007700">());<br /><br /></span><span style="color: #0000BB">?&gt;</span></span></code></div>
    </div>

    <div class="example-contents"><p>上の例の出力は、
たとえば以下のようになります。</p></div>
    <div class="example-contents screen">
<div class="examplescode"><pre class="examplescode">int(422440)
int(2508672)
int(399208)</pre>
</div>
    </div>
   </div>
  </p>
 </div>


 <div class="refsect1 seealso" id="refsect1-function.memory-reset-peak-usage-seealso">
  <h3 class="title">参考</h3>
  <p class="para">
   <ul class="simplelist">
    <li><span class="function"><a href="function.memory-get-peak-usage.php" class="function" rel="rdfs-seeAlso">memory_get_peak_usage()</a> - PHP によって割り当てられたメモリの最大値を返す</span></li>
   </ul>
  </p>
 </div>


</div><?php manual_footer($setup); ?>