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>InitializeUsingAutoStack</title> 8 </head> 9 <body> 10 <h1><CODE><a href="../../../nn/Overview.html">nn</a>::<a href="../../../nn/os/Overview.html">os</a>::<a href="../../../nn/os/ManagedThread/Overview.html">ManagedThread</a>::InitializeUsingAutoStack</CODE> Member Function</h1> 11 <h2>Syntax</h2> 12 <div class="section"> 13 <pre class="definition">#include <nn/os.h> 14 15template <typename T> 16void InitializeUsingAutoStack( 17 void(*)(T *) f, 18 const T & param, 19 size_t stackSize, 20 <a href="../../../nn_types/s32.html">s32</a> priority = PRIORITY_DEFAULT, 21 <a href="../../../nn_types/s32.html">s32</a> coreNo = CORE_NO_DEFAULT 22); 23</pre> 24 </div> 25 <h2>Template Arguments</h2> 26 <div class="section"> 27 <table class="arguments"> 28 <thead> 29 <tr> 30 <th>Name</th> 31 <td>Description</td> 32 </tr> 33 </thead> 34 <tr> 35 <th>T</th> 36 <td>Data type of argument(s) of the function to run (this type must be copyable).</td> 37 </tr> </table> 38 </div> 39 <h2>Arguments</h2> 40 <div class="section"> 41 <table class="arguments"> 42 <thead> 43 <tr> 44 <td width="15" /> 45 <th>Name</th> 46 <td>Description</td> 47 </tr> 48 </thead> 49 <tr> 50 <td>in</td> 51 <th>f</th> 52 <td>Pointer to the function that will run on the created thread.</td> 53 </tr> 54 <tr> 55 <td>in</td> 56 <th>param</th> 57 <td>Parameter to pass for the <SPAN class="argument">f</SPAN> argument.</td> 58 </tr> 59 <tr> 60 <td>in</td> 61 <th>stackSize</th> 62 <td>Size of buffer for stack being allocated.</td> 63 </tr> 64 <tr> 65 <td>in</td> 66 <th>priority</th> 67 <td>Priority of the thread being created.</td> 68 </tr> 69 <tr> 70 <td>in</td> 71 <th>coreNo</th> 72 <td>Preferred processor for the thread being created.</td> 73 </tr> </table> 74 </div> 75 <h2>Return Values</h2> 76 <div class="section"> 77 None. 78 </div> 79 <h2>Description</h2> 80 <div class="section"> 81 <p>Automatically allocates stack and creates thread.</p><p> 82 Performs the same processing as the <CODE><a href="../../../nn/os/ManagedThread/InitializeUsingAutoStack(0).html">InitializeUsingAutoStack<T, U></a></CODE> function, with the exception that the data referenced by <SPAN class="argument">param</SPAN> is copied to the buffer passed as the stack, and the pointer to that copied region is passed as the <SPAN class="argument">f</SPAN> argument. For details, see the <CODE><a href="../../../nn/os/ManagedThread/InitializeUsingAutoStack(0).html">InitializeUsingAutoStack<T, U></a></CODE> function. 83 </p></div> 84 <h2>Revision History</h2> 85 <div class="section"> 86 <dl class="history"> 87 <dt>2012/04/13</dt> 88 <dd>Initial version.<br /> 89 </dd> 90 </dl> 91 </div> 92 <hr><p>CONFIDENTIAL</p></body> 93</html>