IntroductionPortable Native Client (PNaCl) is a toolchain for compiling Native Client applications to a subset of LLVM bitcode. These bitcode files (known as "portable executables", or "pexe" files) represent an Native Client application in a high-level format, which can be translated to native code for execution on any processor supported by NaCl. The PNaCl toolchain is currently available for Windows, Mac, and Linux. PNaCl currently supports code generation on 3 architectures:
How does PNaCl work?PNaCl is a cross-compiling toolchain, where the target architecture is bitcode. PNaCl recognizes three types of bitcode files:
PNaCl provides the standard tools: pnacl-clang pnacl-clang++ pnacl-ld pnacl-ar pnacl-nm pnacl-ranlib pnacl-strip pnacl-asWhile chrome can load and translate a pexe directly, there is an additional tool pnacl-translate.for generating native code from bitcode. Installing the PNaCl Toolchain and Building Examples PNaCl is now available in the naclsdk updater (https://developers.google.com/native-client/sdk/download). It is available in pepper_24 and higher.
How to Run Examples in Chrome 29+
Debugging PNaCl pexes can be loaded and translated directly in chrome. However, for debugging, we recommend translating ahead of time with pnacl-translate to obtain a NaCl nexe. The NaCl nexe can be debugged with the NaCl gdb debugger or other techniques. We recommend debugging the nexe level, instead of the pexe because bitcode debug metadata is not part of PNaCl's stable bitcode ABI and must be left out of published pexes. To remove debug metadata, run pnacl-finalize on the pexe.How to report bugs / feedback for PNaCl
The section on developing PNaCl itself has moved to https://sites.google.com/a/chromium.org/dev/nativeclient/pnacl/developing-pnacl |
