File: PreLoadBegin.html

package info (click to toggle)
petsc 2.3.3-14
  • links: PTS
  • area: main
  • in suites: lenny
  • size: 79,788 kB
  • ctags: 339,579
  • sloc: ansic: 255,388; cpp: 27,384; python: 27,194; fortran: 18,468; makefile: 11,436; sh: 3,671; f90: 1,447; xml: 620; csh: 211
file content (72 lines) | stat: -rw-r--r-- 4,434 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML3.2 EN">
<HTML>
<HEAD>
<META NAME="GENERATOR" CONTENT="DOCTEXT">
<TITLE>PreLoadBegin</TITLE>
</HEAD>
<BODY BGCOLOR="FFFFFF">
<A NAME="PreLoadBegin"><H1>PreLoadBegin</H1></A>
Begin a segment of code that may be preloaded (run twice) to get accurate timings 
<H3><FONT COLOR="#CC3333">Input Parameter</FONT></H3>
<TABLE border="0" cellpadding="0" cellspacing="0">
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>flag </B></TD><TD>- <A HREF="../Sys/PETSC_TRUE.html#PETSC_TRUE">PETSC_TRUE</A> to run twice, <A HREF="../Sys/PETSC_FALSE.html#PETSC_FALSE">PETSC_FALSE</A> to run once, may be overridden
with command line option -preload true or -preload false
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>name </B></TD><TD>- name of first stage (lines of code timed separately with -log_summary) to
be preloaded
</TD></TR></TABLE>
<P>
<H3><FONT COLOR="#CC3333">Synopsis</FONT></H3>
<PRE>
void PreLoadBegin(PetscTruth flag,char *name);
</PRE>
<H3><FONT COLOR="#CC3333">Usage</FONT></H3>
<PRE>
     <A HREF="../Profiling/PreLoadBegin.html#PreLoadBegin">PreLoadBegin</A>(<A HREF="../Sys/PETSC_TRUE.html#PETSC_TRUE">PETSC_TRUE</A>,"first stage);
       lines of code
       <A HREF="../Profiling/PreLoadStage.html#PreLoadStage">PreLoadStage</A>("second stage");
       lines of code
     <A HREF="../Profiling/PreLoadEnd.html#PreLoadEnd">PreLoadEnd</A>();
</PRE>

<P>
Notes: Only works in C/C++, not Fortran
<P>
Flags available within the macro.
<TABLE border="0" cellpadding="0" cellspacing="0">
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>PetscPreLoadingUsed </B></TD><TD>- true if we are or have done preloading 
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>PetscPreLoadingOn </B></TD><TD>- true if it is CURRENTLY doing preload
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>PreLoadIt </B></TD><TD>- 0 for the first computation (with preloading turned off it is only 0) 1 for the second
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>PreLoadMax </B></TD><TD>- number of times it will do the computation, only one when preloading is turned on
The first two variables are available throughout the program, the second two only between the <A HREF="../Profiling/PreLoadBegin.html#PreLoadBegin">PreLoadBegin</A>()
and <A HREF="../Profiling/PreLoadEnd.html#PreLoadEnd">PreLoadEnd</A>()
</TD></TR></TABLE>
<P>

<P>
<H3><FONT COLOR="#CC3333">See Also</FONT></H3>
 <A HREF="../Profiling/PetscLogEventRegister.html#PetscLogEventRegister">PetscLogEventRegister</A>(), <A HREF="../Profiling/PetscLogEventBegin.html#PetscLogEventBegin">PetscLogEventBegin</A>(), <A HREF="../Profiling/PetscLogEventEnd.html#PetscLogEventEnd">PetscLogEventEnd</A>(), <A HREF="../Profiling/PreLoadEnd.html#PreLoadEnd">PreLoadEnd</A>(), <A HREF="../Profiling/PreLoadStage.html#PreLoadStage">PreLoadStage</A>()
<BR>
<P>
<P>
<P>
<P><B><P><B><FONT COLOR="#CC3333">Level:</FONT></B>intermediate
<BR><FONT COLOR="#CC3333">Location:</FONT></B><A HREF="../../../src/sys/plog/plog.c.html#PreLoadBegin">src/sys/plog/plog.c</A>
<BR><A HREF="./index.html">Index of all Profiling routines</A>
<BR><A HREF="../../index.html">Table of Contents for all manual pages</A>
<BR><A HREF="../singleindex.html">Index of all manual pages</A>
<P><H3><FONT COLOR="#CC3333">Examples</FONT></H3>
<A HREF="../../../src/mat/examples/tutorials/ex1.c.html">src/mat/examples/tutorials/ex1.c.html</A><BR>
<A HREF="../../../src/ksp/ksp/examples/tutorials/ex10.c.html">src/ksp/ksp/examples/tutorials/ex10.c.html</A><BR>
<A HREF="../../../src/ksp/ksp/examples/tutorials/ex27.c.html">src/ksp/ksp/examples/tutorials/ex27.c.html</A><BR>
<A HREF="../../../src/snes/examples/tutorials/ex18.c.html">src/snes/examples/tutorials/ex18.c.html</A><BR>
<A HREF="../../../src/snes/examples/tutorials/ex19.c.html">src/snes/examples/tutorials/ex19.c.html</A><BR>
<A HREF="../../../src/snes/examples/tutorials/ex20.c.html">src/snes/examples/tutorials/ex20.c.html</A><BR>
<A HREF="../../../src/snes/examples/tutorials/ex25.c.html">src/snes/examples/tutorials/ex25.c.html</A><BR>
<A HREF="../../../src/snes/examples/tutorials/ex27.c.html">src/snes/examples/tutorials/ex27.c.html</A><BR>
<A HREF="../../../src/snes/examples/tutorials/ex29.c.html">src/snes/examples/tutorials/ex29.c.html</A><BR>
<A HREF="../../../src/snes/examples/tutorials/ex31.c.html">src/snes/examples/tutorials/ex31.c.html</A><BR>
</BODY></HTML>