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<title>StartUsingAutoStack</title>
8  </head>
9  <body>
10<h1><CODE>nn::os::Thread::StartUsingAutoStack</CODE> Member Function</h1>
11<h2>Syntax</h2>
12    <div class="section">
13      <pre class="definition">#include &lt;nn/os.h&gt;
14template &lt;typename T, typename U&gt;
15void StartUsingAutoStack(
16     void(*)(T) f,
17     U param,
18     size_t stackSize,
19     s32 priority = DEFAULT_THREAD_PRIORITY,
20     s32 coreNo = CORE_NO_USE_PROCESS_VALUE
21);
22</pre>
23    </div>
24<h2>Template Arguments</h2>
25    <div class="section">
26      <table class="arguments">
27        <thead>
28          <tr>
29<th>Name</th>
30<td>Description</td>
31          </tr>
32        </thead>
33        <tr>
34<th>T</th>
35<td>Data type of argument(s) of the function to run (this type must be copyable)</td>
36        </tr>
37        <tr>
38<th>U</th>
39<td>A type that can be converted to <SPAN class="argument">T</SPAN></td>
40        </tr> </table>
41    </div>
42<h2>Arguments</h2>
43    <div class="section">
44      <table class="arguments">
45        <thead>
46          <tr>
47            <td width="15" />
48<th>Name</th>
49<td>Description</td>
50          </tr>
51        </thead>
52        <tr>
53<td>in</td>
54<th>f</th>
55<td>Pointer to the function to begin running</td>
56        </tr>
57        <tr>
58<td>in</td>
59<th>param</th>
60<td>Argument to pass to the function that begins execution.</td>
61        </tr>
62        <tr>
63<td>in</td>
64<th>stackSize</th>
65<td>Stack size</td>
66        </tr>
67        <tr>
68<td>in</td>
69<th>priority</th>
70<td>Priority of the thread.</td>
71        </tr>
72        <tr>
73<td>in</td>
74<th>coreNo</th>
75<td>Specifies the thread's preferred processor and affinity mask</td>
76        </tr> </table>
77    </div>
78<h2>Return Values</h2>
79    <div class="section">
80None.
81               </div>
82<h2>Description</h2>
83    <div class="section">
84<p>Initializes and runs a thread.</p><p>Automatically allocates a stack of the specified size or larger, and automatically destroys it when the thread terminates.</p></div>
85  <hr><p>CONFIDENTIAL</p></body>
86</html>
87