Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(761)

Side by Side Diff: native_client_sdk/doc_generated/reference/pnacl-bitcode-abi.html

Issue 358033002: PNaCl documentation: update the bitcode reference manual for vector load/store (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | native_client_sdk/src/doc/reference/pnacl-bitcode-abi.rst » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 {{+bindTo:partials.standard_nacl_article}} 1 {{+bindTo:partials.standard_nacl_article}}
2 2
3 <section id="pnacl-bitcode-reference-manual"> 3 <section id="pnacl-bitcode-reference-manual">
4 <h1 id="pnacl-bitcode-reference-manual">PNaCl Bitcode Reference Manual</h1> 4 <h1 id="pnacl-bitcode-reference-manual">PNaCl Bitcode Reference Manual</h1>
5 <div class="contents local" id="contents" style="display: none"> 5 <div class="contents local" id="contents" style="display: none">
6 <ul class="small-gap"> 6 <ul class="small-gap">
7 <li><a class="reference internal" href="#introduction" id="id1">Introduction</a> </li> 7 <li><a class="reference internal" href="#introduction" id="id1">Introduction</a> </li>
8 <li><p class="first"><a class="reference internal" href="#high-level-structure" id="id2">High Level Structure</a></p> 8 <li><p class="first"><a class="reference internal" href="#high-level-structure" id="id2">High Level Structure</a></p>
9 <ul class="small-gap"> 9 <ul class="small-gap">
10 <li><a class="reference internal" href="#data-model" id="id3">Data Model</a></li > 10 <li><a class="reference internal" href="#data-model" id="id3">Data Model</a></li >
(...skipping 183 matching lines...) Expand 10 before | Expand all | Expand 10 after
194 128-bits).</li> 194 128-bits).</li>
195 </ul> 195 </ul>
196 </section><section id="array-and-struct-types"> 196 </section><section id="array-and-struct-types">
197 <h3 id="array-and-struct-types">Array and struct types</h3> 197 <h3 id="array-and-struct-types">Array and struct types</h3>
198 <p>Array and struct types are only allowed in 198 <p>Array and struct types are only allowed in
199 <a class="reference internal" href="#bitcode-globalvariables"><em>global variabl e initializers</em></a>.</p> 199 <a class="reference internal" href="#bitcode-globalvariables"><em>global variabl e initializers</em></a>.</p>
200 </section><section id="pointer-types"> 200 </section><section id="pointer-types">
201 <span id="bitcode-pointertypes"></span><h3 id="pointer-types"><span id="bitcode- pointertypes"></span>Pointer types</h3> 201 <span id="bitcode-pointertypes"></span><h3 id="pointer-types"><span id="bitcode- pointertypes"></span>Pointer types</h3>
202 <p>Only the following pointer types are allowed:</p> 202 <p>Only the following pointer types are allowed:</p>
203 <ul class="small-gap"> 203 <ul class="small-gap">
204 <li>Pointers to valid PNaCl bitcode scalar types, as specified above.</li> 204 <li>Pointers to valid PNaCl bitcode scalar types, as specified above, except for
205 <code>i1</code>.</li>
206 <li>Pointers to valid PNaCl bitcode vector types, as specified above, except for
207 <code>&lt;? x i1&gt;</code>.</li>
205 <li>Pointers to functions.</li> 208 <li>Pointers to functions.</li>
206 </ul> 209 </ul>
207 <p>In addition, the address space for all pointers must be 0.</p> 210 <p>In addition, the address space for all pointers must be 0.</p>
208 <p>A pointer is <em>inherent</em> when it represents the return value of an <cod e>alloca</code> 211 <p>A pointer is <em>inherent</em> when it represents the return value of an <cod e>alloca</code>
209 instruction, or is an address of a global value.</p> 212 instruction, or is an address of a global value.</p>
210 <p>A pointer is <em>normalized</em> if it&#8217;s either:</p> 213 <p>A pointer is <em>normalized</em> if it&#8217;s either:</p>
211 <ul class="small-gap"> 214 <ul class="small-gap">
212 <li><em>inherent</em></li> 215 <li><em>inherent</em></li>
213 <li>Is the return value of a <code>bitcast</code> instruction.</li> 216 <li>Is the return value of a <code>bitcast</code> instruction.</li>
214 <li>Is the return value of a <code>inttoptr</code> instruction.</li> 217 <li>Is the return value of a <code>inttoptr</code> instruction.</li>
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
280 Unlike the libc fmod function, this does not set <code>errno</code> when the 283 Unlike the libc fmod function, this does not set <code>errno</code> when the
281 result is NaN (see the <a class="reference internal" href="#ir-and-errno"><em>in structions and errno</em></a> 284 result is NaN (see the <a class="reference internal" href="#ir-and-errno"><em>in structions and errno</em></a>
282 section).</p> 285 section).</p>
283 </li> 286 </li>
284 <li><p class="first"><code>alloca</code></p> 287 <li><p class="first"><code>alloca</code></p>
285 <p>See <a class="reference internal" href="#bitcode-allocainst"><em>alloca instr uctions</em></a>.</p> 288 <p>See <a class="reference internal" href="#bitcode-allocainst"><em>alloca instr uctions</em></a>.</p>
286 </li> 289 </li>
287 <li><p class="first"><code>load</code>, <code>store</code></p> 290 <li><p class="first"><code>load</code>, <code>store</code></p>
288 <p>The pointer argument of these instructions must be a <em>normalized</em> poin ter (see 291 <p>The pointer argument of these instructions must be a <em>normalized</em> poin ter (see
289 <a class="reference internal" href="#bitcode-pointertypes"><em>pointer types</em ></a>). The <code>volatile</code> and <code>atomic</code> 292 <a class="reference internal" href="#bitcode-pointertypes"><em>pointer types</em ></a>). The <code>volatile</code> and <code>atomic</code>
290 attributes are not supported. Loads and stores of the type <code>i1</code> are n ot 293 attributes are not supported. Loads and stores of the type <code>i1</code> and < code>&lt;? x
291 supported.</p> 294 i1&gt;</code> are not supported.</p>
292 <p>These instructions must use <code>align 1</code> on integer memory accesses, <code>align 4</code> 295 <p>These instructions must follow the following alignment restrictions:</p>
293 for <code>float</code> accesses and <code>align 8</code> for <code>double</code> accesses.</p> 296 <ul class="small-gap">
297 <li>On integer memory accesses: <code>align 1</code>.</li>
298 <li>On <code>float</code> memory accesses: <code>align 1</code> or <code>align 4 </code>.</li>
299 <li>On <code>double</code> memory accesses: <code>align 1</code> or <code>align 8</code>.</li>
300 <li>On vector memory accesses: alignment at the vector&#8217;s element width, fo r
301 example <code>&lt;4 x i32&gt;</code> must be <code>align 4</code>.</li>
302 </ul>
294 </li> 303 </li>
295 <li><code>trunc</code></li> 304 <li><code>trunc</code></li>
296 <li><code>zext</code></li> 305 <li><code>zext</code></li>
297 <li><code>sext</code></li> 306 <li><code>sext</code></li>
298 <li><code>fptrunc</code></li> 307 <li><code>fptrunc</code></li>
299 <li><code>fpext</code></li> 308 <li><code>fpext</code></li>
300 <li><code>fptoui</code></li> 309 <li><code>fptoui</code></li>
301 <li><code>fptosi</code></li> 310 <li><code>fptosi</code></li>
302 <li><code>uitofp</code></li> 311 <li><code>uitofp</code></li>
303 <li><code>sitofp</code></li> 312 <li><code>sitofp</code></li>
(...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after
460 <p>The <code>llvm.nacl.atomic.is.lock.free</code> intrinsic is designed to 469 <p>The <code>llvm.nacl.atomic.is.lock.free</code> intrinsic is designed to
461 determine at translation time whether atomic operations of a certain 470 determine at translation time whether atomic operations of a certain
462 <code>byte_size</code> (a compile-time constant), at a particular <code>address< /code>, 471 <code>byte_size</code> (a compile-time constant), at a particular <code>address< /code>,
463 are lock-free or not. This reflects the C11 <code>atomic_is_lock_free</code> 472 are lock-free or not. This reflects the C11 <code>atomic_is_lock_free</code>
464 function from header <code>&lt;stdatomic.h&gt;</code> and the C++11 <code>is_loc k_free</code> 473 function from header <code>&lt;stdatomic.h&gt;</code> and the C++11 <code>is_loc k_free</code>
465 member function in header <code>&lt;atomic&gt;</code>. It can be used through th e 474 member function in header <code>&lt;atomic&gt;</code>. It can be used through th e
466 <code>__nacl_atomic_is_lock_free</code> builtin.</p> 475 <code>__nacl_atomic_is_lock_free</code> builtin.</p>
467 </section></section></section> 476 </section></section></section>
468 477
469 {{/partials.standard_nacl_article}} 478 {{/partials.standard_nacl_article}}
OLDNEW
« no previous file with comments | « no previous file | native_client_sdk/src/doc/reference/pnacl-bitcode-abi.rst » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698