1<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
2<html xml:lang="en-US" lang="en-US" xmlns="http://www.w3.org/1999/xhtml">
3  <head>
4    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
5    <meta http-equiv="Content-Style-Type" content="text/css" />
6    <link rel="stylesheet" href="../css/manpage.css" type="text/css" />
7    <style type="text/css"><!--
8      span.static_style
9      {
10        font-size			: 8pt;
11        color				: white;
12        font-weight			: bold;
13        background			: #44f;
14        border-left			: solid 1px #aaf;
15        border-top			: solid 1px #aaf;
16        border-right		: solid 1px #00c;
17        border-bottom		: solid 1px #00c;
18        padding-left		: 2px;
19        padding-right		: 2px;
20      }
21      span.virtual_style
22      {
23        font-size			 : 8pt;
24        color				 : white;
25        font-weight			: bold;
26        background			: #0a0;
27        border-left			: solid 1px #0f0;
28        border-top			: solid 1px #0f0;
29        border-right		: solid 1px #060;
30        border-bottom		: solid 1px #060;
31        padding-left		: 2px;
32        padding-right		: 2px;
33      }
34      span.protected_style
35      {
36        font-size			 : 8pt;
37        color				 : white;
38        font-weight			: bold;
39        background			: #444;
40        border-left			: solid 1px #ccc;
41        border-top			: solid 1px #ccc;
42        border-right		: solid 1px #222;
43        border-bottom		: solid 1px #222;
44        padding-left		: 2px;
45        padding-right		: 2px;
46      }
47        --></style>
48<title>About the <CODE>StartUp</CODE> API</title>
49  </head>
50  <body>
51<h1>About the <CODE>StartUp</CODE> API</h1>
52<h2>Description</h2>
53    <div class="section">
54<p>This API is used to start up applications.</p><p>The application startup process is described below.</p><p><itemizedlist><listitem><para>Initialize BSS region.<br /></para></listitem><listitem><para>Call <CODE>nninitSystem</CODE>.<br /></para></listitem><listitem><para>Call <CODE>nninitStartUp</CODE>.<br /></para></listitem><listitem><para>Call static initializer.<br /></para></listitem><listitem><para>Call <CODE>nninitSetup</CODE>.<br /></para></listitem><listitem><para>Run <CODE>nnMain</CODE>.<br /><br /> The <CODE>nninitStartUp</CODE> function is compiled with weak symbols so it can be overridden with developers' own definitions. </para></listitem></itemizedlist>These functions are called before the C++ static initializer is called, so it is not possible to use instances within the static data of classes that don't have clear constructors. As a result, there are significant restrictions on the functions that can be called. Among the library's functions, only the ones shown below can be called before the static initializer.</p><p><itemizedlist><listitem><para><CODE><a href="../nn/init/InitializeAllocator.html">nn::init::InitializeAllocator</a></CODE><br /></para></listitem><listitem><para><CODE><a href="../nn/os/GetAppMemorySize.html">nn::os::GetAppMemorySize</a></CODE><br /></para></listitem><listitem><para><CODE><a href="../nn/os/GetUsingMemorySize.html">nn::os::GetUsingMemorySize</a></CODE><br /></para></listitem><listitem><para><CODE><a href="../nn/os/SetDeviceMemorySize.html">nn::os::SetDeviceMemorySize</a></CODE><br /></para></listitem><listitem><para><CODE><a href="../nn/os/SetHeapSize.html">nn::os::SetHeapSize</a></CODE><br /></para></listitem><listitem><para><CODE><a href="../nn/os/SetupHeapForMemoryBlock.html">nn::os::SetupHeapForMemoryBlock</a></CODE><br /></para></listitem></itemizedlist><br />Operation is not guaranteed when calling SDK functions other than the above. Sufficient care should be taken when coding your own operations as well.</p><!-- write here --></div>
55<h2>Revision History</h2>
56    <div class="section">
57      <dl class="history">
58        <dt>2010/01/07</dt>
59<dd>Initial version.<br />
60        </dd>
61      </dl>
62    </div>
63  <hr><p>CONFIDENTIAL</p></body>
64</html>
65