JavaMono的谷歌 Native Client(NaCl)技术补助

Native
Client是谷歌(Google)在浏览器领域推出的四个开源技术,它同意在浏览器内编写翻译Web应用程序,并履行原生的编写翻译好的代码。Native
Client有以下多少个优势(参考谷歌(Google)官方英文介绍):

  • 为Web提供愈来愈多的图样,音频以及其它效用:能够直接在web上执行了原生的2D,3D图形渲染程序(对Web游戏很有用),播放音录像,响应鼠标键盘事件,八线程执行代码等等,而这整个,不须要浏览器安装任何插件。
  • 卓绝的可移植性:1个Web程序,只须求花费一份代码,即能够在有着平台(包含Windows,linux,Mac等)运营。
  • 高安全性:安装不被信任的桌面程序拔尖浏览器插件,大概带来很高的安全风险(如程序带领木马,病毒)。而Native
    client使用了双层沙盒(sandbox)设计来保险用户的当地能源。Native
    Client的架构能够确认保证web要运用的安全性,并且取得和原声代码相同或类似的脾性。
  • 便利从桌面迁移:很多耗费厂商从前花了大气力开发桌面程序,随着云总计的来到,越多的次第会被移植到互连网上,由于NaCl援救直接执行C/C++/Java等代码,Native
    Client技术能够简化移植进度,收缩移植费用。
  • 高性能:Native
    Client能够让web应用已接近桌面程序的属性运转,那就为在浏览器内运营品质苛刻的顺序提供了基础,如大型3D游戏。

参照这两篇小说:

漫谈谷歌(Google)的Native
Client技术(一)–历史引力篇(Web本地计算发展史)

漫谈Google的Native
Client(NaCl)技术(二)–技术篇(兼谈LLVM)

Mono从2.10方始支持NaCI技术(开源Mono框架将C#编制程序带到一加、Android和Wii),Unity
3.5也通过Mono支持NaCI ,Getting Started with Native Client
Development
。经过近2年的费用,前几日的Mono版本代码中签入了1个重要的NaCI更新,https://github.com/mono/mono/pull/538

  • Restore nacl directory for this fork
  • Add back temporary __nacl_suspend_thread_if_needed to this
    fork
  • Set up for building on TeamCity.
  • Zip up build results for TeamCity
  • Remove dependency to gettext
  • Simple random implementation for NaCl, so we don’t get exceptions.
  • Add x86_64 build.
  • cleanup.
  • Updated README instructions
  • Don’t use sgen for non-nacl mono build for parity
  • brushing off some nacl dust
  • Remove hardcoded path
  • NaCl working again post M14
  • Fixes for nacl
  • Updated README
  • Merge remote branch ‘upstream/master’ into merge_head
  • Fixups for nacl at head revision
  • New master script to build all for NaCl
  • Add nacl cross-compile target
  • Fix up bugs in x86-codegen for NaCl, use 4.0 for regression tests
  • Merge branch ‘merge_head’
  • Wrap pthread_exit () with mono_gc_pthread_exit () since NACL
    requires it.
  • No longer need BOEHM_DEFINES in io-layer, pthread_exit is wrapped
  • Fix NaCl GC deadlock
  • – Fix nacl aborting on windows because of failed write calls
  • Update for new nacl tool names, also preliminary glibc support.
  • First pass nacl glibc work
  • More glibc nacl work, builds shared library.
  • Fix amd64_alu_reg_imm for NaCl (previous fix was over ambitious)
  • Faster GC instrumentation for managed nacl code.
  • Compare pointers against 4 byte immediates
  • Build with -O2 in Native Client x86-64.
  • Merge pull request #1 from pasko/master
  • Fix compile and validation errors in optimized build
  • Fix conv.ovf.i.un test for 64 bit nacl
  • Also fix convert i->i and i->u with no ovf
  • enable gc instrumentation with inlined if
  • Add volatile qualifier to libgc stop the world.
  • Brad’s patch to bootstrap NaCl glibc
  • Merge pull request #2 from zheka/master
  • Added __nacl_thread_suspension_needed to dynamic exports.
  • Force memory allocation to use mmap
  • Merge pull request #3 from zheka/master
  • get rid of the alias to __nacl_thread_suspension_needed
  • Always use near_call == TRUE in emit_call_body().
  • Merge pull request #Java,4 from bradchen/master
  • Make size of immediate explicit in generating CMP instruction.
  • Run fsacheck tests with data from high-memory to
  • Add ‘laddcc’/’lsubcc’ IR opcode to deal explicitly with long
    arguments
  • Pass return valuetypes of non power of two size to their nearest
    power of two, previously defaulted to sizeof(gpointer) which is too
    small for 5, 6, and 7 byte types on ILP32 machines.
  • Fix patch targets to newly installed methods for NaCl
  • Make divide by zero checks explicit for Native Client
  • Pass TYPEDBYREF types the same as VALUETYPE for amd64 NaCl because
    that’s more appropriate for the ABI
  • Fix BB max_offset for x86 NaCl
  • Fix spaces/tabs from last commit
  • Make explicit-null-checks default for mono in NaCl (not embedded
    case), option to disable since the environment is mostly unusable
  • Add nacl-specific regression tests
  • Support ‘make check’ for self-hosted NaCl Mono in mono/mini
  • Self-host NaCl Mono build
  • Re-enable dlopen support in NaCl Mono
  • Enable ‘make check’ for NaCl on root build directory:
  • Add stderr output on nacl_dyncode_create failure, makes it easier
    to debug bad code
  • Change README contents since those instructions don’t work anymore
  • Add custom nacl_interp script for building/testing NaCl Mono
  • Make scripts work with slightly different paths from pepper_18.
  • Use /bin/bash explicitly so the script runs properly
  • Change install directory so it doesn’t modify the toolchain dir
  • Disable AOT loadhook for native client
  • Initial NaCl/ARM work.
  • Fix gmodule-unix.c (needed config.h for HAVE_DLFCN_H)
  • Merge upstream mono
  • Fix NaCl build post-merge with upstream master

相关文章