a6da12fa1d43da533831c6dd927a48d3b59a977e
[scilab.git] / scilab / modules / functions / help / en_US / profiling / remove_profiling.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!--
3  * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
4  * Copyright (C) ????-2008 - INRIA
5  *
6  * This file must be used under the terms of the CeCILL.
7  * This source file is licensed as described in the file COPYING, which
8  * you should have received as part of this distribution.  The terms
9  * are also available at
10  * http://www.cecill.info/licences/Licence_CeCILL_V2.1-en.txt
11 -->
12 <refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svg="http://www.w3.org/2000/svg" xmlns:ns3="http://www.w3.org/1999/xhtml" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook" xmlns:scilab="http://www.scilab.org" xml:id="remove_profiling" xml:lang="fr">
13     <refnamediv>
14         <refname>remove_profiling</refname>
15         <refpurpose>Removes profiling instructions toout of a function.</refpurpose>
16     </refnamediv>
17     <refsynopsisdiv>
18         <title>Calling Sequence</title>
19         <synopsis>remove_profiling(funname)</synopsis>
20     </refsynopsisdiv>
21     <refsection>
22         <title>Arguments</title>
23         <variablelist>
24             <varlistentry>
25                 <term>funname</term>
26                 <listitem>
27                     <para>A character string, the name of the function</para>
28                 </listitem>
29             </varlistentry>
30         </variablelist>
31     </refsection>
32     <refsection>
33         <title>Description</title>
34         <para>
35             <literal>remove_profiling(funname)</literal> Removes profiling instructions (if any) out of the function
36             named <literal>funname</literal>. 
37         </para>
38     </refsection>
39     <refsection>
40         <title>Examples</title>
41         <programlisting role="example"><![CDATA[ 
42 function x=foo(a,n)
43  x=0;
44  for i=1:n
45    if x<10 then
46      x=x+a
47    else
48      x=x+1
49    end  
50  end
51  x=x^2+1
52 endfunction
53
54 add_profiling("foo")
55 foo(0.1,100) //run the function
56 profile(foo) //extract profile information
57 remove_profiling("foo")
58  ]]></programlisting>
59     </refsection>
60     <refsection role="see also">
61         <title>See Also</title>
62         <simplelist type="inline">
63             <member>
64                 <link linkend="profile">profile</link>
65             </member>
66             <member>
67                 <link linkend="plotprofile">plotprofile</link>
68             </member>
69             <member>
70                 <link linkend="add_profiling">remove_profiling</link>
71             </member>
72             <member>
73                 <link linkend="reset_profiling">reset_profiling</link>
74             </member>
75         </simplelist>
76     </refsection>
77     <refsection>
78         <title>Used Functions</title>
79         <para>
80             This function uses the Scilab functions <literal>bytecode</literal>  and
81             <literal>walkbytecode</literal> 
82         </para>
83     </refsection>
84 </refentry>