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

Side by Side Diff: native_client_sdk/doc_generated/overview.html

Issue 476793002: Per P0 reqs add launch pts + make download obvious. Also misc cpy edits. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 4 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
OLDNEW
1 {{+bindTo:partials.standard_nacl_article}} 1 {{+bindTo:partials.standard_nacl_article}}
2 2
3 <section id="technical-overview"> 3 <section id="technical-overview">
4 <span id="overview"></span><h1 id="technical-overview"><span id="overview"></spa n>Technical Overview</h1> 4 <span id="overview"></span><h1 id="technical-overview"><span id="overview"></spa n>Technical Overview</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="id2">Introduction</a> </li> 7 <li><a class="reference internal" href="#introduction" id="id2">Introduction</a> </li>
8 <li><a class="reference internal" href="#why-use-native-client" id="id3">Why use Native Client?</a></li> 8 <li><a class="reference internal" href="#why-use-native-client" id="id3">Why use Native Client?</a></li>
9 <li><a class="reference internal" href="#common-use-cases" id="id4">Common use c ases</a></li> 9 <li><a class="reference internal" href="#common-use-cases" id="id4">Common use c ases</a></li>
10 <li><p class="first"><a class="reference internal" href="#how-native-client-work s" id="id5">How Native Client works</a></p> 10 <li><p class="first"><a class="reference internal" href="#how-native-client-work s" id="id5">How Native Client works</a></p>
(...skipping 26 matching lines...) Expand all
37 <p>A web application that uses Native Client generally consists of a combination of 37 <p>A web application that uses Native Client generally consists of a combination of
38 JavaScript, HTML, CSS, and a NaCl module that is written in a language supported 38 JavaScript, HTML, CSS, and a NaCl module that is written in a language supported
39 by the SDK. The NaCl SDK currently supports C and C++; as compilers for 39 by the SDK. The NaCl SDK currently supports C and C++; as compilers for
40 additional languages are developed, the SDK will be updated to support those 40 additional languages are developed, the SDK will be updated to support those
41 languages as well.</p> 41 languages as well.</p>
42 <img alt="/native-client/images/web-app-with-nacl.png" src="/native-client/image s/web-app-with-nacl.png" /> 42 <img alt="/native-client/images/web-app-with-nacl.png" src="/native-client/image s/web-app-with-nacl.png" />
43 </section><section id="why-use-native-client"> 43 </section><section id="why-use-native-client">
44 <h2 id="why-use-native-client">Why use Native Client?</h2> 44 <h2 id="why-use-native-client">Why use Native Client?</h2>
45 <p>Native Client open-source technology is designed to run compiled code 45 <p>Native Client open-source technology is designed to run compiled code
46 securely inside a browser at near-native speeds. Native Client puts web 46 securely inside a browser at near-native speeds. Native Client puts web
47 applications on the same playing field as traditional (locally-run) 47 applications on the same playing field as desktop software&#8212;it provides the
48 software&#8212;it provides the means to fully harness the client&#8217;s computa tional 48 means to fully harness the client&#8217;s computational resources for applicatio ns
49 resources for applications such as 3D games, multimedia editors, CAD modeling, 49 such as 3D games, multimedia editors, CAD modeling,
50 client-side data analytics, and interactive simulations. 50 client-side data analytics, and interactive simulations.
51 Native Client also aims to give C and C++ (and eventually other languages) the 51 Native Client also aims to give C and C++ (and eventually other languages) the
52 same level of portability and safety that JavaScript provides on the web today.< /p> 52 same level of portability and safety that JavaScript provides on the web today.< /p>
53 <p>Here are a few of the key benefits that Native Client offers:</p> 53 <p>Important benefits of Native Client include:</p>
54 <ul class="small-gap"> 54 <ul class="small-gap">
55 <li><strong>Graphics, audio, and much more:</strong> Run native code modules tha t render 2D 55 <li><strong>Graphics, audio, and much more:</strong> Runing native code modules that render 2D
56 and 3D graphics, play audio, respond to mouse and keyboard events, run on 56 and 3D graphics, play audio, respond to mouse and keyboard events, run on
57 multiple threads, and access memory directly&#8212;all without requiring 57 multiple threads, and access memory directly&#8212;all without requiring
58 the user to install a plugin.</li> 58 the user to install a plugin.</li>
59 <li><strong>Portability:</strong> Write your applications once and you&#8217;ll be able to run them 59 <li><strong>Portability:</strong> Writing your applications once and running the m on operating
60 across operating systems (Windows, Linux, Mac, and Chrome OS) and CPU 60 systems (Windows, Linux, Mac, and Chrome OS) and CPU architectures (x86 and
61 architectures (x86 and ARM).</li> 61 ARM).</li>
62 <li><strong>Easy migration path to the web:</strong> Many developers and compani es have years 62 <li><strong>Easy migration path to the web:</strong> Leveraging years of work in existing
63 of work invested in existing desktop applications. Native Client makes the 63 desktop applications. Native Client makes the transition from the desktop to a
64 transition from the desktop to a web application significantly easier because 64 web application significantly easier because it supports C and C++.</li>
65 it supports C and C++.</li> 65 <li><strong>Security:</strong> Protecting the user&#8217;s system from malicious or buggy
66 <li><strong>Security:</strong> Native Client uses a double sandbox model designe d to protect 66 applications through Native Client&#8217;s double sandbox model. This model offe rs
67 the user&#8217;s system from malicious or buggy applications. This model offers the 67 the safety of traditional web applications without sacrificing performance and
68 safety of traditional web applications without sacrificing performance and
69 without requiring users to install a plugin.</li> 68 without requiring users to install a plugin.</li>
70 <li><strong>Performance:</strong> Native Client allows web applications to run a t speeds 69 <li><strong>Performance:</strong> Running at speeds comparable to desktop applic ations (within
71 comparable to desktop applications (within 5-15% of native speed). 70 5-15% of native speed). Native Client also allows applications to harness all
72 Native Client also allows applications to harness all available CPU cores via 71 available CPU cores via a threading API; this enables demanding applications
73 a threading API; this enables demanding applications such as console-quality 72 such as console-quality games to run inside the browser.</li>
74 games to run inside the browser.</li>
75 </ul> 73 </ul>
76 </section><section id="common-use-cases"> 74 </section><section id="common-use-cases">
77 <h2 id="common-use-cases">Common use cases</h2> 75 <h2 id="common-use-cases">Common use cases</h2>
78 <p>Typical use cases for Native Client include the following:</p> 76 <p>Typical use cases for Native Client include the following:</p>
79 <ul class="small-gap"> 77 <ul class="small-gap">
80 <li><strong>Existing software components:</strong> With support for C and C++, N ative 78 <li><strong>Existing software components:</strong> With support for C and C++, N ative
81 Client enables you to reuse existing software modules in 79 Client lets you to reuse existing software modules in web applications. You
82 web applications&#8212;you don&#8217;t need to rewrite and debug code 80 don&#8217;t need to rewrite and debug code that already works.</li>
83 that&#8217;s already proven to work well.</li>
84 <li><strong>Legacy desktop applications:</strong> Native Client provides a smoot h migration 81 <li><strong>Legacy desktop applications:</strong> Native Client provides a smoot h migration
85 path from desktop applications to the web. You can port and recompile existing 82 path from desktop applications to the web. You can port and recompile existing
86 code for the computation engine of your application directly to Native Client, 83 code for the computation engine of your application directly to Native Client,
87 and need repurpose only the user interface and event handling portions to the 84 and need rebuild only the user interface and event handling portions for the
88 new browser platform. Native Client allows you to embed existing functionality 85 browser.</li>
89 directly into the browser. At the same time, your application can take
90 advantage of things the browser does well: handling user interaction and
91 processing events, based on the latest developments in HTML5.</li>
92 <li><strong>Heavy computation in enterprise applications:</strong> Native Client can handle the 86 <li><strong>Heavy computation in enterprise applications:</strong> Native Client can handle the
93 number crunching required by large-scale enterprise applications. To ensure 87 number crunching required by large-scale enterprise applications. To ensure
94 protection of user data, Native Client enables you to build complex 88 protection of user data, Native Client enables you to build complex
95 cryptographic algorithms directly into the browser so that unencrypted data 89 cryptographic algorithms directly into the browser so that unencrypted data
96 never goes out over the network.</li> 90 never goes out over the network.</li>
97 <li><strong>Multimedia applications:</strong> Codecs for processing sounds, imag es, and movies 91 <li><strong>Multimedia applications:</strong> Codecs for processing sounds, imag es, and movies
98 can be added to the browser in a Native Client module.</li> 92 can be added to the browser in a Native Client module.</li>
99 <li><strong>Games:</strong> Native Client lets web applications run at close to native 93 <li><strong>Games:</strong> Native Client lets web applications run at close to native
100 speed, reuse existing multithreaded/multicore C/C++ code bases, and 94 speed, reuse existing multithreaded/multicore C/C++ code bases, and
101 access low-latency audio, networking APIs, and OpenGL ES with programmable 95 access low-latency audio, networking APIs, and OpenGL ES with programmable
102 shaders. Native Client is a natural fit for running a physics engine or 96 shaders. Native Client is a natural fit for running a physics engine or
103 artificial intelligence module that powers a sophisticated web game. 97 artificial intelligence module that powers a sophisticated web game.
104 Native Client also enables applications to run unchanged across 98 Native Client also enables applications to run unchanged across
105 many platforms.</li> 99 many platforms.</li>
106 <li><strong>Any application that requires acceleration</strong>: Native Client f its seamlessly 100 <li><strong>Any application that requires acceleration</strong>: Native Client f its seamlessly
107 into web applications&#8212;it&#8217;s up to you to decide to what extent to use it. 101 into web applications&#8212;it&#8217;s up to you to decide to what extent to use it.
108 Use of Native Client covers the full spectrum from complete applications to 102 Use of Native Client covers the full spectrum from complete applications to
109 small optimized routines that accelerate vital parts of web apps.</li> 103 small optimized routines that accelerate vital parts of web applications.</li>
110 </ul> 104 </ul>
111 </section><section id="how-native-client-works"> 105 </section><section id="how-native-client-works">
112 <span id="link-how-nacl-works"></span><h2 id="how-native-client-works"><span id= "link-how-nacl-works"></span>How Native Client works</h2> 106 <span id="link-how-nacl-works"></span><h2 id="how-native-client-works"><span id= "link-how-nacl-works"></span>How Native Client works</h2>
113 <p>Native Client is an umbrella name for a set of interrelated software componen ts 107 <p>Native Client is an umbrella name for a set of related software components th at
114 that work together to provide a way to develop C/C++ applications and run them 108 together to provide a way to develop C/C++ applications and run them securely
115 securely on the web.</p> 109 on the web.</p>
116 <p>At a high level, Native Client consists of:</p> 110 <p>At a high level, Native Client consists of:</p>
117 <ul class="small-gap"> 111 <ul class="small-gap">
118 <li><strong>Toolchains</strong>: collections of development tools (compilers, li nkers, etc.) 112 <li><strong>Toolchains</strong>: Collections of development tools (compilers, li nkers, etc.)
119 that transform C/C++ code to Native Client modules.</li> 113 that transform C/C++ code to Native Client modules.</li>
120 <li><strong>Runtime components</strong>: components embedded in the browser or o ther 114 <li><strong>Runtime components</strong>: components embedded in the browser or o ther
121 host platforms that allow execution of Native Client modules 115 host platforms that allow execution of Native Client modules
122 securely and efficiently.</li> 116 securely and efficiently.</li>
123 </ul> 117 </ul>
124 <p>The following diagram shows how these components interact:</p> 118 <p>The following diagram shows how these components interact:</p>
125 <img alt="/native-client/images/nacl-pnacl-component-diagram.png" src="/native-c lient/images/nacl-pnacl-component-diagram.png" /> 119 <img alt="/native-client/images/nacl-pnacl-component-diagram.png" src="/native-c lient/images/nacl-pnacl-component-diagram.png" />
126 <p>The left side of the diagram shows how to use Portable Native Client 120 <p>The left side of the diagram shows how to use Portable Native Client
127 (PNaCl, pronounced &#8220;pinnacle&#8221;). Developers use the PNaCl toolchain 121 (PNaCl, pronounced &#8220;pinnacle&#8221;). Developers use the PNaCl toolchain
128 to produce a single, portable (<strong>pexe</strong>) module. At runtime, a tran slator 122 to produce a single, portable (<strong>pexe</strong>) module. At runtime, a tran slator
129 built into the browser translates the pexe into native code for the 123 built into the browser translates the pexe into native code for the
130 relevant client architecture.</p> 124 relevant client architecture. Translation occurs before any code is executed.</p >
131 <p>The right side of the diagram shows how to use traditional (non-portable) 125 <p>The right side of the diagram shows how to use (non-portable) Native Client.
132 Native Client. Developers use a nacl-gcc based toolchain to produce multiple 126 Developers use a nacl-gcc based toolchain to produce multiple
133 architecture-dependent (<strong>nexe</strong>) modules, which are packaged into an 127 architecture-dependent (<strong>nexe</strong>) modules, which are packaged into an
134 application. At runtime, the browser decides which nexe to load based 128 application. At runtime, the browser decides which nexe to load based
135 on the architecture of the client machine.</p> 129 on the architecture of the client machine.</p>
136 <section id="security"> 130 <section id="security">
137 <h3 id="security">Security</h3> 131 <h3 id="security">Security</h3>
138 <p>Since Native Client permits the execution of native code on client machines, 132 <p>Since Native Client permits the execution of native code on client machines,
139 special security measures have to be implemented:</p> 133 special security measures have to be implemented:</p>
140 <ul class="small-gap"> 134 <ul class="small-gap">
141 <li>The NaCl sandbox ensures that code accesses system resources only through 135 <li>The NaCl sandbox ensures that code accesses system resources only through
142 safe, whitelisted APIs, and operates within its limits without attempting to 136 safe, whitelisted APIs, and operates within its limits without attempting to
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
231 Pepper APIs to help developers make adjustments to API changes and take 225 Pepper APIs to help developers make adjustments to API changes and take
232 advantage of new features: <a class="reference external" href="/native-client/pe pper_stable">stable</a>, <a class="reference external" href="/native-client/pepp er_beta">beta</a> and <a class="reference external" href="/native-client/pepper_ dev">dev</a>.</p> 226 advantage of new features: <a class="reference external" href="/native-client/pe pper_stable">stable</a>, <a class="reference external" href="/native-client/pepp er_beta">beta</a> and <a class="reference external" href="/native-client/pepper_ dev">dev</a>.</p>
233 </section><section id="where-to-start"> 227 </section><section id="where-to-start">
234 <h2 id="where-to-start">Where to start</h2> 228 <h2 id="where-to-start">Where to start</h2>
235 <p>The <a class="reference internal" href="/native-client/quick-start.html"><em> Quick Start</em></a> document provides links to downloads and 229 <p>The <a class="reference internal" href="/native-client/quick-start.html"><em> Quick Start</em></a> document provides links to downloads and
236 documentation that should help you get started with developing and distributing 230 documentation that should help you get started with developing and distributing
237 Native Client applications.</p> 231 Native Client applications.</p>
238 </section></section> 232 </section></section>
239 233
240 {{/partials.standard_nacl_article}} 234 {{/partials.standard_nacl_article}}
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698