webruby 0.2.7 → 0.9.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/webruby/environment.rb +24 -8
- data/lib/webruby/rake/files.rake +6 -22
- data/lib/webruby/rake/general.rake +1 -1
- data/lib/webruby/rake/mruby.rake +1 -0
- data/lib/webruby/utility.rb +14 -0
- data/modules/mruby/AUTHORS +14 -0
- data/modules/mruby/CONTRIBUTING.md +7 -4
- data/modules/mruby/INSTALL +28 -11
- data/modules/mruby/MITL +13 -13
- data/modules/mruby/Makefile +4 -5
- data/modules/mruby/README.md +54 -49
- data/modules/mruby/Rakefile +36 -6
- data/modules/mruby/benchmark/ao-render.rb +1 -2
- data/modules/mruby/benchmark/bm_app_lc_fizzbuzz.rb +52 -0
- data/modules/mruby/benchmark/fib39.rb +0 -0
- data/modules/mruby/bintest/mrbc.rb +12 -0
- data/modules/mruby/build_config.rb +32 -2
- data/modules/mruby/doc/api/README.md +30 -0
- data/modules/mruby/doc/api/mruby.h.md +69 -0
- data/modules/mruby/doc/compile/README.md +208 -99
- data/modules/mruby/doc/debugger/README.md +370 -0
- data/modules/mruby/doc/language/Core.md +1590 -0
- data/modules/mruby/doc/language/README.md +9 -0
- data/modules/mruby/doc/language/generator.rb +15 -0
- data/modules/mruby/doc/language/mrbdoc/lib/mrbdoc_analyze.rb +231 -0
- data/modules/mruby/doc/language/mrbdoc/lib/mrbdoc_docu.rb +118 -0
- data/modules/mruby/doc/language/mrbdoc/mrbdoc.rb +38 -0
- data/modules/mruby/doc/mrbconf/README.md +160 -0
- data/modules/mruby/doc/mrbgems/README.md +136 -66
- data/modules/mruby/examples/mrbgems/c_and_ruby_extension_example/mrbgem.rake +1 -1
- data/modules/mruby/examples/mrbgems/c_and_ruby_extension_example/src/example.c +1 -1
- data/modules/mruby/examples/mrbgems/c_extension_example/mrbgem.rake +1 -1
- data/modules/mruby/examples/mrbgems/c_extension_example/src/example.c +1 -1
- data/modules/mruby/examples/mrbgems/ruby_extension_example/mrbgem.rake +1 -1
- data/modules/mruby/examples/targets/{ArduinoDue.rb → build_config_ArduinoDue.rb} +32 -6
- data/modules/mruby/examples/targets/build_config_IntelGalileo.rb +106 -0
- data/modules/mruby/examples/targets/{chipKitMax32.rb → build_config_chipKITMax32.rb} +26 -7
- data/modules/mruby/include/mrbconf.h +25 -1
- data/modules/mruby/include/mruby/array.h +32 -22
- data/modules/mruby/include/mruby/boxing_nan.h +94 -0
- data/modules/mruby/include/mruby/boxing_no.h +49 -0
- data/modules/mruby/include/mruby/boxing_word.h +119 -0
- data/modules/mruby/include/mruby/class.h +15 -13
- data/modules/mruby/include/mruby/compile.h +43 -36
- data/modules/mruby/include/mruby/data.h +13 -5
- data/modules/mruby/include/mruby/debug.h +9 -9
- data/modules/mruby/include/mruby/dump.h +32 -23
- data/modules/mruby/include/mruby/error.h +36 -0
- data/modules/mruby/include/mruby/gc.h +11 -6
- data/modules/mruby/include/mruby/hash.h +12 -12
- data/modules/mruby/include/mruby/irep.h +9 -3
- data/modules/mruby/include/mruby/khash.h +58 -41
- data/modules/mruby/include/mruby/numeric.h +38 -4
- data/modules/mruby/include/mruby/object.h +55 -0
- data/modules/mruby/include/mruby/opcode.h +160 -0
- data/modules/mruby/include/mruby/proc.h +19 -5
- data/modules/mruby/include/mruby/range.h +4 -3
- data/modules/mruby/include/mruby/re.h +20 -0
- data/modules/mruby/include/mruby/string.h +86 -47
- data/modules/mruby/include/mruby/value.h +100 -374
- data/modules/mruby/include/mruby/variable.h +34 -32
- data/modules/mruby/include/mruby/version.h +40 -0
- data/modules/mruby/include/mruby.h +211 -139
- data/modules/mruby/minirake +16 -9
- data/modules/mruby/mrbgems/default.gembox +12 -0
- data/modules/mruby/mrbgems/full-core.gembox +3 -3
- data/modules/mruby/mrbgems/mruby-array-ext/mrbgem.rake +1 -0
- data/modules/mruby/mrbgems/mruby-array-ext/mrblib/array.rb +488 -8
- data/modules/mruby/mrbgems/mruby-array-ext/src/array.c +57 -31
- data/modules/mruby/mrbgems/mruby-array-ext/test/array.rb +231 -45
- data/modules/mruby/mrbgems/mruby-bin-debugger/bintest/mrdb.rb +286 -0
- data/modules/mruby/mrbgems/mruby-bin-debugger/bintest/print.rb +701 -0
- data/modules/mruby/mrbgems/mruby-bin-debugger/mrbgem.rake +9 -0
- data/modules/mruby/mrbgems/mruby-bin-debugger/tools/mrdb/apibreak.c +516 -0
- data/modules/mruby/mrbgems/mruby-bin-debugger/tools/mrdb/apibreak.h +26 -0
- data/modules/mruby/mrbgems/mruby-bin-debugger/tools/mrdb/apilist.c +235 -0
- data/modules/mruby/mrbgems/mruby-bin-debugger/tools/mrdb/apilist.h +14 -0
- data/modules/mruby/mrbgems/mruby-bin-debugger/tools/mrdb/apiprint.c +78 -0
- data/modules/mruby/mrbgems/mruby-bin-debugger/tools/mrdb/apiprint.h +13 -0
- data/modules/mruby/mrbgems/mruby-bin-debugger/tools/mrdb/cmdbreak.c +428 -0
- data/modules/mruby/mrbgems/mruby-bin-debugger/tools/mrdb/cmdmisc.c +501 -0
- data/modules/mruby/mrbgems/mruby-bin-debugger/tools/mrdb/cmdprint.c +58 -0
- data/modules/mruby/mrbgems/mruby-bin-debugger/tools/mrdb/cmdrun.c +54 -0
- data/modules/mruby/mrbgems/mruby-bin-debugger/tools/mrdb/mrdb.c +746 -0
- data/modules/mruby/mrbgems/mruby-bin-debugger/tools/mrdb/mrdb.h +163 -0
- data/modules/mruby/mrbgems/mruby-bin-debugger/tools/mrdb/mrdbconf.h +16 -0
- data/modules/mruby/mrbgems/mruby-bin-debugger/tools/mrdb/mrdberror.h +20 -0
- data/modules/mruby/mrbgems/mruby-bin-mirb/bintest/mirb.rb +12 -0
- data/modules/mruby/mrbgems/mruby-bin-mirb/mrbgem.rake +14 -1
- data/modules/mruby/mrbgems/mruby-bin-mirb/tools/mirb/mirb.c +154 -72
- data/modules/mruby/mrbgems/mruby-bin-mruby/bintest/mruby.rb +46 -0
- data/modules/mruby/mrbgems/mruby-bin-mruby/mrbgem.rake +1 -0
- data/modules/mruby/mrbgems/mruby-bin-mruby/tools/mruby/mruby.c +37 -28
- data/modules/mruby/mrbgems/mruby-bin-mruby-config/mrbgem.rake +30 -0
- data/modules/mruby/mrbgems/mruby-bin-mruby-config/mruby-config +16 -0
- data/modules/mruby/mrbgems/mruby-bin-mruby-config/mruby-config.bat +30 -0
- data/modules/mruby/mrbgems/mruby-bin-strip/bintest/mruby-strip.rb +73 -0
- data/modules/mruby/mrbgems/mruby-bin-strip/mrbgem.rake +6 -0
- data/modules/mruby/mrbgems/mruby-bin-strip/tools/mruby-strip/mruby-strip.c +155 -0
- data/modules/mruby/mrbgems/mruby-enum-ext/mrbgem.rake +1 -0
- data/modules/mruby/mrbgems/mruby-enum-ext/mrblib/enum.rb +555 -21
- data/modules/mruby/mrbgems/mruby-enum-ext/test/enum.rb +119 -0
- data/modules/mruby/mrbgems/mruby-enum-lazy/mrbgem.rake +7 -0
- data/modules/mruby/mrbgems/mruby-enum-lazy/mrblib/lazy.rb +150 -0
- data/modules/mruby/mrbgems/mruby-enum-lazy/test/lazy.rb +47 -0
- data/modules/mruby/mrbgems/mruby-enumerator/mrbgem.rake +7 -0
- data/modules/mruby/mrbgems/mruby-enumerator/mrblib/enumerator.rb +636 -0
- data/modules/mruby/mrbgems/mruby-enumerator/test/enumerator.rb +537 -0
- data/modules/mruby/mrbgems/mruby-eval/mrbgem.rake +1 -0
- data/modules/mruby/mrbgems/mruby-eval/src/eval.c +243 -4
- data/modules/mruby/mrbgems/mruby-eval/test/eval.rb +80 -0
- data/modules/mruby/mrbgems/mruby-exit/mrbgem.rake +1 -0
- data/modules/mruby/mrbgems/mruby-exit/src/mruby-exit.c +1 -1
- data/modules/mruby/mrbgems/mruby-fiber/mrbgem.rake +1 -0
- data/modules/mruby/mrbgems/mruby-fiber/src/fiber.c +157 -51
- data/modules/mruby/mrbgems/mruby-fiber/test/fiber.rb +179 -35
- data/modules/mruby/mrbgems/mruby-hash-ext/mrbgem.rake +3 -0
- data/modules/mruby/mrbgems/mruby-hash-ext/mrblib/hash.rb +241 -1
- data/modules/mruby/mrbgems/mruby-hash-ext/src/hash-ext.c +11 -19
- data/modules/mruby/mrbgems/mruby-hash-ext/test/hash.rb +138 -1
- data/modules/mruby/mrbgems/mruby-kernel-ext/mrbgem.rake +5 -0
- data/modules/mruby/mrbgems/mruby-kernel-ext/src/kernel.c +183 -0
- data/modules/mruby/mrbgems/mruby-kernel-ext/test/kernel.rb +53 -0
- data/modules/mruby/mrbgems/mruby-math/mrbgem.rake +1 -0
- data/modules/mruby/mrbgems/mruby-math/src/math.c +107 -14
- data/modules/mruby/mrbgems/mruby-math/test/math.rb +16 -0
- data/modules/mruby/mrbgems/mruby-numeric-ext/mrbgem.rake +1 -0
- data/modules/mruby/mrbgems/mruby-numeric-ext/mrblib/numeric_ext.rb +5 -0
- data/modules/mruby/mrbgems/mruby-numeric-ext/test/numeric.rb +9 -1
- data/modules/mruby/mrbgems/mruby-object-ext/mrbgem.rake +1 -0
- data/modules/mruby/mrbgems/mruby-object-ext/mrblib/object.rb +19 -0
- data/modules/mruby/mrbgems/mruby-object-ext/src/object.c +5 -8
- data/modules/mruby/mrbgems/mruby-object-ext/test/object.rb +16 -0
- data/modules/mruby/mrbgems/mruby-objectspace/mrbgem.rake +1 -0
- data/modules/mruby/mrbgems/mruby-objectspace/src/mruby_objectspace.c +121 -53
- data/modules/mruby/mrbgems/mruby-objectspace/test/objectspace.rb +27 -4
- data/modules/mruby/mrbgems/mruby-print/mrbgem.rake +1 -0
- data/modules/mruby/mrbgems/mruby-print/src/print.c +3 -5
- data/modules/mruby/mrbgems/mruby-proc-ext/mrbgem.rake +1 -0
- data/modules/mruby/mrbgems/mruby-proc-ext/src/proc.c +89 -19
- data/modules/mruby/mrbgems/mruby-proc-ext/test/proc.c +56 -0
- data/modules/mruby/mrbgems/mruby-proc-ext/test/proc.rb +47 -0
- data/modules/mruby/mrbgems/mruby-random/mrbgem.rake +1 -0
- data/modules/mruby/mrbgems/mruby-random/src/mt19937ar.c +30 -25
- data/modules/mruby/mrbgems/mruby-random/src/mt19937ar.h +6 -3
- data/modules/mruby/mrbgems/mruby-random/src/random.c +157 -137
- data/modules/mruby/mrbgems/mruby-random/src/random.h +3 -3
- data/modules/mruby/mrbgems/mruby-random/test/random.rb +9 -9
- data/modules/mruby/mrbgems/mruby-range-ext/mrbgem.rake +1 -0
- data/modules/mruby/mrbgems/mruby-range-ext/src/range.c +57 -3
- data/modules/mruby/mrbgems/mruby-range-ext/test/range.rb +9 -0
- data/modules/mruby/mrbgems/mruby-sprintf/mrbgem.rake +1 -0
- data/modules/mruby/mrbgems/mruby-sprintf/mrblib/string.rb +9 -0
- data/modules/mruby/mrbgems/mruby-sprintf/src/sprintf.c +29 -23
- data/modules/mruby/mrbgems/mruby-sprintf/test/sprintf.rb +7 -2
- data/modules/mruby/mrbgems/mruby-string-ext/mrbgem.rake +1 -0
- data/modules/mruby/mrbgems/mruby-string-ext/mrblib/string.rb +250 -11
- data/modules/mruby/mrbgems/mruby-string-ext/src/string.c +220 -5
- data/modules/mruby/mrbgems/mruby-string-ext/test/string.rb +326 -4
- data/modules/mruby/mrbgems/mruby-string-utf8/mrbgem.rake +2 -0
- data/modules/mruby/mrbgems/mruby-string-utf8/src/string.c +486 -52
- data/modules/mruby/mrbgems/mruby-string-utf8/test/string.rb +97 -14
- data/modules/mruby/mrbgems/mruby-struct/mrbgem.rake +1 -0
- data/modules/mruby/mrbgems/mruby-struct/mrblib/struct.rb +31 -0
- data/modules/mruby/mrbgems/mruby-struct/src/struct.c +178 -196
- data/modules/mruby/mrbgems/mruby-struct/test/struct.rb +115 -61
- data/modules/mruby/mrbgems/mruby-symbol-ext/mrbgem.rake +1 -0
- data/modules/mruby/mrbgems/mruby-symbol-ext/mrblib/symbol.rb +22 -17
- data/modules/mruby/mrbgems/mruby-symbol-ext/src/symbol.c +20 -11
- data/modules/mruby/mrbgems/mruby-symbol-ext/test/symbol.rb +14 -0
- data/modules/mruby/mrbgems/mruby-time/mrbgem.rake +1 -0
- data/modules/mruby/mrbgems/mruby-time/mrblib/time.rb +9 -0
- data/modules/mruby/mrbgems/mruby-time/src/time.c +98 -37
- data/modules/mruby/mrbgems/mruby-time/test/time.rb +152 -148
- data/modules/mruby/mrbgems/mruby-toplevel-ext/mrbgem.rake +1 -0
- data/modules/mruby/mrbgems/mruby-toplevel-ext/test/toplevel.rb +1 -1
- data/modules/mruby/mrblib/array.rb +110 -4
- data/modules/mruby/mrblib/class.rb +1 -22
- data/modules/mruby/mrblib/compar.rb +10 -30
- data/modules/mruby/mrblib/enum.rb +64 -52
- data/modules/mruby/mrblib/error.rb +9 -4
- data/modules/mruby/mrblib/hash.rb +164 -23
- data/modules/mruby/mrblib/kernel.rb +26 -22
- data/modules/mruby/mrblib/mrblib.rake +4 -4
- data/modules/mruby/mrblib/numeric.rb +22 -9
- data/modules/mruby/mrblib/range.rb +24 -2
- data/modules/mruby/mrblib/string.rb +15 -3
- data/modules/mruby/src/array.c +279 -339
- data/modules/mruby/src/backtrace.c +68 -16
- data/modules/mruby/src/class.c +539 -379
- data/modules/mruby/src/codegen.c +424 -207
- data/modules/mruby/src/compar.c +1 -1
- data/modules/mruby/src/crc.c +7 -6
- data/modules/mruby/src/debug.c +37 -36
- data/modules/mruby/src/dump.c +463 -213
- data/modules/mruby/src/enum.c +1 -1
- data/modules/mruby/src/error.c +91 -92
- data/modules/mruby/src/error.h +3 -19
- data/modules/mruby/src/etc.c +85 -82
- data/modules/mruby/src/gc.c +134 -108
- data/modules/mruby/src/hash.c +161 -565
- data/modules/mruby/src/init.c +2 -13
- data/modules/mruby/src/kernel.c +217 -251
- data/modules/mruby/src/load.c +280 -283
- data/modules/mruby/src/mrb_throw.h +41 -0
- data/modules/mruby/src/mruby_core.rake +57 -7
- data/modules/mruby/src/node.h +104 -104
- data/modules/mruby/src/numeric.c +221 -208
- data/modules/mruby/src/object.c +41 -42
- data/modules/mruby/src/opcode.h +2 -160
- data/modules/mruby/src/parse.y +3430 -3223
- data/modules/mruby/src/pool.c +13 -9
- data/modules/mruby/src/print.c +20 -17
- data/modules/mruby/src/proc.c +77 -21
- data/modules/mruby/src/range.c +55 -45
- data/modules/mruby/src/state.c +95 -31
- data/modules/mruby/src/string.c +462 -468
- data/modules/mruby/src/symbol.c +95 -85
- data/modules/mruby/src/variable.c +104 -74
- data/modules/mruby/src/version.c +13 -0
- data/modules/mruby/src/vm.c +528 -296
- data/modules/mruby/tasks/libmruby.rake +9 -5
- data/modules/mruby/tasks/mrbgem_spec.rake +130 -26
- data/modules/mruby/tasks/mrbgems.rake +21 -11
- data/modules/mruby/tasks/mrbgems_test.rake +46 -40
- data/modules/mruby/tasks/mruby_build.rake +54 -12
- data/modules/mruby/tasks/mruby_build_commands.rake +34 -5
- data/modules/mruby/tasks/mruby_build_gem.rake +25 -3
- data/modules/mruby/tasks/ruby_ext.rake +11 -2
- data/modules/mruby/tasks/toolchains/clang.rake +2 -1
- data/modules/mruby/tasks/toolchains/gcc.rake +26 -3
- data/modules/mruby/tasks/toolchains/visualcpp.rake +17 -8
- data/modules/mruby/test/assert.rb +30 -8
- data/modules/mruby/test/bintest.rb +10 -0
- data/modules/mruby/test/driver.c +74 -24
- data/modules/mruby/test/init_mrbtest.c +21 -2
- data/modules/mruby/test/mrbtest.rake +27 -5
- data/modules/mruby/test/t/argumenterror.rb +0 -5
- data/modules/mruby/test/t/array.rb +23 -7
- data/modules/mruby/test/t/bs_block.rb +32 -0
- data/modules/mruby/test/t/class.rb +29 -5
- data/modules/mruby/test/t/comparable.rb +20 -12
- data/modules/mruby/test/t/enumerable.rb +33 -7
- data/modules/mruby/test/t/exception.rb +63 -38
- data/modules/mruby/test/t/false.rb +2 -4
- data/modules/mruby/test/t/float.rb +39 -4
- data/modules/mruby/test/t/hash.rb +40 -6
- data/modules/mruby/test/t/indexerror.rb +0 -4
- data/modules/mruby/test/t/integer.rb +41 -5
- data/modules/mruby/test/t/kernel.rb +90 -3
- data/modules/mruby/test/t/localjumperror.rb +4 -4
- data/modules/mruby/test/t/methods.rb +1 -1
- data/modules/mruby/test/t/module.rb +43 -13
- data/modules/mruby/test/t/nameerror.rb +0 -4
- data/modules/mruby/test/t/nil.rb +5 -0
- data/modules/mruby/test/t/nomethoderror.rb +11 -2
- data/modules/mruby/test/t/numeric.rb +18 -4
- data/modules/mruby/test/t/proc.rb +59 -6
- data/modules/mruby/test/t/range.rb +15 -5
- data/modules/mruby/test/t/rangeerror.rb +0 -4
- data/modules/mruby/test/t/standarderror.rb +0 -4
- data/modules/mruby/test/t/string.rb +56 -12
- data/modules/mruby/test/t/superclass.rb +46 -0
- data/modules/mruby/test/t/symbol.rb +0 -4
- data/modules/mruby/test/t/syntax.rb +134 -1
- data/modules/mruby/test/t/true.rb +2 -4
- data/modules/mruby/test/t/typeerror.rb +0 -5
- data/modules/mruby/test/t/unicode.rb +35 -0
- data/modules/mruby/tools/mrbc/mrbc.c +9 -12
- data/modules/mruby/travis_config.rb +22 -2
- metadata +98 -1299
- data/modules/emscripten/AUTHORS +0 -117
- data/modules/emscripten/CONTRIBUTING.markdown +0 -5
- data/modules/emscripten/ChangeLog +0 -468
- data/modules/emscripten/LICENSE +0 -94
- data/modules/emscripten/README.markdown +0 -14
- data/modules/emscripten/cmake/Modules/FindOpenAL.cmake +0 -26
- data/modules/emscripten/cmake/Platform/Emscripten.cmake +0 -228
- data/modules/emscripten/em++ +0 -12
- data/modules/emscripten/em++.bat +0 -2
- data/modules/emscripten/em-config +0 -24
- data/modules/emscripten/em-config.bat +0 -2
- data/modules/emscripten/emar +0 -24
- data/modules/emscripten/emar.bat +0 -2
- data/modules/emscripten/emcc +0 -2069
- data/modules/emscripten/emcc.bat +0 -2
- data/modules/emscripten/emcc.py +0 -5
- data/modules/emscripten/emconfigure +0 -27
- data/modules/emscripten/emconfigure.bat +0 -2
- data/modules/emscripten/emlink.py +0 -33
- data/modules/emscripten/emmake +0 -29
- data/modules/emscripten/emmake.bat +0 -2
- data/modules/emscripten/emranlib +0 -9
- data/modules/emscripten/emranlib.bat +0 -2
- data/modules/emscripten/emrun +0 -1087
- data/modules/emscripten/emrun.bat +0 -2
- data/modules/emscripten/emscons +0 -20
- data/modules/emscripten/emscripten.py +0 -1347
- data/modules/emscripten/package.json +0 -7
- data/modules/emscripten/patches/README +0 -4
- data/modules/emscripten/patches/series +0 -2
- data/modules/emscripten/scons-tools/closure.py +0 -28
- data/modules/emscripten/scons-tools/emscripten.py +0 -364
- data/modules/emscripten/scons-tools/llvm.py +0 -34
- data/modules/emscripten/src/analyzer.js +0 -1781
- data/modules/emscripten/src/closure-externs.js +0 -110
- data/modules/emscripten/src/compiler.html +0 -48
- data/modules/emscripten/src/compiler.js +0 -331
- data/modules/emscripten/src/compiler_phase.html +0 -33
- data/modules/emscripten/src/corruptionCheck.js +0 -98
- data/modules/emscripten/src/determinstic.js +0 -20
- data/modules/emscripten/src/embind/embind.js +0 -1677
- data/modules/emscripten/src/embind/emval.js +0 -284
- data/modules/emscripten/src/emrun_postjs.js +0 -20
- data/modules/emscripten/src/emrun_prejs.js +0 -5
- data/modules/emscripten/src/emscripten-source-map.min.js +0 -31
- data/modules/emscripten/src/experimental/allow_loopvars_from_memsetcpy_inasm.diff +0 -97
- data/modules/emscripten/src/experimental/batching.diff +0 -44
- data/modules/emscripten/src/experimental/functypeopt.diff +0 -113
- data/modules/emscripten/src/experimental/multiple_heaps.diff +0 -175
- data/modules/emscripten/src/experimental/noncallgraphprofiling.diff +0 -197
- data/modules/emscripten/src/experimental/optimize_memcpy_for_ta1.diff +0 -124
- data/modules/emscripten/src/experimental/remove__label__s.diff +0 -140
- data/modules/emscripten/src/experimental/renderer_cache_hash.diff +0 -99
- data/modules/emscripten/src/experimental/sdl_key_forwarding.diff +0 -57
- data/modules/emscripten/src/experimental/simplifyGeneratedFunctionsDetection.diff +0 -336
- data/modules/emscripten/src/experimental/stringCache.diff +0 -147
- data/modules/emscripten/src/fastLong.js +0 -299
- data/modules/emscripten/src/gl-matrix.js +0 -1952
- data/modules/emscripten/src/headless.js +0 -295
- data/modules/emscripten/src/headlessCanvas.js +0 -618
- data/modules/emscripten/src/hello_world.js +0 -92
- data/modules/emscripten/src/intertyper.js +0 -1228
- data/modules/emscripten/src/jsifier.js +0 -1969
- data/modules/emscripten/src/library.js +0 -9196
- data/modules/emscripten/src/library_browser.js +0 -988
- data/modules/emscripten/src/library_egl.js +0 -564
- data/modules/emscripten/src/library_fs.js +0 -1619
- data/modules/emscripten/src/library_gc.js +0 -236
- data/modules/emscripten/src/library_gl.js +0 -5194
- data/modules/emscripten/src/library_glfw.js +0 -585
- data/modules/emscripten/src/library_glut.js +0 -504
- data/modules/emscripten/src/library_idbfs.js +0 -216
- data/modules/emscripten/src/library_jansson.js +0 -320
- data/modules/emscripten/src/library_memfs.js +0 -303
- data/modules/emscripten/src/library_nodefs.js +0 -286
- data/modules/emscripten/src/library_openal.js +0 -915
- data/modules/emscripten/src/library_path.js +0 -133
- data/modules/emscripten/src/library_sdl.js +0 -2728
- data/modules/emscripten/src/library_sockfs.js +0 -578
- data/modules/emscripten/src/library_strtok_r.c +0 -97
- data/modules/emscripten/src/library_tty.js +0 -146
- data/modules/emscripten/src/library_uuid.js +0 -140
- data/modules/emscripten/src/library_xlib.js +0 -23
- data/modules/emscripten/src/long.js +0 -1609
- data/modules/emscripten/src/modules.js +0 -543
- data/modules/emscripten/src/parseTools.js +0 -2723
- data/modules/emscripten/src/postamble.js +0 -239
- data/modules/emscripten/src/postamble_sharedlib.js +0 -16
- data/modules/emscripten/src/preamble.js +0 -1233
- data/modules/emscripten/src/preamble_sharedlib.js +0 -25
- data/modules/emscripten/src/proxyClient.js +0 -82
- data/modules/emscripten/src/proxyWorker.js +0 -143
- data/modules/emscripten/src/relooper/README.markdown +0 -14
- data/modules/emscripten/src/relooper/Relooper.cpp +0 -1301
- data/modules/emscripten/src/relooper/Relooper.h +0 -257
- data/modules/emscripten/src/relooper/doit.sh +0 -70
- data/modules/emscripten/src/relooper/emscripten/glue.js +0 -67
- data/modules/emscripten/src/relooper/emscripten/test.js +0 -44
- data/modules/emscripten/src/relooper/fuzzer.py +0 -131
- data/modules/emscripten/src/relooper/ministring.h +0 -35
- data/modules/emscripten/src/relooper/paper.pdf +0 -0
- data/modules/emscripten/src/relooper/test.cpp +0 -290
- data/modules/emscripten/src/relooper/test.txt +0 -317
- data/modules/emscripten/src/relooper/test2.c +0 -44
- data/modules/emscripten/src/relooper/test2.txt +0 -26
- data/modules/emscripten/src/relooper/test3.c +0 -42
- data/modules/emscripten/src/relooper/test3.txt +0 -56
- data/modules/emscripten/src/relooper/test4.cpp +0 -40
- data/modules/emscripten/src/relooper/test4.txt +0 -44
- data/modules/emscripten/src/relooper/test5.cpp +0 -40
- data/modules/emscripten/src/relooper/test5.txt +0 -56
- data/modules/emscripten/src/relooper/test6.cpp +0 -31
- data/modules/emscripten/src/relooper/test6.txt +0 -26
- data/modules/emscripten/src/relooper/test_dead.cpp +0 -28
- data/modules/emscripten/src/relooper/test_dead.txt +0 -9
- data/modules/emscripten/src/relooper/test_debug.cpp +0 -30
- data/modules/emscripten/src/relooper/test_debug.txt +0 -142
- data/modules/emscripten/src/relooper/test_fuzz1.cpp +0 -52
- data/modules/emscripten/src/relooper/test_fuzz1.txt +0 -72
- data/modules/emscripten/src/relooper/test_fuzz2.cpp +0 -34
- data/modules/emscripten/src/relooper/test_fuzz2.txt +0 -30
- data/modules/emscripten/src/relooper/test_fuzz3.cpp +0 -36
- data/modules/emscripten/src/relooper/test_fuzz3.txt +0 -25
- data/modules/emscripten/src/relooper/test_fuzz4.cpp +0 -38
- data/modules/emscripten/src/relooper/test_fuzz4.txt +0 -41
- data/modules/emscripten/src/relooper/test_fuzz5.cpp +0 -57
- data/modules/emscripten/src/relooper/test_fuzz5.txt +0 -86
- data/modules/emscripten/src/relooper/test_fuzz6.cpp +0 -322
- data/modules/emscripten/src/relooper/test_fuzz6.txt +0 -291
- data/modules/emscripten/src/relooper/test_inf.cpp +0 -813
- data/modules/emscripten/src/relooper/test_inf.txt +0 -1131
- data/modules/emscripten/src/relooper/testit.sh +0 -62
- data/modules/emscripten/src/relooper/updateit.sh +0 -17
- data/modules/emscripten/src/runtime.js +0 -604
- data/modules/emscripten/src/settings.js +0 -476
- data/modules/emscripten/src/shell.html +0 -95
- data/modules/emscripten/src/shell.js +0 -173
- data/modules/emscripten/src/shell_sharedlib.js +0 -29
- data/modules/emscripten/src/simd.js +0 -1128
- data/modules/emscripten/src/socket.io.js +0 -3870
- data/modules/emscripten/src/struct_info.json +0 -1077
- data/modules/emscripten/src/utility.js +0 -411
- data/modules/emscripten/src/wrtcp.js +0 -821
- data/modules/emscripten/system/bin/sdl-config +0 -13
- data/modules/emscripten/system/include/AL/al.h +0 -172
- data/modules/emscripten/system/include/AL/alc.h +0 -84
- data/modules/emscripten/system/include/EGL/egl.h +0 -329
- data/modules/emscripten/system/include/EGL/eglext.h +0 -398
- data/modules/emscripten/system/include/EGL/eglplatform.h +0 -141
- data/modules/emscripten/system/include/GL/freeglut_std.h +0 -628
- data/modules/emscripten/system/include/GL/gl.h +0 -2241
- data/modules/emscripten/system/include/GL/glew.h +0 -6
- data/modules/emscripten/system/include/GL/glext.h +0 -11127
- data/modules/emscripten/system/include/GL/glfw.h +0 -518
- data/modules/emscripten/system/include/GL/glu.h +0 -353
- data/modules/emscripten/system/include/GL/glut.h +0 -21
- data/modules/emscripten/system/include/GLES/gl.h +0 -770
- data/modules/emscripten/system/include/GLES/glext.h +0 -1278
- data/modules/emscripten/system/include/GLES/glplatform.h +0 -30
- data/modules/emscripten/system/include/GLES2/gl2.h +0 -621
- data/modules/emscripten/system/include/GLES2/gl2ext.h +0 -803
- data/modules/emscripten/system/include/GLES2/gl2platform.h +0 -30
- data/modules/emscripten/system/include/KHR/khrplatform.h +0 -277
- data/modules/emscripten/system/include/SDL/COPYING +0 -19
- data/modules/emscripten/system/include/SDL/SDL.h +0 -162
- data/modules/emscripten/system/include/SDL/SDL_assert.h +0 -241
- data/modules/emscripten/system/include/SDL/SDL_atomic.h +0 -318
- data/modules/emscripten/system/include/SDL/SDL_audio.h +0 -509
- data/modules/emscripten/system/include/SDL/SDL_blendmode.h +0 -60
- data/modules/emscripten/system/include/SDL/SDL_clipboard.h +0 -75
- data/modules/emscripten/system/include/SDL/SDL_compat.h +0 -365
- data/modules/emscripten/system/include/SDL/SDL_config.h +0 -48
- data/modules/emscripten/system/include/SDL/SDL_config.h.in +0 -297
- data/modules/emscripten/system/include/SDL/SDL_config_android.h +0 -133
- data/modules/emscripten/system/include/SDL/SDL_config_iphoneos.h +0 -148
- data/modules/emscripten/system/include/SDL/SDL_config_macosx.h +0 -172
- data/modules/emscripten/system/include/SDL/SDL_config_minimal.h +0 -74
- data/modules/emscripten/system/include/SDL/SDL_config_nintendods.h +0 -129
- data/modules/emscripten/system/include/SDL/SDL_config_pandora.h +0 -125
- data/modules/emscripten/system/include/SDL/SDL_config_windows.h +0 -207
- data/modules/emscripten/system/include/SDL/SDL_config_wiz.h +0 -119
- data/modules/emscripten/system/include/SDL/SDL_copying.h +0 -20
- data/modules/emscripten/system/include/SDL/SDL_cpuinfo.h +0 -150
- data/modules/emscripten/system/include/SDL/SDL_endian.h +0 -248
- data/modules/emscripten/system/include/SDL/SDL_error.h +0 -77
- data/modules/emscripten/system/include/SDL/SDL_events.h +0 -640
- data/modules/emscripten/system/include/SDL/SDL_gesture.h +0 -91
- data/modules/emscripten/system/include/SDL/SDL_gfxPrimitives.h +0 -246
- data/modules/emscripten/system/include/SDL/SDL_haptic.h +0 -1200
- data/modules/emscripten/system/include/SDL/SDL_hints.h +0 -206
- data/modules/emscripten/system/include/SDL/SDL_image.h +0 -138
- data/modules/emscripten/system/include/SDL/SDL_input.h +0 -87
- data/modules/emscripten/system/include/SDL/SDL_joystick.h +0 -208
- data/modules/emscripten/system/include/SDL/SDL_keyboard.h +0 -169
- data/modules/emscripten/system/include/SDL/SDL_keycode.h +0 -344
- data/modules/emscripten/system/include/SDL/SDL_loadso.h +0 -85
- data/modules/emscripten/system/include/SDL/SDL_log.h +0 -211
- data/modules/emscripten/system/include/SDL/SDL_main.h +0 -98
- data/modules/emscripten/system/include/SDL/SDL_mixer.h +0 -634
- data/modules/emscripten/system/include/SDL/SDL_mouse.h +0 -213
- data/modules/emscripten/system/include/SDL/SDL_mutex.h +0 -248
- data/modules/emscripten/system/include/SDL/SDL_name.h +0 -11
- data/modules/emscripten/system/include/SDL/SDL_opengl.h +0 -11116
- data/modules/emscripten/system/include/SDL/SDL_opengles.h +0 -38
- data/modules/emscripten/system/include/SDL/SDL_opengles2.h +0 -38
- data/modules/emscripten/system/include/SDL/SDL_pixels.h +0 -423
- data/modules/emscripten/system/include/SDL/SDL_platform.h +0 -160
- data/modules/emscripten/system/include/SDL/SDL_power.h +0 -79
- data/modules/emscripten/system/include/SDL/SDL_quit.h +0 -58
- data/modules/emscripten/system/include/SDL/SDL_rect.h +0 -136
- data/modules/emscripten/system/include/SDL/SDL_render.h +0 -615
- data/modules/emscripten/system/include/SDL/SDL_revision.h +0 -2
- data/modules/emscripten/system/include/SDL/SDL_revision.h.orig +0 -2
- data/modules/emscripten/system/include/SDL/SDL_rotozoom.h +0 -123
- data/modules/emscripten/system/include/SDL/SDL_rwops.h +0 -220
- data/modules/emscripten/system/include/SDL/SDL_scancode.h +0 -398
- data/modules/emscripten/system/include/SDL/SDL_shape.h +0 -147
- data/modules/emscripten/system/include/SDL/SDL_stdinc.h +0 -764
- data/modules/emscripten/system/include/SDL/SDL_surface.h +0 -499
- data/modules/emscripten/system/include/SDL/SDL_syswm.h +0 -241
- data/modules/emscripten/system/include/SDL/SDL_thread.h +0 -182
- data/modules/emscripten/system/include/SDL/SDL_timer.h +0 -108
- data/modules/emscripten/system/include/SDL/SDL_touch.h +0 -124
- data/modules/emscripten/system/include/SDL/SDL_ttf.h +0 -249
- data/modules/emscripten/system/include/SDL/SDL_types.h +0 -29
- data/modules/emscripten/system/include/SDL/SDL_version.h +0 -166
- data/modules/emscripten/system/include/SDL/SDL_video.h +0 -820
- data/modules/emscripten/system/include/SDL/begin_code.h +0 -135
- data/modules/emscripten/system/include/SDL/close_code.h +0 -37
- data/modules/emscripten/system/include/X11/X.h +0 -717
- data/modules/emscripten/system/include/X11/Xatom.h +0 -79
- data/modules/emscripten/system/include/X11/Xfuncproto.h +0 -127
- data/modules/emscripten/system/include/X11/Xlib.h +0 -4023
- data/modules/emscripten/system/include/X11/Xosdefs.h +0 -116
- data/modules/emscripten/system/include/X11/Xutil.h +0 -826
- data/modules/emscripten/system/include/X11/keysym.h +0 -73
- data/modules/emscripten/system/include/X11/keysymdef.h +0 -2389
- data/modules/emscripten/system/include/compat/ctype.h +0 -34
- data/modules/emscripten/system/include/compat/malloc.h +0 -48
- data/modules/emscripten/system/include/compat/math.h +0 -14
- data/modules/emscripten/system/include/compat/netdb.h +0 -22
- data/modules/emscripten/system/include/compat/stdarg.h +0 -16
- data/modules/emscripten/system/include/compat/stdlib.h +0 -16
- data/modules/emscripten/system/include/compat/string.h +0 -17
- data/modules/emscripten/system/include/compat/sys/socketvar.h +0 -14
- data/modules/emscripten/system/include/compat/sys/stat.h +0 -20
- data/modules/emscripten/system/include/compat/sys/timeb.h +0 -35
- data/modules/emscripten/system/include/compat/time.h +0 -18
- data/modules/emscripten/system/include/compat/unistd.h +0 -16
- data/modules/emscripten/system/include/compat/wchar.h +0 -23
- data/modules/emscripten/system/include/compat/wctype.h +0 -23
- data/modules/emscripten/system/include/compat/xlocale.h +0 -19
- data/modules/emscripten/system/include/emscripten/bind.h +0 -1210
- data/modules/emscripten/system/include/emscripten/emmintrin.h +0 -87
- data/modules/emscripten/system/include/emscripten/emscripten.h +0 -519
- data/modules/emscripten/system/include/emscripten/val.h +0 -311
- data/modules/emscripten/system/include/emscripten/vector.h +0 -34
- data/modules/emscripten/system/include/emscripten/wire.h +0 -393
- data/modules/emscripten/system/include/emscripten/xmmintrin.h +0 -131
- data/modules/emscripten/system/include/execinfo.h +0 -44
- data/modules/emscripten/system/include/gc.h +0 -70
- data/modules/emscripten/system/include/gfx/png.h +0 -3798
- data/modules/emscripten/system/include/gfx/pngconf.h +0 -1665
- data/modules/emscripten/system/include/gfx/tiff.h +0 -654
- data/modules/emscripten/system/include/gfx/tiffconf.h +0 -104
- data/modules/emscripten/system/include/gfx/tiffio.h +0 -526
- data/modules/emscripten/system/include/gfx/tiffvers.h +0 -9
- data/modules/emscripten/system/include/jansson.h +0 -323
- data/modules/emscripten/system/include/jansson_config.h +0 -54
- data/modules/emscripten/system/include/libc/aio.h +0 -69
- data/modules/emscripten/system/include/libc/alloca.h +0 -21
- data/modules/emscripten/system/include/libc/ar.h +0 -25
- data/modules/emscripten/system/include/libc/arpa/ftp.h +0 -35
- data/modules/emscripten/system/include/libc/arpa/inet.h +0 -36
- data/modules/emscripten/system/include/libc/arpa/nameser.h +0 -467
- data/modules/emscripten/system/include/libc/arpa/nameser_compat.h +0 -2
- data/modules/emscripten/system/include/libc/arpa/telnet.h +0 -251
- data/modules/emscripten/system/include/libc/arpa/tftp.h +0 -31
- data/modules/emscripten/system/include/libc/assert.h +0 -19
- data/modules/emscripten/system/include/libc/bits/alltypes.h +0 -397
- data/modules/emscripten/system/include/libc/bits/endian.h +0 -1
- data/modules/emscripten/system/include/libc/bits/errno.h +0 -134
- data/modules/emscripten/system/include/libc/bits/fcntl.h +0 -38
- data/modules/emscripten/system/include/libc/bits/fenv.h +0 -34
- data/modules/emscripten/system/include/libc/bits/float.h +0 -17
- data/modules/emscripten/system/include/libc/bits/io.h +0 -0
- data/modules/emscripten/system/include/libc/bits/ioctl.h +0 -197
- data/modules/emscripten/system/include/libc/bits/ipc.h +0 -14
- data/modules/emscripten/system/include/libc/bits/limits.h +0 -8
- data/modules/emscripten/system/include/libc/bits/mman.h +0 -62
- data/modules/emscripten/system/include/libc/bits/msg.h +0 -16
- data/modules/emscripten/system/include/libc/bits/posix.h +0 -2
- data/modules/emscripten/system/include/libc/bits/reg.h +0 -19
- data/modules/emscripten/system/include/libc/bits/setjmp.h +0 -1
- data/modules/emscripten/system/include/libc/bits/shm.h +0 -18
- data/modules/emscripten/system/include/libc/bits/signal.h +0 -112
- data/modules/emscripten/system/include/libc/bits/socket.h +0 -17
- data/modules/emscripten/system/include/libc/bits/stat.h +0 -22
- data/modules/emscripten/system/include/libc/bits/statfs.h +0 -7
- data/modules/emscripten/system/include/libc/bits/stdarg.h +0 -4
- data/modules/emscripten/system/include/libc/bits/stdint.h +0 -20
- data/modules/emscripten/system/include/libc/bits/syscall.h +0 -696
- data/modules/emscripten/system/include/libc/bits/termios.h +0 -160
- data/modules/emscripten/system/include/libc/bits/user.h +0 -48
- data/modules/emscripten/system/include/libc/byteswap.h +0 -26
- data/modules/emscripten/system/include/libc/complex.h +0 -125
- data/modules/emscripten/system/include/libc/cpio.h +0 -29
- data/modules/emscripten/system/include/libc/crypt.h +0 -20
- data/modules/emscripten/system/include/libc/ctype.h +0 -67
- data/modules/emscripten/system/include/libc/dirent.h +0 -79
- data/modules/emscripten/system/include/libc/dlfcn.h +0 -42
- data/modules/emscripten/system/include/libc/elf.h +0 -2555
- data/modules/emscripten/system/include/libc/endian.h +0 -82
- data/modules/emscripten/system/include/libc/err.h +0 -25
- data/modules/emscripten/system/include/libc/errno.h +0 -27
- data/modules/emscripten/system/include/libc/fcntl.h +0 -175
- data/modules/emscripten/system/include/libc/features.h +0 -32
- data/modules/emscripten/system/include/libc/fenv.h +0 -28
- data/modules/emscripten/system/include/libc/float.h +0 -34
- data/modules/emscripten/system/include/libc/fnmatch.h +0 -29
- data/modules/emscripten/system/include/libc/ftw.h +0 -42
- data/modules/emscripten/system/include/libc/getopt.h +0 -31
- data/modules/emscripten/system/include/libc/glob.h +0 -48
- data/modules/emscripten/system/include/libc/grp.h +0 -52
- data/modules/emscripten/system/include/libc/iconv.h +0 -24
- data/modules/emscripten/system/include/libc/ifaddrs.h +0 -35
- data/modules/emscripten/system/include/libc/inttypes.h +0 -227
- data/modules/emscripten/system/include/libc/iso646.h +0 -20
- data/modules/emscripten/system/include/libc/langinfo.h +0 -88
- data/modules/emscripten/system/include/libc/lastlog.h +0 -1
- data/modules/emscripten/system/include/libc/libgen.h +0 -15
- data/modules/emscripten/system/include/libc/libintl.h +0 -25
- data/modules/emscripten/system/include/libc/limits.h +0 -146
- data/modules/emscripten/system/include/libc/link.h +0 -54
- data/modules/emscripten/system/include/libc/locale.h +0 -82
- data/modules/emscripten/system/include/libc/malloc.h +0 -0
- data/modules/emscripten/system/include/libc/math.h +0 -422
- data/modules/emscripten/system/include/libc/memory.h +0 -1
- data/modules/emscripten/system/include/libc/mntent.h +0 -44
- data/modules/emscripten/system/include/libc/monetary.h +0 -23
- data/modules/emscripten/system/include/libc/mqueue.h +0 -36
- data/modules/emscripten/system/include/libc/net/ethernet.h +0 -55
- data/modules/emscripten/system/include/libc/net/if.h +0 -135
- data/modules/emscripten/system/include/libc/net/if_arp.h +0 -133
- data/modules/emscripten/system/include/libc/net/route.h +0 -124
- data/modules/emscripten/system/include/libc/netdb.h +0 -161
- data/modules/emscripten/system/include/libc/netinet/ether.h +0 -14
- data/modules/emscripten/system/include/libc/netinet/icmp6.h +0 -305
- data/modules/emscripten/system/include/libc/netinet/if_ether.h +0 -126
- data/modules/emscripten/system/include/libc/netinet/in.h +0 -336
- data/modules/emscripten/system/include/libc/netinet/in_systm.h +0 -9
- data/modules/emscripten/system/include/libc/netinet/ip.h +0 -186
- data/modules/emscripten/system/include/libc/netinet/ip6.h +0 -142
- data/modules/emscripten/system/include/libc/netinet/ip_icmp.h +0 -192
- data/modules/emscripten/system/include/libc/netinet/tcp.h +0 -71
- data/modules/emscripten/system/include/libc/netinet/udp.h +0 -35
- data/modules/emscripten/system/include/libc/netpacket/packet.h +0 -44
- data/modules/emscripten/system/include/libc/nl_types.h +0 -22
- data/modules/emscripten/system/include/libc/paths.h +0 -32
- data/modules/emscripten/system/include/libc/poll.h +0 -46
- data/modules/emscripten/system/include/libc/pthread.h +0 -222
- data/modules/emscripten/system/include/libc/pty.h +0 -18
- data/modules/emscripten/system/include/libc/pwd.h +0 -49
- data/modules/emscripten/system/include/libc/readme.txt +0 -3
- data/modules/emscripten/system/include/libc/regex.h +0 -62
- data/modules/emscripten/system/include/libc/resolv.h +0 -144
- data/modules/emscripten/system/include/libc/sched.h +0 -132
- data/modules/emscripten/system/include/libc/search.h +0 -51
- data/modules/emscripten/system/include/libc/semaphore.h +0 -35
- data/modules/emscripten/system/include/libc/setjmp.h +0 -42
- data/modules/emscripten/system/include/libc/shadow.h +0 -44
- data/modules/emscripten/system/include/libc/signal.h +0 -255
- data/modules/emscripten/system/include/libc/spawn.h +0 -74
- data/modules/emscripten/system/include/libc/stdalign.h +0 -15
- data/modules/emscripten/system/include/libc/stdarg.h +0 -25
- data/modules/emscripten/system/include/libc/stdbool.h +0 -14
- data/modules/emscripten/system/include/libc/stddef.h +0 -18
- data/modules/emscripten/system/include/libc/stdint.h +0 -117
- data/modules/emscripten/system/include/libc/stdio.h +0 -199
- data/modules/emscripten/system/include/libc/stdio_ext.h +0 -34
- data/modules/emscripten/system/include/libc/stdlib.h +0 -171
- data/modules/emscripten/system/include/libc/stdnoreturn.h +0 -5
- data/modules/emscripten/system/include/libc/string.h +0 -102
- data/modules/emscripten/system/include/libc/strings.h +0 -35
- data/modules/emscripten/system/include/libc/stropts.h +0 -139
- data/modules/emscripten/system/include/libc/sys/acct.h +0 -75
- data/modules/emscripten/system/include/libc/sys/cachectl.h +0 -22
- data/modules/emscripten/system/include/libc/sys/dir.h +0 -2
- data/modules/emscripten/system/include/libc/sys/epoll.h +0 -67
- data/modules/emscripten/system/include/libc/sys/errno.h +0 -2
- data/modules/emscripten/system/include/libc/sys/eventfd.h +0 -26
- data/modules/emscripten/system/include/libc/sys/fcntl.h +0 -2
- data/modules/emscripten/system/include/libc/sys/file.h +0 -21
- data/modules/emscripten/system/include/libc/sys/fsuid.h +0 -20
- data/modules/emscripten/system/include/libc/sys/inotify.h +0 -57
- data/modules/emscripten/system/include/libc/sys/io.h +0 -17
- data/modules/emscripten/system/include/libc/sys/ioctl.h +0 -14
- data/modules/emscripten/system/include/libc/sys/ipc.h +0 -42
- data/modules/emscripten/system/include/libc/sys/klog.h +0 -14
- data/modules/emscripten/system/include/libc/sys/mman.h +0 -55
- data/modules/emscripten/system/include/libc/sys/mount.h +0 -72
- data/modules/emscripten/system/include/libc/sys/msg.h +0 -52
- data/modules/emscripten/system/include/libc/sys/mtio.h +0 -188
- data/modules/emscripten/system/include/libc/sys/param.h +0 -35
- data/modules/emscripten/system/include/libc/sys/personality.h +0 -46
- data/modules/emscripten/system/include/libc/sys/poll.h +0 -2
- data/modules/emscripten/system/include/libc/sys/prctl.h +0 -101
- data/modules/emscripten/system/include/libc/sys/procfs.h +0 -65
- data/modules/emscripten/system/include/libc/sys/ptrace.h +0 -96
- data/modules/emscripten/system/include/libc/sys/reboot.h +0 -20
- data/modules/emscripten/system/include/libc/sys/reg.h +0 -9
- data/modules/emscripten/system/include/libc/sys/resource.h +0 -103
- data/modules/emscripten/system/include/libc/sys/select.h +0 -42
- data/modules/emscripten/system/include/libc/sys/sem.h +0 -82
- data/modules/emscripten/system/include/libc/sys/sendfile.h +0 -22
- data/modules/emscripten/system/include/libc/sys/shm.h +0 -61
- data/modules/emscripten/system/include/libc/sys/signal.h +0 -2
- data/modules/emscripten/system/include/libc/sys/signalfd.h +0 -44
- data/modules/emscripten/system/include/libc/sys/socket.h +0 -299
- data/modules/emscripten/system/include/libc/sys/stat.h +0 -114
- data/modules/emscripten/system/include/libc/sys/statfs.h +0 -32
- data/modules/emscripten/system/include/libc/sys/statvfs.h +0 -57
- data/modules/emscripten/system/include/libc/sys/stropts.h +0 -1
- data/modules/emscripten/system/include/libc/sys/swap.h +0 -21
- data/modules/emscripten/system/include/libc/sys/syscall.h +0 -6
- data/modules/emscripten/system/include/libc/sys/sysctl.h +0 -17
- data/modules/emscripten/system/include/libc/sys/sysinfo.h +0 -36
- data/modules/emscripten/system/include/libc/sys/syslog.h +0 -1
- data/modules/emscripten/system/include/libc/sys/sysmacros.h +0 -15
- data/modules/emscripten/system/include/libc/sys/termios.h +0 -2
- data/modules/emscripten/system/include/libc/sys/time.h +0 -57
- data/modules/emscripten/system/include/libc/sys/timerfd.h +0 -24
- data/modules/emscripten/system/include/libc/sys/times.h +0 -26
- data/modules/emscripten/system/include/libc/sys/timex.h +0 -98
- data/modules/emscripten/system/include/libc/sys/ttydefaults.h +0 -39
- data/modules/emscripten/system/include/libc/sys/types.h +0 -91
- data/modules/emscripten/system/include/libc/sys/ucontext.h +0 -1
- data/modules/emscripten/system/include/libc/sys/uio.h +0 -48
- data/modules/emscripten/system/include/libc/sys/un.h +0 -32
- data/modules/emscripten/system/include/libc/sys/user.h +0 -16
- data/modules/emscripten/system/include/libc/sys/utsname.h +0 -30
- data/modules/emscripten/system/include/libc/sys/vfs.h +0 -1
- data/modules/emscripten/system/include/libc/sys/wait.h +0 -55
- data/modules/emscripten/system/include/libc/sys/xattr.h +0 -30
- data/modules/emscripten/system/include/libc/syscall.h +0 -1
- data/modules/emscripten/system/include/libc/sysexits.h +0 -21
- data/modules/emscripten/system/include/libc/syslog.h +0 -104
- data/modules/emscripten/system/include/libc/tar.h +0 -33
- data/modules/emscripten/system/include/libc/termios.h +0 -46
- data/modules/emscripten/system/include/libc/tgmath.h +0 -270
- data/modules/emscripten/system/include/libc/time.h +0 -132
- data/modules/emscripten/system/include/libc/ucontext.h +0 -25
- data/modules/emscripten/system/include/libc/ulimit.h +0 -17
- data/modules/emscripten/system/include/libc/unistd.h +0 -519
- data/modules/emscripten/system/include/libc/utime.h +0 -24
- data/modules/emscripten/system/include/libc/utmp.h +0 -47
- data/modules/emscripten/system/include/libc/utmpx.h +0 -58
- data/modules/emscripten/system/include/libc/values.h +0 -39
- data/modules/emscripten/system/include/libc/wchar.h +0 -183
- data/modules/emscripten/system/include/libc/wctype.h +0 -77
- data/modules/emscripten/system/include/libc/wordexp.h +0 -42
- data/modules/emscripten/system/include/libcxx/CREDITS.TXT +0 -123
- data/modules/emscripten/system/include/libcxx/LICENSE.txt +0 -76
- data/modules/emscripten/system/include/libcxx/__bit_reference +0 -1287
- data/modules/emscripten/system/include/libcxx/__config +0 -610
- data/modules/emscripten/system/include/libcxx/__debug +0 -218
- data/modules/emscripten/system/include/libcxx/__functional_03 +0 -2130
- data/modules/emscripten/system/include/libcxx/__functional_base +0 -615
- data/modules/emscripten/system/include/libcxx/__functional_base_03 +0 -1087
- data/modules/emscripten/system/include/libcxx/__hash_table +0 -2457
- data/modules/emscripten/system/include/libcxx/__locale +0 -1445
- data/modules/emscripten/system/include/libcxx/__mutex_base +0 -407
- data/modules/emscripten/system/include/libcxx/__split_buffer +0 -654
- data/modules/emscripten/system/include/libcxx/__sso_allocator +0 -77
- data/modules/emscripten/system/include/libcxx/__std_stream +0 -359
- data/modules/emscripten/system/include/libcxx/__tree +0 -2309
- data/modules/emscripten/system/include/libcxx/__tuple +0 -305
- data/modules/emscripten/system/include/libcxx/__tuple_03 +0 -27
- data/modules/emscripten/system/include/libcxx/__undef_min_max +0 -27
- data/modules/emscripten/system/include/libcxx/algorithm +0 -5679
- data/modules/emscripten/system/include/libcxx/array +0 -342
- data/modules/emscripten/system/include/libcxx/atomic +0 -1531
- data/modules/emscripten/system/include/libcxx/bitset +0 -1081
- data/modules/emscripten/system/include/libcxx/cassert +0 -25
- data/modules/emscripten/system/include/libcxx/ccomplex +0 -29
- data/modules/emscripten/system/include/libcxx/cctype +0 -164
- data/modules/emscripten/system/include/libcxx/cerrno +0 -393
- data/modules/emscripten/system/include/libcxx/cfenv +0 -82
- data/modules/emscripten/system/include/libcxx/cfloat +0 -78
- data/modules/emscripten/system/include/libcxx/chrono +0 -1027
- data/modules/emscripten/system/include/libcxx/cinttypes +0 -259
- data/modules/emscripten/system/include/libcxx/ciso646 +0 -25
- data/modules/emscripten/system/include/libcxx/climits +0 -48
- data/modules/emscripten/system/include/libcxx/clocale +0 -53
- data/modules/emscripten/system/include/libcxx/cmath +0 -1690
- data/modules/emscripten/system/include/libcxx/codecvt +0 -550
- data/modules/emscripten/system/include/libcxx/complex +0 -1567
- data/modules/emscripten/system/include/libcxx/complex.h +0 -35
- data/modules/emscripten/system/include/libcxx/condition_variable +0 -256
- data/modules/emscripten/system/include/libcxx/csetjmp +0 -52
- data/modules/emscripten/system/include/libcxx/csignal +0 -58
- data/modules/emscripten/system/include/libcxx/cstdarg +0 -48
- data/modules/emscripten/system/include/libcxx/cstdbool +0 -32
- data/modules/emscripten/system/include/libcxx/cstddef +0 -103
- data/modules/emscripten/system/include/libcxx/cstdint +0 -191
- data/modules/emscripten/system/include/libcxx/cstdio +0 -182
- data/modules/emscripten/system/include/libcxx/cstdlib +0 -172
- data/modules/emscripten/system/include/libcxx/cstring +0 -112
- data/modules/emscripten/system/include/libcxx/ctgmath +0 -29
- data/modules/emscripten/system/include/libcxx/ctime +0 -72
- data/modules/emscripten/system/include/libcxx/cwchar +0 -217
- data/modules/emscripten/system/include/libcxx/cwctype +0 -213
- data/modules/emscripten/system/include/libcxx/deque +0 -2873
- data/modules/emscripten/system/include/libcxx/dynarray +0 -311
- data/modules/emscripten/system/include/libcxx/exception +0 -250
- data/modules/emscripten/system/include/libcxx/ext/__hash +0 -46
- data/modules/emscripten/system/include/libcxx/ext/hash_map +0 -1007
- data/modules/emscripten/system/include/libcxx/ext/hash_set +0 -661
- data/modules/emscripten/system/include/libcxx/forward_list +0 -1663
- data/modules/emscripten/system/include/libcxx/fstream +0 -1431
- data/modules/emscripten/system/include/libcxx/functional +0 -2418
- data/modules/emscripten/system/include/libcxx/future +0 -2615
- data/modules/emscripten/system/include/libcxx/initializer_list +0 -118
- data/modules/emscripten/system/include/libcxx/iomanip +0 -651
- data/modules/emscripten/system/include/libcxx/ios +0 -1023
- data/modules/emscripten/system/include/libcxx/iosfwd +0 -194
- data/modules/emscripten/system/include/libcxx/iostream +0 -60
- data/modules/emscripten/system/include/libcxx/istream +0 -1716
- data/modules/emscripten/system/include/libcxx/iterator +0 -1568
- data/modules/emscripten/system/include/libcxx/limits +0 -813
- data/modules/emscripten/system/include/libcxx/list +0 -2355
- data/modules/emscripten/system/include/libcxx/locale +0 -4465
- data/modules/emscripten/system/include/libcxx/map +0 -2045
- data/modules/emscripten/system/include/libcxx/memory +0 -5448
- data/modules/emscripten/system/include/libcxx/mutex +0 -566
- data/modules/emscripten/system/include/libcxx/new +0 -146
- data/modules/emscripten/system/include/libcxx/numeric +0 -197
- data/modules/emscripten/system/include/libcxx/optional +0 -697
- data/modules/emscripten/system/include/libcxx/ostream +0 -1295
- data/modules/emscripten/system/include/libcxx/queue +0 -717
- data/modules/emscripten/system/include/libcxx/random +0 -6725
- data/modules/emscripten/system/include/libcxx/ratio +0 -487
- data/modules/emscripten/system/include/libcxx/readme.txt +0 -1
- data/modules/emscripten/system/include/libcxx/regex +0 -6487
- data/modules/emscripten/system/include/libcxx/scoped_allocator +0 -578
- data/modules/emscripten/system/include/libcxx/set +0 -1189
- data/modules/emscripten/system/include/libcxx/shared_mutex +0 -419
- data/modules/emscripten/system/include/libcxx/sstream +0 -972
- data/modules/emscripten/system/include/libcxx/stack +0 -292
- data/modules/emscripten/system/include/libcxx/stdexcept +0 -162
- data/modules/emscripten/system/include/libcxx/streambuf +0 -564
- data/modules/emscripten/system/include/libcxx/string +0 -4198
- data/modules/emscripten/system/include/libcxx/strstream +0 -400
- data/modules/emscripten/system/include/libcxx/support/ibm/limits.h +0 -99
- data/modules/emscripten/system/include/libcxx/support/ibm/support.h +0 -54
- data/modules/emscripten/system/include/libcxx/support/ibm/xlocale.h +0 -326
- data/modules/emscripten/system/include/libcxx/support/solaris/floatingpoint.h +0 -5
- data/modules/emscripten/system/include/libcxx/support/solaris/wchar.h +0 -38
- data/modules/emscripten/system/include/libcxx/support/solaris/xlocale.h +0 -146
- data/modules/emscripten/system/include/libcxx/support/win32/limits_win32.h +0 -79
- data/modules/emscripten/system/include/libcxx/support/win32/locale_win32.h +0 -129
- data/modules/emscripten/system/include/libcxx/support/win32/math_win32.h +0 -115
- data/modules/emscripten/system/include/libcxx/support/win32/support.h +0 -119
- data/modules/emscripten/system/include/libcxx/system_error +0 -642
- data/modules/emscripten/system/include/libcxx/tgmath.h +0 -29
- data/modules/emscripten/system/include/libcxx/thread +0 -458
- data/modules/emscripten/system/include/libcxx/tuple +0 -1102
- data/modules/emscripten/system/include/libcxx/type_traits +0 -3292
- data/modules/emscripten/system/include/libcxx/typeindex +0 -103
- data/modules/emscripten/system/include/libcxx/typeinfo +0 -124
- data/modules/emscripten/system/include/libcxx/unordered_map +0 -2078
- data/modules/emscripten/system/include/libcxx/unordered_set +0 -1379
- data/modules/emscripten/system/include/libcxx/utility +0 -768
- data/modules/emscripten/system/include/libcxx/valarray +0 -4779
- data/modules/emscripten/system/include/libcxx/vector +0 -3246
- data/modules/emscripten/system/include/unwind.h +0 -154
- data/modules/emscripten/system/include/uuid/uuid.h +0 -35
- data/modules/emscripten/system/include/zconf.h +0 -428
- data/modules/emscripten/system/include/zlib.h +0 -1613
- data/modules/emscripten/system/lib/compiler-rt/LICENSE.TXT +0 -97
- data/modules/emscripten/system/lib/compiler-rt/divdi3.c +0 -47
- data/modules/emscripten/system/lib/compiler-rt/int_endianness.h +0 -116
- data/modules/emscripten/system/lib/compiler-rt/int_lib.h +0 -46
- data/modules/emscripten/system/lib/compiler-rt/int_math.h +0 -67
- data/modules/emscripten/system/lib/compiler-rt/int_types.h +0 -140
- data/modules/emscripten/system/lib/compiler-rt/int_util.h +0 -29
- data/modules/emscripten/system/lib/compiler-rt/muldi3.c +0 -56
- data/modules/emscripten/system/lib/compiler-rt/readme.txt +0 -20
- data/modules/emscripten/system/lib/compiler-rt/udivdi3.c +0 -36
- data/modules/emscripten/system/lib/compiler-rt/udivmoddi4.c +0 -251
- data/modules/emscripten/system/lib/debugging.cpp +0 -24
- data/modules/emscripten/system/lib/dlmalloc.c +0 -6297
- data/modules/emscripten/system/lib/embind/bind.cpp +0 -63
- data/modules/emscripten/system/lib/libc/gen/err.c +0 -49
- data/modules/emscripten/system/lib/libc/gen/errx.c +0 -49
- data/modules/emscripten/system/lib/libc/gen/verr.c +0 -58
- data/modules/emscripten/system/lib/libc/gen/verrx.c +0 -51
- data/modules/emscripten/system/lib/libc/gen/vwarn.c +0 -55
- data/modules/emscripten/system/lib/libc/gen/vwarnx.c +0 -48
- data/modules/emscripten/system/lib/libc/gen/warn.c +0 -49
- data/modules/emscripten/system/lib/libc/gen/warnx.c +0 -49
- data/modules/emscripten/system/lib/libc/musl/COPYRIGHT +0 -92
- data/modules/emscripten/system/lib/libc/musl/readme.txt +0 -9
- data/modules/emscripten/system/lib/libc/musl/src/ctype/alpha.h +0 -125
- data/modules/emscripten/system/lib/libc/musl/src/ctype/iswalnum.c +0 -7
- data/modules/emscripten/system/lib/libc/musl/src/ctype/iswalpha.c +0 -14
- data/modules/emscripten/system/lib/libc/musl/src/ctype/iswblank.c +0 -8
- data/modules/emscripten/system/lib/libc/musl/src/ctype/iswcntrl.c +0 -10
- data/modules/emscripten/system/lib/libc/musl/src/ctype/iswctype.c +0 -63
- data/modules/emscripten/system/lib/libc/musl/src/ctype/iswdigit.c +0 -9
- data/modules/emscripten/system/lib/libc/musl/src/ctype/iswgraph.c +0 -7
- data/modules/emscripten/system/lib/libc/musl/src/ctype/iswlower.c +0 -6
- data/modules/emscripten/system/lib/libc/musl/src/ctype/iswprint.c +0 -19
- data/modules/emscripten/system/lib/libc/musl/src/ctype/iswpunct.c +0 -12
- data/modules/emscripten/system/lib/libc/musl/src/ctype/iswspace.c +0 -19
- data/modules/emscripten/system/lib/libc/musl/src/ctype/iswupper.c +0 -6
- data/modules/emscripten/system/lib/libc/musl/src/ctype/iswxdigit.c +0 -7
- data/modules/emscripten/system/lib/libc/musl/src/ctype/nonspacing.h +0 -62
- data/modules/emscripten/system/lib/libc/musl/src/ctype/punct.h +0 -109
- data/modules/emscripten/system/lib/libc/musl/src/ctype/towctrans.c +0 -268
- data/modules/emscripten/system/lib/libc/musl/src/ctype/wcswidth.c +0 -8
- data/modules/emscripten/system/lib/libc/musl/src/ctype/wctrans.c +0 -16
- data/modules/emscripten/system/lib/libc/musl/src/ctype/wcwidth.c +0 -29
- data/modules/emscripten/system/lib/libc/musl/src/ctype/wide.h +0 -42
- data/modules/emscripten/system/lib/libc/musl/src/internal/libc.c +0 -22
- data/modules/emscripten/system/lib/libc/musl/src/internal/libc.h +0 -71
- data/modules/emscripten/system/lib/libc/musl/src/internal/locale_impl.h +0 -5
- data/modules/emscripten/system/lib/libc/musl/src/internal/stdio_impl.h +0 -92
- data/modules/emscripten/system/lib/libc/musl/src/locale/big5.h +0 -1085
- data/modules/emscripten/system/lib/libc/musl/src/locale/codepages.h +0 -238
- data/modules/emscripten/system/lib/libc/musl/src/locale/gb18030.h +0 -1836
- data/modules/emscripten/system/lib/libc/musl/src/locale/hkscs.h +0 -390
- data/modules/emscripten/system/lib/libc/musl/src/locale/iconv.c +0 -454
- data/modules/emscripten/system/lib/libc/musl/src/locale/iswalnum_l.c +0 -6
- data/modules/emscripten/system/lib/libc/musl/src/locale/iswalpha_l.c +0 -6
- data/modules/emscripten/system/lib/libc/musl/src/locale/iswblank_l.c +0 -6
- data/modules/emscripten/system/lib/libc/musl/src/locale/iswcntrl_l.c +0 -6
- data/modules/emscripten/system/lib/libc/musl/src/locale/iswctype_l.c +0 -9
- data/modules/emscripten/system/lib/libc/musl/src/locale/iswdigit_l.c +0 -6
- data/modules/emscripten/system/lib/libc/musl/src/locale/iswgraph_l.c +0 -6
- data/modules/emscripten/system/lib/libc/musl/src/locale/iswlower_l.c +0 -6
- data/modules/emscripten/system/lib/libc/musl/src/locale/iswprint_l.c +0 -6
- data/modules/emscripten/system/lib/libc/musl/src/locale/iswpunct_l.c +0 -6
- data/modules/emscripten/system/lib/libc/musl/src/locale/iswspace_l.c +0 -6
- data/modules/emscripten/system/lib/libc/musl/src/locale/iswupper_l.c +0 -6
- data/modules/emscripten/system/lib/libc/musl/src/locale/iswxdigit_l.c +0 -6
- data/modules/emscripten/system/lib/libc/musl/src/locale/jis0208.h +0 -550
- data/modules/emscripten/system/lib/libc/musl/src/locale/ksc.h +0 -640
- data/modules/emscripten/system/lib/libc/musl/src/locale/legacychars.h +0 -39
- data/modules/emscripten/system/lib/libc/musl/src/locale/strfmon.c +0 -101
- data/modules/emscripten/system/lib/libc/musl/src/locale/strxfrm.c +0 -18
- data/modules/emscripten/system/lib/libc/musl/src/locale/towctrans_l.c +0 -6
- data/modules/emscripten/system/lib/libc/musl/src/locale/towlower_l.c +0 -9
- data/modules/emscripten/system/lib/libc/musl/src/locale/towupper_l.c +0 -9
- data/modules/emscripten/system/lib/libc/musl/src/locale/wcscoll.c +0 -16
- data/modules/emscripten/system/lib/libc/musl/src/locale/wcscoll_l.c +0 -6
- data/modules/emscripten/system/lib/libc/musl/src/locale/wcsxfrm.c +0 -21
- data/modules/emscripten/system/lib/libc/musl/src/locale/wcsxfrm_l.c +0 -6
- data/modules/emscripten/system/lib/libc/musl/src/locale/wctrans_l.c +0 -6
- data/modules/emscripten/system/lib/libc/musl/src/locale/wctype_l.c +0 -9
- data/modules/emscripten/system/lib/libc/musl/src/multibyte/btowc.c +0 -7
- data/modules/emscripten/system/lib/libc/musl/src/multibyte/internal.c +0 -38
- data/modules/emscripten/system/lib/libc/musl/src/multibyte/internal.h +0 -22
- data/modules/emscripten/system/lib/libc/musl/src/multibyte/mblen.c +0 -17
- data/modules/emscripten/system/lib/libc/musl/src/multibyte/mbrlen.c +0 -18
- data/modules/emscripten/system/lib/libc/musl/src/multibyte/mbrtowc.c +0 -57
- data/modules/emscripten/system/lib/libc/musl/src/multibyte/mbsinit.c +0 -17
- data/modules/emscripten/system/lib/libc/musl/src/multibyte/mbsnrtowcs.c +0 -65
- data/modules/emscripten/system/lib/libc/musl/src/multibyte/mbsrtowcs.c +0 -100
- data/modules/emscripten/system/lib/libc/musl/src/multibyte/mbstowcs.c +0 -7
- data/modules/emscripten/system/lib/libc/musl/src/multibyte/mbtowc.c +0 -53
- data/modules/emscripten/system/lib/libc/musl/src/multibyte/wcrtomb.c +0 -38
- data/modules/emscripten/system/lib/libc/musl/src/multibyte/wcsnrtombs.c +0 -52
- data/modules/emscripten/system/lib/libc/musl/src/multibyte/wcsrtombs.c +0 -58
- data/modules/emscripten/system/lib/libc/musl/src/multibyte/wcstombs.c +0 -7
- data/modules/emscripten/system/lib/libc/musl/src/multibyte/wctob.c +0 -8
- data/modules/emscripten/system/lib/libc/musl/src/multibyte/wctomb.c +0 -18
- data/modules/emscripten/system/lib/libc/musl/src/regex/regcomp.c +0 -3352
- data/modules/emscripten/system/lib/libc/musl/src/regex/regerror.c +0 -35
- data/modules/emscripten/system/lib/libc/musl/src/regex/regexec.c +0 -1011
- data/modules/emscripten/system/lib/libc/musl/src/regex/tre-mem.c +0 -158
- data/modules/emscripten/system/lib/libc/musl/src/regex/tre.h +0 -231
- data/modules/emscripten/system/lib/libc/musl/src/stdio/fwprintf.c +0 -13
- data/modules/emscripten/system/lib/libc/musl/src/stdio/swprintf.c +0 -14
- data/modules/emscripten/system/lib/libc/musl/src/stdio/vfwprintf.c +0 -361
- data/modules/emscripten/system/lib/libc/musl/src/stdio/vswprintf.c +0 -53
- data/modules/emscripten/system/lib/libc/musl/src/stdio/vwprintf.c +0 -7
- data/modules/emscripten/system/lib/libc/musl/src/stdio/wprintf.c +0 -13
- data/modules/emscripten/system/lib/libc/musl/src/stdlib/ecvt.c +0 -19
- data/modules/emscripten/system/lib/libc/musl/src/stdlib/fcvt.c +0 -25
- data/modules/emscripten/system/lib/libc/musl/src/stdlib/gcvt.c +0 -8
- data/modules/emscripten/system/lib/libc/musl/src/string/wcpcpy.c +0 -6
- data/modules/emscripten/system/lib/libc/musl/src/string/wcpncpy.c +0 -6
- data/modules/emscripten/system/lib/libc/musl/src/string/wcscasecmp.c +0 -7
- data/modules/emscripten/system/lib/libc/musl/src/string/wcscasecmp_l.c +0 -6
- data/modules/emscripten/system/lib/libc/musl/src/string/wcscat.c +0 -7
- data/modules/emscripten/system/lib/libc/musl/src/string/wcschr.c +0 -8
- data/modules/emscripten/system/lib/libc/musl/src/string/wcscmp.c +0 -7
- data/modules/emscripten/system/lib/libc/musl/src/string/wcscpy.c +0 -8
- data/modules/emscripten/system/lib/libc/musl/src/string/wcscspn.c +0 -10
- data/modules/emscripten/system/lib/libc/musl/src/string/wcsdup.c +0 -11
- data/modules/emscripten/system/lib/libc/musl/src/string/wcslen.c +0 -8
- data/modules/emscripten/system/lib/libc/musl/src/string/wcsncasecmp.c +0 -9
- data/modules/emscripten/system/lib/libc/musl/src/string/wcsncasecmp_l.c +0 -6
- data/modules/emscripten/system/lib/libc/musl/src/string/wcsncat.c +0 -10
- data/modules/emscripten/system/lib/libc/musl/src/string/wcsncmp.c +0 -7
- data/modules/emscripten/system/lib/libc/musl/src/string/wcsncpy.c +0 -9
- data/modules/emscripten/system/lib/libc/musl/src/string/wcsnlen.c +0 -8
- data/modules/emscripten/system/lib/libc/musl/src/string/wcspbrk.c +0 -7
- data/modules/emscripten/system/lib/libc/musl/src/string/wcsrchr.c +0 -8
- data/modules/emscripten/system/lib/libc/musl/src/string/wcsspn.c +0 -8
- data/modules/emscripten/system/lib/libc/musl/src/string/wcsstr.c +0 -108
- data/modules/emscripten/system/lib/libc/musl/src/string/wcstok.c +0 -12
- data/modules/emscripten/system/lib/libc/musl/src/string/wcswcs.c +0 -6
- data/modules/emscripten/system/lib/libc/musl/src/string/wmemchr.c +0 -8
- data/modules/emscripten/system/lib/libc/musl/src/string/wmemcmp.c +0 -8
- data/modules/emscripten/system/lib/libc/musl/src/string/wmemcpy.c +0 -9
- data/modules/emscripten/system/lib/libc/musl/src/string/wmemmove.c +0 -12
- data/modules/emscripten/system/lib/libc/musl/src/string/wmemset.c +0 -9
- data/modules/emscripten/system/lib/libc/stdlib/getopt_long.c +0 -511
- data/modules/emscripten/system/lib/libc/stdlib/strtod.c +0 -305
- data/modules/emscripten/system/lib/libc.symbols +0 -81
- data/modules/emscripten/system/lib/libcextra.symbols +0 -115
- data/modules/emscripten/system/lib/libcxx/CREDITS.TXT +0 -123
- data/modules/emscripten/system/lib/libcxx/LICENSE.txt +0 -76
- data/modules/emscripten/system/lib/libcxx/algorithm.cpp +0 -84
- data/modules/emscripten/system/lib/libcxx/bind.cpp +0 -30
- data/modules/emscripten/system/lib/libcxx/chrono.cpp +0 -132
- data/modules/emscripten/system/lib/libcxx/condition_variable.cpp +0 -81
- data/modules/emscripten/system/lib/libcxx/debug.cpp +0 -530
- data/modules/emscripten/system/lib/libcxx/exception.cpp +0 -307
- data/modules/emscripten/system/lib/libcxx/future.cpp +0 -291
- data/modules/emscripten/system/lib/libcxx/hash.cpp +0 -570
- data/modules/emscripten/system/lib/libcxx/ios.cpp +0 -460
- data/modules/emscripten/system/lib/libcxx/iostream.cpp +0 -68
- data/modules/emscripten/system/lib/libcxx/locale.cpp +0 -6169
- data/modules/emscripten/system/lib/libcxx/memory.cpp +0 -223
- data/modules/emscripten/system/lib/libcxx/mutex.cpp +0 -253
- data/modules/emscripten/system/lib/libcxx/new.cpp +0 -239
- data/modules/emscripten/system/lib/libcxx/optional.cpp +0 -25
- data/modules/emscripten/system/lib/libcxx/random.cpp +0 -74
- data/modules/emscripten/system/lib/libcxx/readme.txt +0 -1
- data/modules/emscripten/system/lib/libcxx/regex.cpp +0 -325
- data/modules/emscripten/system/lib/libcxx/shared_mutex.cpp +0 -101
- data/modules/emscripten/system/lib/libcxx/stdexcept.cpp +0 -200
- data/modules/emscripten/system/lib/libcxx/string.cpp +0 -530
- data/modules/emscripten/system/lib/libcxx/strstream.cpp +0 -329
- data/modules/emscripten/system/lib/libcxx/support/solaris/README +0 -4
- data/modules/emscripten/system/lib/libcxx/support/solaris/mbsnrtowcs.inc +0 -76
- data/modules/emscripten/system/lib/libcxx/support/solaris/wcsnrtombs.inc +0 -93
- data/modules/emscripten/system/lib/libcxx/support/solaris/xlocale.c +0 -245
- data/modules/emscripten/system/lib/libcxx/support/win32/locale_win32.cpp +0 -95
- data/modules/emscripten/system/lib/libcxx/support/win32/support.cpp +0 -166
- data/modules/emscripten/system/lib/libcxx/symbols +0 -2699
- data/modules/emscripten/system/lib/libcxx/system_error.cpp +0 -205
- data/modules/emscripten/system/lib/libcxx/thread.cpp +0 -225
- data/modules/emscripten/system/lib/libcxx/typeinfo.cpp +0 -73
- data/modules/emscripten/system/lib/libcxx/utility.cpp +0 -17
- data/modules/emscripten/system/lib/libcxx/valarray.cpp +0 -56
- data/modules/emscripten/system/lib/libcxxabi/CREDITS.TXT +0 -38
- data/modules/emscripten/system/lib/libcxxabi/LICENSE.TXT +0 -76
- data/modules/emscripten/system/lib/libcxxabi/include/cxa_demangle.h +0 -167
- data/modules/emscripten/system/lib/libcxxabi/include/cxxabi.h +0 -175
- data/modules/emscripten/system/lib/libcxxabi/lib/buildit +0 -99
- data/modules/emscripten/system/lib/libcxxabi/readme.txt +0 -1
- data/modules/emscripten/system/lib/libcxxabi/src/abort_message.cpp +0 -50
- data/modules/emscripten/system/lib/libcxxabi/src/abort_message.h +0 -33
- data/modules/emscripten/system/lib/libcxxabi/src/cxa_aux_runtime.cpp +0 -34
- data/modules/emscripten/system/lib/libcxxabi/src/cxa_demangle.cpp +0 -11036
- data/modules/emscripten/system/lib/libcxxabi/src/cxa_exception.cpp +0 -622
- data/modules/emscripten/system/lib/libcxxabi/src/cxa_exception.hpp +0 -123
- data/modules/emscripten/system/lib/libcxxabi/src/cxa_exception_storage.cpp +0 -91
- data/modules/emscripten/system/lib/libcxxabi/src/cxa_guard.cpp +0 -231
- data/modules/emscripten/system/lib/libcxxabi/src/cxa_handlers.cpp +0 -125
- data/modules/emscripten/system/lib/libcxxabi/src/cxa_handlers.hpp +0 -54
- data/modules/emscripten/system/lib/libcxxabi/src/cxa_new_delete.cpp +0 -242
- data/modules/emscripten/system/lib/libcxxabi/src/cxa_personality.cpp +0 -1055
- data/modules/emscripten/system/lib/libcxxabi/src/cxa_unexpected.cpp +0 -27
- data/modules/emscripten/system/lib/libcxxabi/src/cxa_vector.cpp +0 -367
- data/modules/emscripten/system/lib/libcxxabi/src/cxa_virtual.cpp +0 -31
- data/modules/emscripten/system/lib/libcxxabi/src/exception.cpp +0 -41
- data/modules/emscripten/system/lib/libcxxabi/src/fallback_malloc.ipp +0 -174
- data/modules/emscripten/system/lib/libcxxabi/src/private_typeinfo.cpp +0 -1146
- data/modules/emscripten/system/lib/libcxxabi/src/private_typeinfo.h +0 -248
- data/modules/emscripten/system/lib/libcxxabi/src/stdexcept.cpp +0 -169
- data/modules/emscripten/system/lib/libcxxabi/src/typeinfo.cpp +0 -53
- data/modules/emscripten/system/lib/libcxxabi/symbols +0 -236
- data/modules/emscripten/system/lib/sdl.cpp +0 -13
- data/modules/emscripten/system/lib/sdl.symbols +0 -1
- data/modules/emscripten/third_party/CppHeaderParser/CppHeaderParser/CppHeaderParser.py +0 -2347
- data/modules/emscripten/third_party/CppHeaderParser/CppHeaderParser/__init__.py +0 -4
- data/modules/emscripten/third_party/CppHeaderParser/CppHeaderParser/doc/CppHeaderParser.html +0 -657
- data/modules/emscripten/third_party/CppHeaderParser/CppHeaderParser/examples/SampleClass.h +0 -147
- data/modules/emscripten/third_party/CppHeaderParser/CppHeaderParser/examples/readSampleClass.py +0 -74
- data/modules/emscripten/third_party/CppHeaderParser/PKG-INFO +0 -249
- data/modules/emscripten/third_party/CppHeaderParser/README.html +0 -544
- data/modules/emscripten/third_party/CppHeaderParser/README.txt +0 -226
- data/modules/emscripten/third_party/CppHeaderParser/setup.py +0 -43
- data/modules/emscripten/third_party/ansidecl.h +0 -371
- data/modules/emscripten/third_party/closure-compiler/COPYING +0 -202
- data/modules/emscripten/third_party/closure-compiler/README +0 -292
- data/modules/emscripten/third_party/closure-compiler/compiler.jar +0 -0
- data/modules/emscripten/third_party/closure-compiler/readme.txt +0 -3
- data/modules/emscripten/third_party/cp-demangle.h +0 -161
- data/modules/emscripten/third_party/demangle.h +0 -549
- data/modules/emscripten/third_party/demangler.py +0 -49
- data/modules/emscripten/third_party/gcc_demangler.c +0 -4226
- data/modules/emscripten/third_party/gcc_demangler.js +0 -21282
- data/modules/emscripten/third_party/jni/emjvm.cpp +0 -133
- data/modules/emscripten/third_party/jni/emjvm.h +0 -8
- data/modules/emscripten/third_party/jni/emjvm.js +0 -185
- data/modules/emscripten/third_party/jni/jni.h +0 -1154
- data/modules/emscripten/third_party/libiberty.h +0 -634
- data/modules/emscripten/third_party/lzma.js/README.markdown +0 -37
- data/modules/emscripten/third_party/lzma.js/doit.bat +0 -4
- data/modules/emscripten/third_party/lzma.js/doit.sh +0 -44
- data/modules/emscripten/third_party/lzma.js/lzip/AUTHORS +0 -7
- data/modules/emscripten/third_party/lzma.js/lzip/COPYING +0 -676
- data/modules/emscripten/third_party/lzma.js/lzip/ChangeLog +0 -201
- data/modules/emscripten/third_party/lzma.js/lzip/INSTALL +0 -56
- data/modules/emscripten/third_party/lzma.js/lzip/Makefile +0 -160
- data/modules/emscripten/third_party/lzma.js/lzip/Makefile.in +0 -138
- data/modules/emscripten/third_party/lzma.js/lzip/NEWS +0 -22
- data/modules/emscripten/third_party/lzma.js/lzip/README +0 -77
- data/modules/emscripten/third_party/lzma.js/lzip/arg_parser.cc +0 -204
- data/modules/emscripten/third_party/lzma.js/lzip/arg_parser.h +0 -106
- data/modules/emscripten/third_party/lzma.js/lzip/configure +0 -192
- data/modules/emscripten/third_party/lzma.js/lzip/decoder.cc +0 -252
- data/modules/emscripten/third_party/lzma.js/lzip/decoder.h +0 -268
- data/modules/emscripten/third_party/lzma.js/lzip/encoder.cc +0 -643
- data/modules/emscripten/third_party/lzma.js/lzip/encoder.h +0 -582
- data/modules/emscripten/third_party/lzma.js/lzip/fast_encoder.cc +0 -378
- data/modules/emscripten/third_party/lzma.js/lzip/fast_encoder.h +0 -171
- data/modules/emscripten/third_party/lzma.js/lzip/lzip.h +0 -264
- data/modules/emscripten/third_party/lzma.js/lzip/main.cc +0 -545
- data/modules/emscripten/third_party/lzma.js/lzma-decoder.js +0 -27
- data/modules/emscripten/third_party/lzma.js/lzma-full.js +0 -27
- data/modules/emscripten/third_party/lzma.js/native_test.sh +0 -5
- data/modules/emscripten/third_party/lzma.js/post.js +0 -13
- data/modules/emscripten/third_party/lzma.js/pre.js +0 -13
- data/modules/emscripten/third_party/lzma.js/test-decoder.js +0 -39
- data/modules/emscripten/third_party/lzma.js/test-full.html +0 -9
- data/modules/emscripten/third_party/lzma.js/test-full.js +0 -78
- data/modules/emscripten/third_party/ply/ANNOUNCE +0 -40
- data/modules/emscripten/third_party/ply/CHANGES +0 -1093
- data/modules/emscripten/third_party/ply/PKG-INFO +0 -22
- data/modules/emscripten/third_party/ply/README +0 -271
- data/modules/emscripten/third_party/ply/TODO +0 -16
- data/modules/emscripten/third_party/ply/doc/internal.html +0 -874
- data/modules/emscripten/third_party/ply/doc/makedoc.py +0 -194
- data/modules/emscripten/third_party/ply/doc/ply.html +0 -3262
- data/modules/emscripten/third_party/ply/example/BASIC/README +0 -79
- data/modules/emscripten/third_party/ply/example/BASIC/basic.py +0 -71
- data/modules/emscripten/third_party/ply/example/BASIC/basiclex.py +0 -74
- data/modules/emscripten/third_party/ply/example/BASIC/basiclog.py +0 -79
- data/modules/emscripten/third_party/ply/example/BASIC/basinterp.py +0 -441
- data/modules/emscripten/third_party/ply/example/BASIC/basparse.py +0 -424
- data/modules/emscripten/third_party/ply/example/BASIC/dim.bas +0 -14
- data/modules/emscripten/third_party/ply/example/BASIC/func.bas +0 -5
- data/modules/emscripten/third_party/ply/example/BASIC/gcd.bas +0 -22
- data/modules/emscripten/third_party/ply/example/BASIC/gosub.bas +0 -13
- data/modules/emscripten/third_party/ply/example/BASIC/hello.bas +0 -4
- data/modules/emscripten/third_party/ply/example/BASIC/linear.bas +0 -17
- data/modules/emscripten/third_party/ply/example/BASIC/maxsin.bas +0 -12
- data/modules/emscripten/third_party/ply/example/BASIC/powers.bas +0 -13
- data/modules/emscripten/third_party/ply/example/BASIC/rand.bas +0 -4
- data/modules/emscripten/third_party/ply/example/BASIC/sales.bas +0 -20
- data/modules/emscripten/third_party/ply/example/BASIC/sears.bas +0 -18
- data/modules/emscripten/third_party/ply/example/BASIC/sqrt1.bas +0 -5
- data/modules/emscripten/third_party/ply/example/BASIC/sqrt2.bas +0 -4
- data/modules/emscripten/third_party/ply/example/GardenSnake/GardenSnake.py +0 -709
- data/modules/emscripten/third_party/ply/example/GardenSnake/README +0 -5
- data/modules/emscripten/third_party/ply/example/README +0 -10
- data/modules/emscripten/third_party/ply/example/ansic/README +0 -2
- data/modules/emscripten/third_party/ply/example/ansic/clex.py +0 -164
- data/modules/emscripten/third_party/ply/example/ansic/cparse.py +0 -863
- data/modules/emscripten/third_party/ply/example/calc/calc.py +0 -107
- data/modules/emscripten/third_party/ply/example/calcdebug/calc.py +0 -113
- data/modules/emscripten/third_party/ply/example/classcalc/calc.py +0 -157
- data/modules/emscripten/third_party/ply/example/cleanup.sh +0 -2
- data/modules/emscripten/third_party/ply/example/closurecalc/calc.py +0 -130
- data/modules/emscripten/third_party/ply/example/hedit/hedit.py +0 -48
- data/modules/emscripten/third_party/ply/example/newclasscalc/calc.py +0 -160
- data/modules/emscripten/third_party/ply/example/optcalc/README +0 -9
- data/modules/emscripten/third_party/ply/example/optcalc/calc.py +0 -119
- data/modules/emscripten/third_party/ply/example/unicalc/calc.py +0 -117
- data/modules/emscripten/third_party/ply/example/yply/README +0 -41
- data/modules/emscripten/third_party/ply/example/yply/ylex.py +0 -112
- data/modules/emscripten/third_party/ply/example/yply/yparse.py +0 -217
- data/modules/emscripten/third_party/ply/example/yply/yply.py +0 -53
- data/modules/emscripten/third_party/ply/ply/__init__.py +0 -4
- data/modules/emscripten/third_party/ply/ply/cpp.py +0 -898
- data/modules/emscripten/third_party/ply/ply/ctokens.py +0 -133
- data/modules/emscripten/third_party/ply/ply/lex.py +0 -1058
- data/modules/emscripten/third_party/ply/ply/yacc.py +0 -3276
- data/modules/emscripten/third_party/ply/setup.py +0 -31
- data/modules/emscripten/third_party/ply/test/README +0 -7
- data/modules/emscripten/third_party/ply/test/calclex.py +0 -49
- data/modules/emscripten/third_party/ply/test/cleanup.sh +0 -4
- data/modules/emscripten/third_party/ply/test/lex_closure.py +0 -54
- data/modules/emscripten/third_party/ply/test/lex_doc1.py +0 -26
- data/modules/emscripten/third_party/ply/test/lex_dup1.py +0 -29
- data/modules/emscripten/third_party/ply/test/lex_dup2.py +0 -33
- data/modules/emscripten/third_party/ply/test/lex_dup3.py +0 -31
- data/modules/emscripten/third_party/ply/test/lex_empty.py +0 -20
- data/modules/emscripten/third_party/ply/test/lex_error1.py +0 -24
- data/modules/emscripten/third_party/ply/test/lex_error2.py +0 -26
- data/modules/emscripten/third_party/ply/test/lex_error3.py +0 -27
- data/modules/emscripten/third_party/ply/test/lex_error4.py +0 -27
- data/modules/emscripten/third_party/ply/test/lex_hedit.py +0 -47
- data/modules/emscripten/third_party/ply/test/lex_ignore.py +0 -31
- data/modules/emscripten/third_party/ply/test/lex_ignore2.py +0 -29
- data/modules/emscripten/third_party/ply/test/lex_literal1.py +0 -25
- data/modules/emscripten/third_party/ply/test/lex_literal2.py +0 -25
- data/modules/emscripten/third_party/ply/test/lex_many_tokens.py +0 -27
- data/modules/emscripten/third_party/ply/test/lex_module.py +0 -10
- data/modules/emscripten/third_party/ply/test/lex_module_import.py +0 -42
- data/modules/emscripten/third_party/ply/test/lex_object.py +0 -55
- data/modules/emscripten/third_party/ply/test/lex_opt_alias.py +0 -54
- data/modules/emscripten/third_party/ply/test/lex_optimize.py +0 -50
- data/modules/emscripten/third_party/ply/test/lex_optimize2.py +0 -50
- data/modules/emscripten/third_party/ply/test/lex_optimize3.py +0 -52
- data/modules/emscripten/third_party/ply/test/lex_re1.py +0 -27
- data/modules/emscripten/third_party/ply/test/lex_re2.py +0 -27
- data/modules/emscripten/third_party/ply/test/lex_re3.py +0 -29
- data/modules/emscripten/third_party/ply/test/lex_rule1.py +0 -27
- data/modules/emscripten/third_party/ply/test/lex_rule2.py +0 -29
- data/modules/emscripten/third_party/ply/test/lex_rule3.py +0 -27
- data/modules/emscripten/third_party/ply/test/lex_state1.py +0 -40
- data/modules/emscripten/third_party/ply/test/lex_state2.py +0 -40
- data/modules/emscripten/third_party/ply/test/lex_state3.py +0 -42
- data/modules/emscripten/third_party/ply/test/lex_state4.py +0 -41
- data/modules/emscripten/third_party/ply/test/lex_state5.py +0 -40
- data/modules/emscripten/third_party/ply/test/lex_state_noerror.py +0 -39
- data/modules/emscripten/third_party/ply/test/lex_state_norule.py +0 -40
- data/modules/emscripten/third_party/ply/test/lex_state_try.py +0 -45
- data/modules/emscripten/third_party/ply/test/lex_token1.py +0 -19
- data/modules/emscripten/third_party/ply/test/lex_token2.py +0 -22
- data/modules/emscripten/third_party/ply/test/lex_token3.py +0 -24
- data/modules/emscripten/third_party/ply/test/lex_token4.py +0 -26
- data/modules/emscripten/third_party/ply/test/lex_token5.py +0 -31
- data/modules/emscripten/third_party/ply/test/lex_token_dup.py +0 -29
- data/modules/emscripten/third_party/ply/test/testlex.py +0 -606
- data/modules/emscripten/third_party/ply/test/testyacc.py +0 -347
- data/modules/emscripten/third_party/ply/test/yacc_badargs.py +0 -68
- data/modules/emscripten/third_party/ply/test/yacc_badid.py +0 -77
- data/modules/emscripten/third_party/ply/test/yacc_badprec.py +0 -64
- data/modules/emscripten/third_party/ply/test/yacc_badprec2.py +0 -68
- data/modules/emscripten/third_party/ply/test/yacc_badprec3.py +0 -68
- data/modules/emscripten/third_party/ply/test/yacc_badrule.py +0 -68
- data/modules/emscripten/third_party/ply/test/yacc_badtok.py +0 -68
- data/modules/emscripten/third_party/ply/test/yacc_dup.py +0 -68
- data/modules/emscripten/third_party/ply/test/yacc_error1.py +0 -68
- data/modules/emscripten/third_party/ply/test/yacc_error2.py +0 -68
- data/modules/emscripten/third_party/ply/test/yacc_error3.py +0 -67
- data/modules/emscripten/third_party/ply/test/yacc_error4.py +0 -72
- data/modules/emscripten/third_party/ply/test/yacc_inf.py +0 -56
- data/modules/emscripten/third_party/ply/test/yacc_literal.py +0 -69
- data/modules/emscripten/third_party/ply/test/yacc_misplaced.py +0 -68
- data/modules/emscripten/third_party/ply/test/yacc_missing1.py +0 -68
- data/modules/emscripten/third_party/ply/test/yacc_nested.py +0 -33
- data/modules/emscripten/third_party/ply/test/yacc_nodoc.py +0 -67
- data/modules/emscripten/third_party/ply/test/yacc_noerror.py +0 -66
- data/modules/emscripten/third_party/ply/test/yacc_nop.py +0 -68
- data/modules/emscripten/third_party/ply/test/yacc_notfunc.py +0 -66
- data/modules/emscripten/third_party/ply/test/yacc_notok.py +0 -67
- data/modules/emscripten/third_party/ply/test/yacc_prec1.py +0 -68
- data/modules/emscripten/third_party/ply/test/yacc_rr.py +0 -72
- data/modules/emscripten/third_party/ply/test/yacc_rr_unused.py +0 -30
- data/modules/emscripten/third_party/ply/test/yacc_simple.py +0 -68
- data/modules/emscripten/third_party/ply/test/yacc_sr.py +0 -63
- data/modules/emscripten/third_party/ply/test/yacc_term1.py +0 -68
- data/modules/emscripten/third_party/ply/test/yacc_unused.py +0 -77
- data/modules/emscripten/third_party/ply/test/yacc_unused_rule.py +0 -72
- data/modules/emscripten/third_party/ply/test/yacc_uprec.py +0 -63
- data/modules/emscripten/third_party/ply/test/yacc_uprec2.py +0 -63
- data/modules/emscripten/third_party/readme.txt +0 -7
- data/modules/emscripten/third_party/stb_image.c +0 -4673
- data/modules/emscripten/third_party/websockify/CHANGES.txt +0 -23
- data/modules/emscripten/third_party/websockify/LICENSE.txt +0 -16
- data/modules/emscripten/third_party/websockify/MANIFEST.in +0 -1
- data/modules/emscripten/third_party/websockify/Makefile +0 -11
- data/modules/emscripten/third_party/websockify/README.md +0 -168
- data/modules/emscripten/third_party/websockify/Windows/Windows Service Readme.txt +0 -39
- data/modules/emscripten/third_party/websockify/Windows/noVNC Websocket Service Project/Program.cs +0 -24
- data/modules/emscripten/third_party/websockify/Windows/noVNC Websocket Service Project/ProjectInstaller.Designer.cs +0 -61
- data/modules/emscripten/third_party/websockify/Windows/noVNC Websocket Service Project/ProjectInstaller.cs +0 -19
- data/modules/emscripten/third_party/websockify/Windows/noVNC Websocket Service Project/ProjectInstaller.resx +0 -129
- data/modules/emscripten/third_party/websockify/Windows/noVNC Websocket Service Project/Properties/AssemblyInfo.cs +0 -36
- data/modules/emscripten/third_party/websockify/Windows/noVNC Websocket Service Project/Service1.Designer.cs +0 -37
- data/modules/emscripten/third_party/websockify/Windows/noVNC Websocket Service Project/Service1.cs +0 -41
- data/modules/emscripten/third_party/websockify/Windows/noVNC Websocket Service Project/noVNC Websocket.csproj +0 -75
- data/modules/emscripten/third_party/websockify/Windows/noVNC Websocket Service Project/noVNC Websocket.sln +0 -20
- data/modules/emscripten/third_party/websockify/docs/LICENSE.GPL-3 +0 -621
- data/modules/emscripten/third_party/websockify/docs/LICENSE.LGPL-3 +0 -165
- data/modules/emscripten/third_party/websockify/docs/LICENSE.MPL-2.0 +0 -373
- data/modules/emscripten/third_party/websockify/docs/TODO +0 -9
- data/modules/emscripten/third_party/websockify/docs/flash_policy.txt +0 -4
- data/modules/emscripten/third_party/websockify/docs/latency_results.txt +0 -114
- data/modules/emscripten/third_party/websockify/docs/notes +0 -17
- data/modules/emscripten/third_party/websockify/docs/release.txt +0 -9
- data/modules/emscripten/third_party/websockify/docs/websockify.1 +0 -110
- data/modules/emscripten/third_party/websockify/include/VT100.js +0 -919
- data/modules/emscripten/third_party/websockify/include/base64.js +0 -114
- data/modules/emscripten/third_party/websockify/include/keysym.js +0 -99
- data/modules/emscripten/third_party/websockify/include/util.js +0 -359
- data/modules/emscripten/third_party/websockify/include/web-socket-js/README.txt +0 -109
- data/modules/emscripten/third_party/websockify/include/web-socket-js/WebSocketMain.swf +0 -0
- data/modules/emscripten/third_party/websockify/include/web-socket-js/swfobject.js +0 -4
- data/modules/emscripten/third_party/websockify/include/web-socket-js/web_socket.js +0 -391
- data/modules/emscripten/third_party/websockify/include/websock.js +0 -422
- data/modules/emscripten/third_party/websockify/include/webutil.js +0 -216
- data/modules/emscripten/third_party/websockify/include/wsirc.js +0 -235
- data/modules/emscripten/third_party/websockify/include/wstelnet.js +0 -335
- data/modules/emscripten/third_party/websockify/other/Makefile +0 -14
- data/modules/emscripten/third_party/websockify/other/README.md +0 -51
- data/modules/emscripten/third_party/websockify/other/launch.sh +0 -108
- data/modules/emscripten/third_party/websockify/other/project.clj +0 -13
- data/modules/emscripten/third_party/websockify/other/websocket.c +0 -802
- data/modules/emscripten/third_party/websockify/other/websocket.h +0 -84
- data/modules/emscripten/third_party/websockify/other/websocket.rb +0 -456
- data/modules/emscripten/third_party/websockify/other/websockify.c +0 -385
- data/modules/emscripten/third_party/websockify/other/websockify.clj +0 -233
- data/modules/emscripten/third_party/websockify/other/websockify.js +0 -196
- data/modules/emscripten/third_party/websockify/other/websockify.rb +0 -171
- data/modules/emscripten/third_party/websockify/other/wswrap +0 -22
- data/modules/emscripten/third_party/websockify/rebind +0 -18
- data/modules/emscripten/third_party/websockify/rebind.c +0 -94
- data/modules/emscripten/third_party/websockify/run +0 -5
- data/modules/emscripten/third_party/websockify/setup.py +0 -30
- data/modules/emscripten/third_party/websockify/tests/b64_vs_utf8.py +0 -29
- data/modules/emscripten/third_party/websockify/tests/base64.html +0 -91
- data/modules/emscripten/third_party/websockify/tests/base64.js +0 -12
- data/modules/emscripten/third_party/websockify/tests/echo.html +0 -148
- data/modules/emscripten/third_party/websockify/tests/echo.py +0 -75
- data/modules/emscripten/third_party/websockify/tests/echo.rb +0 -62
- data/modules/emscripten/third_party/websockify/tests/latency.html +0 -290
- data/modules/emscripten/third_party/websockify/tests/latency.py +0 -75
- data/modules/emscripten/third_party/websockify/tests/load.html +0 -250
- data/modules/emscripten/third_party/websockify/tests/load.py +0 -167
- data/modules/emscripten/third_party/websockify/tests/plain_echo.html +0 -168
- data/modules/emscripten/third_party/websockify/tests/simple.html +0 -68
- data/modules/emscripten/third_party/websockify/tests/utf8-list.py +0 -22
- data/modules/emscripten/third_party/websockify/websockify/__init__.py +0 -2
- data/modules/emscripten/third_party/websockify/websockify/websocket.py +0 -982
- data/modules/emscripten/third_party/websockify/websockify/websocketproxy.py +0 -393
- data/modules/emscripten/third_party/websockify/websockify.py +0 -5
- data/modules/emscripten/third_party/websockify/wsirc.html +0 -99
- data/modules/emscripten/third_party/websockify/wstelnet.html +0 -74
- data/modules/emscripten/tools/__init__.py +0 -0
- data/modules/emscripten/tools/asm_module.py +0 -275
- data/modules/emscripten/tools/autodebugger.py +0 -291
- data/modules/emscripten/tools/autodebugger_c.py +0 -37
- data/modules/emscripten/tools/autodebugger_indenter.py +0 -18
- data/modules/emscripten/tools/autodebugger_js.py +0 -47
- data/modules/emscripten/tools/autodediffer.py +0 -60
- data/modules/emscripten/tools/bindings_generator.py +0 -832
- data/modules/emscripten/tools/bisect_pair.py +0 -88
- data/modules/emscripten/tools/cache.py +0 -196
- data/modules/emscripten/tools/clean_webconsole.py +0 -34
- data/modules/emscripten/tools/crunch-worker.js +0 -124
- data/modules/emscripten/tools/diff_autodebugger.py +0 -15
- data/modules/emscripten/tools/eliminator/asm-eliminator-test-output.js +0 -307
- data/modules/emscripten/tools/eliminator/asm-eliminator-test.js +0 -382
- data/modules/emscripten/tools/eliminator/eliminator-test-output.js +0 -6136
- data/modules/emscripten/tools/eliminator/eliminator-test.js +0 -8879
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/README.html +0 -888
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/README.org +0 -463
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/bin/uglifyjs +0 -317
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/docstyle.css +0 -75
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/lib/object-ast.js +0 -75
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/lib/parse-js.js +0 -1363
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/lib/process.js +0 -2005
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/lib/squeeze-more.js +0 -51
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/package.json +0 -22
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/beautify.js +0 -28
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/testparser.js +0 -402
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/array1.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/array2.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/array3.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/array4.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/assignment.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/concatstring.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/const.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/empty-blocks.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/forstatement.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/if.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/ifreturn.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/ifreturn2.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/issue10.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/issue11.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/issue13.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/issue14.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/issue16.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/issue17.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/issue20.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/issue21.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/issue25.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/issue27.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/issue28.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/issue29.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/issue30.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/issue34.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/issue4.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/issue48.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/issue50.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/issue53.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/issue54.1.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/issue68.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/issue69.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/issue9.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/mangle.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/strict-equals.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/var.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/expected/with.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/array1.js +0 -3
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/array2.js +0 -4
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/array3.js +0 -4
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/array4.js +0 -6
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/assignment.js +0 -20
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/concatstring.js +0 -3
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/const.js +0 -5
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/empty-blocks.js +0 -4
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/forstatement.js +0 -10
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/if.js +0 -6
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/ifreturn.js +0 -9
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/ifreturn2.js +0 -16
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/issue10.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/issue11.js +0 -3
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/issue13.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/issue14.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/issue16.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/issue17.js +0 -4
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/issue20.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/issue21.js +0 -6
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/issue25.js +0 -7
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/issue27.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/issue28.js +0 -3
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/issue29.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/issue30.js +0 -3
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/issue34.js +0 -3
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/issue4.js +0 -3
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/issue48.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/issue50.js +0 -9
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/issue53.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/issue54.1.js +0 -3
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/issue68.js +0 -5
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/issue69.js +0 -1
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/issue9.js +0 -4
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/mangle.js +0 -5
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/strict-equals.js +0 -3
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/var.js +0 -3
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/compress/test/with.js +0 -2
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/test/unit/scripts.js +0 -55
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/tmp/hoist.js +0 -33
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/tmp/instrument.js +0 -97
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/tmp/instrument2.js +0 -138
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/tmp/test.js +0 -16
- data/modules/emscripten/tools/eliminator/node_modules/uglify-js/uglify-js.js +0 -17
- data/modules/emscripten/tools/eliminator/safe-eliminator-test-output.js +0 -85
- data/modules/emscripten/tools/eliminator/safe-eliminator-test.js +0 -103
- data/modules/emscripten/tools/emconfiguren.py +0 -19
- data/modules/emscripten/tools/emmaken.py +0 -230
- data/modules/emscripten/tools/emmakenxx.py +0 -18
- data/modules/emscripten/tools/exec_llvm.py +0 -50
- data/modules/emscripten/tools/file2json.py +0 -49
- data/modules/emscripten/tools/file_packager.py +0 -719
- data/modules/emscripten/tools/find_bigfuncs.py +0 -23
- data/modules/emscripten/tools/find_bigis.py +0 -18
- data/modules/emscripten/tools/find_bigvars.py +0 -24
- data/modules/emscripten/tools/fix_closure.py +0 -88
- data/modules/emscripten/tools/gen_struct_info.py +0 -509
- data/modules/emscripten/tools/ie7_fix.py +0 -14
- data/modules/emscripten/tools/js-optimizer.js +0 -4023
- data/modules/emscripten/tools/js_optimizer.py +0 -357
- data/modules/emscripten/tools/jsrun.py +0 -37
- data/modules/emscripten/tools/ll-strip.py +0 -56
- data/modules/emscripten/tools/make_file.py +0 -19
- data/modules/emscripten/tools/make_minigzip.py +0 -13
- data/modules/emscripten/tools/merge_asm.py +0 -26
- data/modules/emscripten/tools/namespacer.py +0 -95
- data/modules/emscripten/tools/nativize_llvm.py +0 -34
- data/modules/emscripten/tools/node_modules/source-map/CHANGELOG.md +0 -58
- data/modules/emscripten/tools/node_modules/source-map/LICENSE +0 -28
- data/modules/emscripten/tools/node_modules/source-map/Makefile.dryice.js +0 -166
- data/modules/emscripten/tools/node_modules/source-map/README.md +0 -347
- data/modules/emscripten/tools/node_modules/source-map/build/assert-shim.js +0 -56
- data/modules/emscripten/tools/node_modules/source-map/build/mini-require.js +0 -152
- data/modules/emscripten/tools/node_modules/source-map/build/prefix-source-map.jsm +0 -20
- data/modules/emscripten/tools/node_modules/source-map/build/prefix-utils.jsm +0 -18
- data/modules/emscripten/tools/node_modules/source-map/build/suffix-browser.js +0 -8
- data/modules/emscripten/tools/node_modules/source-map/build/suffix-source-map.jsm +0 -6
- data/modules/emscripten/tools/node_modules/source-map/build/suffix-utils.jsm +0 -21
- data/modules/emscripten/tools/node_modules/source-map/build/test-prefix.js +0 -8
- data/modules/emscripten/tools/node_modules/source-map/build/test-suffix.js +0 -3
- data/modules/emscripten/tools/node_modules/source-map/lib/source-map/array-set.js +0 -96
- data/modules/emscripten/tools/node_modules/source-map/lib/source-map/base64-vlq.js +0 -144
- data/modules/emscripten/tools/node_modules/source-map/lib/source-map/base64.js +0 -42
- data/modules/emscripten/tools/node_modules/source-map/lib/source-map/binary-search.js +0 -81
- data/modules/emscripten/tools/node_modules/source-map/lib/source-map/source-map-consumer.js +0 -430
- data/modules/emscripten/tools/node_modules/source-map/lib/source-map/source-map-generator.js +0 -381
- data/modules/emscripten/tools/node_modules/source-map/lib/source-map/source-node.js +0 -353
- data/modules/emscripten/tools/node_modules/source-map/lib/source-map/util.js +0 -117
- data/modules/emscripten/tools/node_modules/source-map/lib/source-map.js +0 -8
- data/modules/emscripten/tools/node_modules/source-map/node_modules/amdefine/LICENSE +0 -58
- data/modules/emscripten/tools/node_modules/source-map/node_modules/amdefine/README.md +0 -119
- data/modules/emscripten/tools/node_modules/source-map/node_modules/amdefine/amdefine.js +0 -299
- data/modules/emscripten/tools/node_modules/source-map/node_modules/amdefine/package.json +0 -33
- data/modules/emscripten/tools/node_modules/source-map/package.json +0 -74
- data/modules/emscripten/tools/node_modules/source-map/test/run-tests.js +0 -73
- data/modules/emscripten/tools/node_modules/source-map/test/source-map/test-api.js +0 -26
- data/modules/emscripten/tools/node_modules/source-map/test/source-map/test-array-set.js +0 -71
- data/modules/emscripten/tools/node_modules/source-map/test/source-map/test-base64-vlq.js +0 -24
- data/modules/emscripten/tools/node_modules/source-map/test/source-map/test-base64.js +0 -35
- data/modules/emscripten/tools/node_modules/source-map/test/source-map/test-binary-search.js +0 -54
- data/modules/emscripten/tools/node_modules/source-map/test/source-map/test-dog-fooding.js +0 -72
- data/modules/emscripten/tools/node_modules/source-map/test/source-map/test-source-map-consumer.js +0 -306
- data/modules/emscripten/tools/node_modules/source-map/test/source-map/test-source-map-generator.js +0 -391
- data/modules/emscripten/tools/node_modules/source-map/test/source-map/test-source-node.js +0 -282
- data/modules/emscripten/tools/node_modules/source-map/test/source-map/util.js +0 -152
- data/modules/emscripten/tools/reproduceriter.js +0 -216
- data/modules/emscripten/tools/reproduceriter.py +0 -160
- data/modules/emscripten/tools/response_file.py +0 -34
- data/modules/emscripten/tools/scan_js.py +0 -20
- data/modules/emscripten/tools/scan_ll.py +0 -18
- data/modules/emscripten/tools/scons/site_scons/site_tools/emscripten/__init__.py +0 -3
- data/modules/emscripten/tools/scons/site_scons/site_tools/emscripten/emscripten.py +0 -46
- data/modules/emscripten/tools/settings_template_readonly.py +0 -49
- data/modules/emscripten/tools/shared.py +0 -1705
- data/modules/emscripten/tools/source-maps/sourcemap2json.js +0 -15
- data/modules/emscripten/tools/source-maps/sourcemapper.js +0 -208
- data/modules/emscripten/tools/split.py +0 -105
- data/modules/emscripten/tools/split_asm.py +0 -30
- data/modules/emscripten/tools/tempfiles.py +0 -41
- data/modules/emscripten/tools/test-js-optimizer-asm-last-output.js +0 -75
- data/modules/emscripten/tools/test-js-optimizer-asm-last.js +0 -91
- data/modules/emscripten/tools/test-js-optimizer-asm-minlast-output.js +0 -2
- data/modules/emscripten/tools/test-js-optimizer-asm-minlast.js +0 -8
- data/modules/emscripten/tools/test-js-optimizer-asm-outline1-output.js +0 -929
- data/modules/emscripten/tools/test-js-optimizer-asm-outline1.js +0 -351
- data/modules/emscripten/tools/test-js-optimizer-asm-outline2-output.js +0 -793
- data/modules/emscripten/tools/test-js-optimizer-asm-outline2.js +0 -606
- data/modules/emscripten/tools/test-js-optimizer-asm-outline3-output.js +0 -28
- data/modules/emscripten/tools/test-js-optimizer-asm-outline3.js +0 -30
- data/modules/emscripten/tools/test-js-optimizer-asm-pre-output.js +0 -522
- data/modules/emscripten/tools/test-js-optimizer-asm-pre.js +0 -533
- data/modules/emscripten/tools/test-js-optimizer-asm-regs-min-output.js +0 -36
- data/modules/emscripten/tools/test-js-optimizer-asm-regs-min.js +0 -37
- data/modules/emscripten/tools/test-js-optimizer-asm-regs-output.js +0 -106
- data/modules/emscripten/tools/test-js-optimizer-asm-regs.js +0 -110
- data/modules/emscripten/tools/test-js-optimizer-asm-relocate-output.js +0 -9
- data/modules/emscripten/tools/test-js-optimizer-asm-relocate.js +0 -12
- data/modules/emscripten/tools/test-js-optimizer-output.js +0 -291
- data/modules/emscripten/tools/test-js-optimizer-regs-output.js +0 -232
- data/modules/emscripten/tools/test-js-optimizer-regs.js +0 -237
- data/modules/emscripten/tools/test-js-optimizer-t2-output.js +0 -91
- data/modules/emscripten/tools/test-js-optimizer-t2.js +0 -92
- data/modules/emscripten/tools/test-js-optimizer-t2c-output.js +0 -17
- data/modules/emscripten/tools/test-js-optimizer-t2c.js +0 -18
- data/modules/emscripten/tools/test-js-optimizer-t3-output.js +0 -49
- data/modules/emscripten/tools/test-js-optimizer-t3.js +0 -50
- data/modules/emscripten/tools/test-js-optimizer.js +0 -401
- data/modules/emscripten/tools/validate_asmjs.py +0 -82
- data/modules/mruby/mrblib/print.rb +0 -18
- data/modules/mruby/src/re.h +0 -12
@@ -1,1781 +0,0 @@
|
|
1
|
-
//"use strict";
|
2
|
-
|
3
|
-
// Analyze intertype data. Calculates things that are necessary in order
|
4
|
-
// to do the final conversion into JavaScript later, for example,
|
5
|
-
// properties of variables, loop structures of functions, etc.
|
6
|
-
|
7
|
-
var VAR_NATIVE = 'native';
|
8
|
-
var VAR_NATIVIZED = 'nativized';
|
9
|
-
var VAR_EMULATED = 'emulated';
|
10
|
-
|
11
|
-
var ENTRY_IDENT = toNiceIdent('%0');
|
12
|
-
|
13
|
-
function recomputeLines(func) {
|
14
|
-
func.lines = func.labels.map(function(label) { return label.lines }).reduce(concatenator, []);
|
15
|
-
}
|
16
|
-
|
17
|
-
// Handy sets
|
18
|
-
|
19
|
-
var BRANCH_INVOKE = set('branch', 'invoke');
|
20
|
-
var LABEL_ENDERS = set('branch', 'return', 'switch');
|
21
|
-
var SIDE_EFFECT_CAUSERS = set('call', 'invoke', 'atomic');
|
22
|
-
var UNUNFOLDABLE = set('value', 'structvalue', 'type', 'phiparam');
|
23
|
-
var SHADOW_FLIP = { i64: 'double', double: 'i64' }; //, i32: 'float', float: 'i32' };
|
24
|
-
|
25
|
-
// Analyzer
|
26
|
-
|
27
|
-
function analyzer(data, sidePass) {
|
28
|
-
//B.start('analyzer');
|
29
|
-
var mainPass = !sidePass;
|
30
|
-
|
31
|
-
var item = { items: data };
|
32
|
-
var data = item;
|
33
|
-
|
34
|
-
var newTypes = {};
|
35
|
-
|
36
|
-
// Gather
|
37
|
-
// Single-liners
|
38
|
-
['globalVariable', 'functionStub', 'unparsedFunction', 'unparsedGlobals', 'unparsedTypes', 'alias'].forEach(function(intertype) {
|
39
|
-
var temp = splitter(item.items, function(item) { return item.intertype == intertype });
|
40
|
-
item.items = temp.leftIn;
|
41
|
-
item[intertype + 's'] = temp.splitOut;
|
42
|
-
});
|
43
|
-
var temp = splitter(item.items, function(item) { return item.intertype == 'type' });
|
44
|
-
item.items = temp.leftIn;
|
45
|
-
temp.splitOut.forEach(function(type) {
|
46
|
-
//dprint('types', 'adding defined type: ' + type.name_);
|
47
|
-
Types.types[type.name_] = type;
|
48
|
-
newTypes[type.name_] = 1;
|
49
|
-
if (QUANTUM_SIZE === 1) {
|
50
|
-
Types.fatTypes[type.name_] = copy(type);
|
51
|
-
}
|
52
|
-
});
|
53
|
-
|
54
|
-
// Functions & labels
|
55
|
-
item.functions = [];
|
56
|
-
var currLabelFinished = false; // Sometimes LLVM puts a branch in the middle of a label. We need to ignore all lines after that.
|
57
|
-
item.items.sort(function(a, b) { return a.lineNum - b.lineNum });
|
58
|
-
for (var i = 0; i < item.items.length; i++) {
|
59
|
-
var subItem = item.items[i];
|
60
|
-
assert(subItem.lineNum);
|
61
|
-
if (subItem.intertype == 'function') {
|
62
|
-
item.functions.push(subItem);
|
63
|
-
subItem.endLineNum = null;
|
64
|
-
subItem.lines = []; // We will fill in the function lines after the legalizer, since it can modify them
|
65
|
-
subItem.labels = [];
|
66
|
-
subItem.forceEmulated = false;
|
67
|
-
|
68
|
-
// no explicit 'entry' label in clang on LLVM 2.8 - most of the time, but not all the time! - so we add one if necessary
|
69
|
-
if (item.items[i+1].intertype !== 'label') {
|
70
|
-
item.items.splice(i+1, 0, {
|
71
|
-
intertype: 'label',
|
72
|
-
ident: ENTRY_IDENT,
|
73
|
-
lineNum: subItem.lineNum + '.5'
|
74
|
-
});
|
75
|
-
}
|
76
|
-
} else if (subItem.intertype == 'functionEnd') {
|
77
|
-
item.functions.slice(-1)[0].endLineNum = subItem.lineNum;
|
78
|
-
} else if (subItem.intertype == 'label') {
|
79
|
-
item.functions.slice(-1)[0].labels.push(subItem);
|
80
|
-
subItem.lines = [];
|
81
|
-
currLabelFinished = false;
|
82
|
-
} else if (item.functions.length > 0 && item.functions.slice(-1)[0].endLineNum === null) {
|
83
|
-
// Internal line
|
84
|
-
if (!currLabelFinished) {
|
85
|
-
item.functions.slice(-1)[0].labels.slice(-1)[0].lines.push(subItem); // If this line fails, perhaps missing a label?
|
86
|
-
if (subItem.intertype in LABEL_ENDERS) {
|
87
|
-
currLabelFinished = true;
|
88
|
-
}
|
89
|
-
} else {
|
90
|
-
print('// WARNING: content after a branch in a label, line: ' + subItem.lineNum);
|
91
|
-
}
|
92
|
-
} else {
|
93
|
-
throw 'ERROR: what is this? ' + dump(subItem);
|
94
|
-
}
|
95
|
-
}
|
96
|
-
delete item.items;
|
97
|
-
|
98
|
-
// CastAway - try to remove bitcasts of double<-->i64, which LLVM sometimes generates unnecessarily
|
99
|
-
// (load a double, convert to i64, use as i64).
|
100
|
-
// We optimize this by checking if there are such bitcasts. If so we create a shadow
|
101
|
-
// variable that is of the other type, and use that in the relevant places. (As SSA, this is valid, and
|
102
|
-
// variable elimination later will remove the double load if it is no longer needed.)
|
103
|
-
//
|
104
|
-
// Note that aside from being an optimization, this is needed for correctness in some cases: If code
|
105
|
-
// assumes it can bitcast a double to an i64 and back and forth without loss, that may be violated
|
106
|
-
// due to NaN canonicalization.
|
107
|
-
function castAway() {
|
108
|
-
if (USE_TYPED_ARRAYS != 2) return;
|
109
|
-
|
110
|
-
item.functions.forEach(function(func) {
|
111
|
-
var has = false;
|
112
|
-
func.labels.forEach(function(label) {
|
113
|
-
var lines = label.lines;
|
114
|
-
for (var i = 0; i < lines.length; i++) {
|
115
|
-
var line = lines[i];
|
116
|
-
if (line.intertype == 'bitcast' && line.type in SHADOW_FLIP) {
|
117
|
-
has = true;
|
118
|
-
}
|
119
|
-
}
|
120
|
-
});
|
121
|
-
if (!has) return;
|
122
|
-
// there are integer<->floating-point bitcasts, create shadows for everything
|
123
|
-
var shadowed = {};
|
124
|
-
func.labels.forEach(function(label) {
|
125
|
-
var lines = label.lines;
|
126
|
-
var i = 0;
|
127
|
-
while (i < lines.length) {
|
128
|
-
var lines = label.lines;
|
129
|
-
var line = lines[i];
|
130
|
-
if (line.intertype == 'load' && line.type in SHADOW_FLIP) {
|
131
|
-
if (line.pointer.intertype != 'value') { i++; continue } // TODO
|
132
|
-
shadowed[line.assignTo] = 1;
|
133
|
-
var shadow = line.assignTo + '$$SHADOW';
|
134
|
-
var flip = SHADOW_FLIP[line.type];
|
135
|
-
lines.splice(i + 1, 0, { // if necessary this element will be legalized in the next phase
|
136
|
-
tokens: null,
|
137
|
-
indent: 2,
|
138
|
-
lineNum: line.lineNum + 0.5,
|
139
|
-
assignTo: shadow,
|
140
|
-
intertype: 'load',
|
141
|
-
pointerType: flip + '*',
|
142
|
-
type: flip,
|
143
|
-
valueType: flip,
|
144
|
-
pointer: {
|
145
|
-
intertype: 'value',
|
146
|
-
ident: line.pointer.ident,
|
147
|
-
type: flip + '*'
|
148
|
-
},
|
149
|
-
align: line.align,
|
150
|
-
ident: line.ident
|
151
|
-
});
|
152
|
-
// note: no need to update func.lines, it is generated in a later pass
|
153
|
-
i++;
|
154
|
-
}
|
155
|
-
i++;
|
156
|
-
}
|
157
|
-
});
|
158
|
-
// use shadows where possible
|
159
|
-
func.labels.forEach(function(label) {
|
160
|
-
var lines = label.lines;
|
161
|
-
for (var i = 0; i < lines.length; i++) {
|
162
|
-
var line = lines[i];
|
163
|
-
if (line.intertype == 'bitcast' && line.type in SHADOW_FLIP && line.ident in shadowed) {
|
164
|
-
var shadow = line.ident + '$$SHADOW';
|
165
|
-
line.params[0].ident = shadow;
|
166
|
-
line.params[0].type = line.type;
|
167
|
-
line.type2 = line.type;
|
168
|
-
}
|
169
|
-
}
|
170
|
-
});
|
171
|
-
});
|
172
|
-
}
|
173
|
-
|
174
|
-
// Legalize LLVM unrealistic types into realistic types.
|
175
|
-
//
|
176
|
-
// With full LLVM optimizations, it can generate types like i888 which do not exist in
|
177
|
-
// any actual hardware implementation, but are useful during optimization. LLVM then
|
178
|
-
// legalizes these types into real ones during code generation. Sadly, there is no LLVM
|
179
|
-
// IR pass to legalize them, which would have been useful and nice from a design perspective.
|
180
|
-
// The LLVM community is also not interested in receiving patches to implement that
|
181
|
-
// functionality, since it would duplicate existing code from the code generation
|
182
|
-
// component. Therefore, we implement legalization here in Emscripten.
|
183
|
-
//
|
184
|
-
// Currently we just legalize completely unrealistic types into bundles of i32s, and just
|
185
|
-
// the most common instructions that can be involved with such types: load, store, shifts,
|
186
|
-
// trunc and zext.
|
187
|
-
function legalizer() {
|
188
|
-
// Legalization
|
189
|
-
if (USE_TYPED_ARRAYS == 2) {
|
190
|
-
function getLegalVars(base, bits, allowLegal) {
|
191
|
-
bits = bits || 32; // things like pointers are all i32, but show up as 0 bits from getBits
|
192
|
-
if (allowLegal && bits <= 32) return [{ intertype: 'value', ident: base + ('i' + bits in Runtime.INT_TYPES ? '' : '$0'), bits: bits, type: 'i' + bits }];
|
193
|
-
if (isNumber(base)) return getLegalLiterals(base, bits);
|
194
|
-
if (base[0] == '{') {
|
195
|
-
warnOnce('seeing source of illegal data ' + base + ', likely an inline struct - assuming zeroinit');
|
196
|
-
return getLegalLiterals('0', bits);
|
197
|
-
}
|
198
|
-
var ret = new Array(Math.ceil(bits/32));
|
199
|
-
var i = 0;
|
200
|
-
if (base == 'zeroinitializer' || base == 'undef') base = 0;
|
201
|
-
while (bits > 0) {
|
202
|
-
ret[i] = { intertype: 'value', ident: base ? base + '$' + i : '0', bits: Math.min(32, bits), type: 'i' + Math.min(32, bits) };
|
203
|
-
bits -= 32;
|
204
|
-
i++;
|
205
|
-
}
|
206
|
-
return ret;
|
207
|
-
}
|
208
|
-
function getLegalLiterals(text, bits) {
|
209
|
-
var parsed = parseArbitraryInt(text, bits);
|
210
|
-
var ret = new Array(Math.ceil(bits/32));
|
211
|
-
var i = 0;
|
212
|
-
while (bits > 0) {
|
213
|
-
ret[i] = { intertype: 'value', ident: (parsed[i]|0).toString(), bits: Math.min(32, bits), type: 'i' + Math.min(32, bits) }; // resign all values
|
214
|
-
bits -= 32;
|
215
|
-
i++;
|
216
|
-
}
|
217
|
-
return ret;
|
218
|
-
}
|
219
|
-
function getLegalStructuralParts(value) {
|
220
|
-
return value.params.slice(0);
|
221
|
-
}
|
222
|
-
function getLegalParams(params, bits) {
|
223
|
-
return params.map(function(param) {
|
224
|
-
var value = param.value || param;
|
225
|
-
if (isNumber(value.ident)) {
|
226
|
-
return getLegalLiterals(value.ident, bits);
|
227
|
-
} else if (value.intertype == 'structvalue') {
|
228
|
-
return getLegalStructuralParts(value).map(function(part) {
|
229
|
-
part.bits = part.type.substr(1); // can be some nested IR, like LLVM calls
|
230
|
-
return part;
|
231
|
-
});
|
232
|
-
} else {
|
233
|
-
return getLegalVars(value.ident, bits);
|
234
|
-
}
|
235
|
-
});
|
236
|
-
}
|
237
|
-
// Uses the right factor to multiply line numbers by so that they fit in between
|
238
|
-
// the line[i] and the line after it
|
239
|
-
function interpLines(lines, i, toAdd) {
|
240
|
-
var prev = i >= 0 ? lines[i].lineNum : -1;
|
241
|
-
var next = (i < lines.length-1) ? lines[i+1].lineNum : (lines[i].lineNum + 0.5);
|
242
|
-
var factor = (next - prev)/(4*toAdd.length+3);
|
243
|
-
for (var k = 0; k < toAdd.length; k++) {
|
244
|
-
toAdd[k].lineNum = prev + ((k+1)*factor);
|
245
|
-
assert(k == 0 || toAdd[k].lineNum > toAdd[k-1].lineNum);
|
246
|
-
}
|
247
|
-
}
|
248
|
-
function removeAndAdd(lines, i, toAdd) {
|
249
|
-
var item = lines[i];
|
250
|
-
interpLines(lines, i, toAdd);
|
251
|
-
Array.prototype.splice.apply(lines, [i, 1].concat(toAdd));
|
252
|
-
if (i > 0) assert(lines[i].lineNum > lines[i-1].lineNum);
|
253
|
-
if (i + toAdd.length < lines.length) assert(lines[i + toAdd.length - 1].lineNum < lines[i + toAdd.length].lineNum);
|
254
|
-
return toAdd.length;
|
255
|
-
}
|
256
|
-
function legalizeFunctionParameters(params) {
|
257
|
-
var i = 0;
|
258
|
-
while (i < params.length) {
|
259
|
-
var param = params[i];
|
260
|
-
if (param.intertype == 'value' && isIllegalType(param.type)) {
|
261
|
-
var toAdd = getLegalVars(param.ident, getBits(param.type)).map(function(element) {
|
262
|
-
return {
|
263
|
-
intertype: 'value',
|
264
|
-
type: 'i' + element.bits,
|
265
|
-
ident: element.ident,
|
266
|
-
byval: 0
|
267
|
-
};
|
268
|
-
});
|
269
|
-
Array.prototype.splice.apply(params, [i, 1].concat(toAdd));
|
270
|
-
i += toAdd.length;
|
271
|
-
continue;
|
272
|
-
} else if (param.intertype == 'structvalue') {
|
273
|
-
// 'flatten' out the struct into scalars
|
274
|
-
var toAdd = param.params;
|
275
|
-
toAdd.forEach(function(param) {
|
276
|
-
param.byval = 0;
|
277
|
-
});
|
278
|
-
Array.prototype.splice.apply(params, [i, 1].concat(toAdd));
|
279
|
-
continue; // do not increment i; proceed to process the new params
|
280
|
-
}
|
281
|
-
i++;
|
282
|
-
}
|
283
|
-
}
|
284
|
-
function fixUnfolded(item) {
|
285
|
-
// Unfolded items may need some correction to work properly in the global scope
|
286
|
-
if (item.intertype in MATHOPS) {
|
287
|
-
item.op = item.intertype;
|
288
|
-
item.intertype = 'mathop';
|
289
|
-
}
|
290
|
-
}
|
291
|
-
data.functions.forEach(function(func) {
|
292
|
-
// Legalize function params
|
293
|
-
legalizeFunctionParameters(func.params);
|
294
|
-
// Legalize lines in labels
|
295
|
-
var tempId = 0;
|
296
|
-
func.labels.forEach(function(label) {
|
297
|
-
if (dcheck('legalizer')) dprint('zz legalizing: \n' + dump(label.lines));
|
298
|
-
var i = 0, bits;
|
299
|
-
while (i < label.lines.length) {
|
300
|
-
var item = label.lines[i];
|
301
|
-
var value = item;
|
302
|
-
// Check if we need to legalize here, and do some trivial legalization along the way
|
303
|
-
var isIllegal = false;
|
304
|
-
walkInterdata(item, function(item) {
|
305
|
-
if (item.intertype == 'getelementptr' || (item.intertype == 'call' && item.ident in LLVM.INTRINSICS_32)) {
|
306
|
-
// Turn i64 args into i32
|
307
|
-
for (var i = 0; i < item.params.length; i++) {
|
308
|
-
if (item.params[i].type == 'i64') item.params[i].type = 'i32';
|
309
|
-
}
|
310
|
-
} else if (item.intertype == 'inttoptr') {
|
311
|
-
var input = item.params[0];
|
312
|
-
if (input.type == 'i64') input.type = 'i32'; // inttoptr can only care about 32 bits anyhow since pointers are 32-bit
|
313
|
-
}
|
314
|
-
if (isIllegalType(item.valueType) || isIllegalType(item.type)) {
|
315
|
-
isIllegal = true;
|
316
|
-
} else if ((item.intertype == 'load' || item.intertype == 'store') && isStructType(item.valueType)) {
|
317
|
-
isIllegal = true; // storing an entire structure is illegal
|
318
|
-
} else if (item.intertype == 'mathop' && item.op == 'trunc' && isIllegalType(item.params[1].ident)) { // trunc stores target value in second ident
|
319
|
-
isIllegal = true;
|
320
|
-
}
|
321
|
-
});
|
322
|
-
if (!isIllegal) {
|
323
|
-
//if (dcheck('legalizer')) dprint('no need to legalize \n' + dump(item));
|
324
|
-
i++;
|
325
|
-
continue;
|
326
|
-
}
|
327
|
-
// Unfold this line. If we unfolded, we need to return and process the lines we just
|
328
|
-
// generated - they may need legalization too
|
329
|
-
var unfolded = [];
|
330
|
-
walkAndModifyInterdata(item, function(subItem) {
|
331
|
-
// Unfold all non-value interitems that we can, and also unfold all numbers (doing the latter
|
332
|
-
// makes it easier later since we can then assume illegal expressions are always variables
|
333
|
-
// accessible through ident$x, and not constants we need to parse then and there)
|
334
|
-
if (subItem != item && (!(subItem.intertype in UNUNFOLDABLE) ||
|
335
|
-
(subItem.intertype == 'value' && isNumber(subItem.ident) && isIllegalType(subItem.type)))) {
|
336
|
-
if (item.intertype == 'phi') {
|
337
|
-
assert(subItem.intertype == 'value' || subItem.intertype == 'structvalue' || subItem.intertype in PARSABLE_LLVM_FUNCTIONS, 'We can only unfold some expressions in phis');
|
338
|
-
// we must handle this in the phi itself, if we unfold normally it will not be pushed back with the phi
|
339
|
-
} else {
|
340
|
-
var tempIdent = '$$etemp$' + (tempId++);
|
341
|
-
subItem.assignTo = tempIdent;
|
342
|
-
unfolded.unshift(subItem);
|
343
|
-
fixUnfolded(subItem);
|
344
|
-
return { intertype: 'value', ident: tempIdent, type: subItem.type };
|
345
|
-
}
|
346
|
-
} else if (subItem.intertype == 'switch' && isIllegalType(subItem.type)) {
|
347
|
-
subItem.switchLabels.forEach(function(switchLabel) {
|
348
|
-
if (switchLabel.value[0] != '$') {
|
349
|
-
var tempIdent = '$$etemp$' + (tempId++);
|
350
|
-
unfolded.unshift({
|
351
|
-
assignTo: tempIdent,
|
352
|
-
intertype: 'value',
|
353
|
-
ident: switchLabel.value,
|
354
|
-
type: subItem.type
|
355
|
-
});
|
356
|
-
switchLabel.value = tempIdent;
|
357
|
-
}
|
358
|
-
});
|
359
|
-
}
|
360
|
-
});
|
361
|
-
if (unfolded.length > 0) {
|
362
|
-
interpLines(label.lines, i-1, unfolded);
|
363
|
-
Array.prototype.splice.apply(label.lines, [i, 0].concat(unfolded));
|
364
|
-
continue; // remain at this index, to unfold newly generated lines
|
365
|
-
}
|
366
|
-
// This is an illegal-containing line, and it is unfolded. Legalize it now
|
367
|
-
dprint('legalizer', 'Legalizing ' + item.intertype + ' at line ' + item.lineNum);
|
368
|
-
var finalizer = null;
|
369
|
-
switch (item.intertype) {
|
370
|
-
case 'store': {
|
371
|
-
var toAdd = [];
|
372
|
-
bits = getBits(item.valueType);
|
373
|
-
var elements = getLegalParams([item.value], bits)[0];
|
374
|
-
var j = 0;
|
375
|
-
elements.forEach(function(element) {
|
376
|
-
var tempVar = '$st$' + (tempId++) + '$' + j;
|
377
|
-
toAdd.push({
|
378
|
-
intertype: 'getelementptr',
|
379
|
-
assignTo: tempVar,
|
380
|
-
ident: item.pointer.ident,
|
381
|
-
type: '[0 x i32]*',
|
382
|
-
params: [
|
383
|
-
{ intertype: 'value', ident: item.pointer.ident, type: '[0 x i32]*' }, // technically a bitcase is needed in llvm, but not for us
|
384
|
-
{ intertype: 'value', ident: '0', type: 'i32' },
|
385
|
-
{ intertype: 'value', ident: j.toString(), type: 'i32' }
|
386
|
-
],
|
387
|
-
});
|
388
|
-
var actualSizeType = 'i' + element.bits; // The last one may be smaller than 32 bits
|
389
|
-
toAdd.push({
|
390
|
-
intertype: 'store',
|
391
|
-
valueType: actualSizeType,
|
392
|
-
value: { intertype: 'value', ident: element.ident, type: actualSizeType },
|
393
|
-
pointer: { intertype: 'value', ident: tempVar, type: actualSizeType + '*' },
|
394
|
-
ident: tempVar,
|
395
|
-
pointerType: actualSizeType + '*',
|
396
|
-
align: item.align,
|
397
|
-
});
|
398
|
-
j++;
|
399
|
-
});
|
400
|
-
Types.needAnalysis['[0 x i32]'] = 0;
|
401
|
-
i += removeAndAdd(label.lines, i, toAdd);
|
402
|
-
continue;
|
403
|
-
}
|
404
|
-
// call, return: Return the first 32 bits, the rest are in temp
|
405
|
-
case 'call': {
|
406
|
-
var toAdd = [value];
|
407
|
-
// legalize parameters
|
408
|
-
legalizeFunctionParameters(value.params);
|
409
|
-
// legalize return value, if any
|
410
|
-
var returnType = getReturnType(item.type);
|
411
|
-
if (value.assignTo && isIllegalType(returnType)) {
|
412
|
-
bits = getBits(returnType);
|
413
|
-
var elements = getLegalVars(item.assignTo, bits);
|
414
|
-
// legalize return value
|
415
|
-
value.assignTo = elements[0].ident;
|
416
|
-
for (var j = 1; j < elements.length; j++) {
|
417
|
-
var element = elements[j];
|
418
|
-
toAdd.push({
|
419
|
-
intertype: 'value',
|
420
|
-
assignTo: element.ident,
|
421
|
-
type: 'i' + element.bits,
|
422
|
-
ident: 'tempRet' + (j - 1)
|
423
|
-
});
|
424
|
-
assert(j<10); // TODO: dynamically create more than 10 tempRet-s
|
425
|
-
}
|
426
|
-
}
|
427
|
-
i += removeAndAdd(label.lines, i, toAdd);
|
428
|
-
continue;
|
429
|
-
}
|
430
|
-
case 'landingpad': {
|
431
|
-
// not much to legalize
|
432
|
-
i++;
|
433
|
-
continue;
|
434
|
-
}
|
435
|
-
case 'return': {
|
436
|
-
bits = getBits(item.type);
|
437
|
-
var elements = getLegalVars(item.value.ident, bits);
|
438
|
-
item.value.ident = '(';
|
439
|
-
for (var j = 1; j < elements.length; j++) {
|
440
|
-
item.value.ident += 'tempRet' + (j-1) + '=' + elements[j].ident + ',';
|
441
|
-
}
|
442
|
-
item.value.ident += elements[0].ident + ')';
|
443
|
-
i++;
|
444
|
-
continue;
|
445
|
-
}
|
446
|
-
case 'invoke': {
|
447
|
-
legalizeFunctionParameters(value.params);
|
448
|
-
// We can't add lines after this, since invoke already modifies control flow. So we handle the return in invoke
|
449
|
-
i++;
|
450
|
-
continue;
|
451
|
-
}
|
452
|
-
case 'value': {
|
453
|
-
bits = getBits(value.type);
|
454
|
-
var elements = getLegalVars(item.assignTo, bits);
|
455
|
-
var values = getLegalLiterals(item.ident, bits);
|
456
|
-
var j = 0;
|
457
|
-
var toAdd = elements.map(function(element) {
|
458
|
-
return {
|
459
|
-
intertype: 'value',
|
460
|
-
assignTo: element.ident,
|
461
|
-
type: 'i' + bits,
|
462
|
-
ident: values[j++].ident
|
463
|
-
};
|
464
|
-
});
|
465
|
-
i += removeAndAdd(label.lines, i, toAdd);
|
466
|
-
continue;
|
467
|
-
}
|
468
|
-
case 'structvalue': {
|
469
|
-
bits = getBits(value.type);
|
470
|
-
var elements = getLegalVars(item.assignTo, bits);
|
471
|
-
var toAdd = [];
|
472
|
-
for (var j = 0; j < item.params.length; j++) {
|
473
|
-
toAdd[j] = {
|
474
|
-
intertype: 'value',
|
475
|
-
assignTo: elements[j].ident,
|
476
|
-
type: 'i32',
|
477
|
-
ident: item.params[j].ident
|
478
|
-
};
|
479
|
-
}
|
480
|
-
i += removeAndAdd(label.lines, i, toAdd);
|
481
|
-
continue;
|
482
|
-
}
|
483
|
-
case 'load': {
|
484
|
-
bits = getBits(value.valueType);
|
485
|
-
var elements = getLegalVars(item.assignTo, bits);
|
486
|
-
var j = 0;
|
487
|
-
var toAdd = [];
|
488
|
-
elements.forEach(function(element) {
|
489
|
-
var tempVar = '$ld$' + (tempId++) + '$' + j;
|
490
|
-
toAdd.push({
|
491
|
-
intertype: 'getelementptr',
|
492
|
-
assignTo: tempVar,
|
493
|
-
ident: value.pointer.ident,
|
494
|
-
type: '[0 x i32]*',
|
495
|
-
params: [
|
496
|
-
{ intertype: 'value', ident: value.pointer.ident, type: '[0 x i32]*' }, // technically bitcast is needed in llvm, but not for us
|
497
|
-
{ intertype: 'value', ident: '0', type: 'i32' },
|
498
|
-
{ intertype: 'value', ident: j.toString(), type: 'i32' }
|
499
|
-
]
|
500
|
-
});
|
501
|
-
var newItem = {
|
502
|
-
intertype: 'load',
|
503
|
-
assignTo: element.ident,
|
504
|
-
pointerType: 'i32*',
|
505
|
-
valueType: 'i32',
|
506
|
-
type: 'i32',
|
507
|
-
pointer: { intertype: 'value', ident: tempVar, type: 'i32*' },
|
508
|
-
ident: tempVar,
|
509
|
-
align: value.align
|
510
|
-
};
|
511
|
-
var newItem2 = null;
|
512
|
-
// The last one may be smaller than 32 bits
|
513
|
-
if (element.bits < 32) {
|
514
|
-
newItem.assignTo += '$preadd$';
|
515
|
-
newItem2 = {
|
516
|
-
intertype: 'mathop',
|
517
|
-
op: 'and',
|
518
|
-
assignTo: element.ident,
|
519
|
-
type: 'i32',
|
520
|
-
params: [{
|
521
|
-
intertype: 'value',
|
522
|
-
type: 'i32',
|
523
|
-
ident: newItem.assignTo
|
524
|
-
}, {
|
525
|
-
intertype: 'value',
|
526
|
-
type: 'i32',
|
527
|
-
ident: (0xffffffff >>> (32 - element.bits)).toString()
|
528
|
-
}],
|
529
|
-
};
|
530
|
-
}
|
531
|
-
toAdd.push(newItem);
|
532
|
-
if (newItem2) toAdd.push(newItem2);
|
533
|
-
j++;
|
534
|
-
});
|
535
|
-
Types.needAnalysis['[0 x i32]'] = 0;
|
536
|
-
i += removeAndAdd(label.lines, i, toAdd);
|
537
|
-
continue;
|
538
|
-
}
|
539
|
-
case 'phi': {
|
540
|
-
bits = getBits(value.type);
|
541
|
-
var toAdd = [];
|
542
|
-
var elements = getLegalVars(item.assignTo, bits);
|
543
|
-
var j = 0;
|
544
|
-
var values = getLegalParams(value.params, bits);
|
545
|
-
elements.forEach(function(element) {
|
546
|
-
var k = 0;
|
547
|
-
toAdd.push({
|
548
|
-
intertype: 'phi',
|
549
|
-
assignTo: element.ident,
|
550
|
-
type: 'i' + element.bits,
|
551
|
-
params: value.params.map(function(param) {
|
552
|
-
return {
|
553
|
-
intertype: 'phiparam',
|
554
|
-
label: param.label,
|
555
|
-
value: values[k++][j]
|
556
|
-
};
|
557
|
-
})
|
558
|
-
});
|
559
|
-
j++;
|
560
|
-
});
|
561
|
-
i += removeAndAdd(label.lines, i, toAdd);
|
562
|
-
continue;
|
563
|
-
}
|
564
|
-
case 'switch': {
|
565
|
-
i++;
|
566
|
-
continue; // special case, handled in makeComparison
|
567
|
-
}
|
568
|
-
case 'va_arg': {
|
569
|
-
assert(value.type == 'i64');
|
570
|
-
assert(value.value.type == 'i32*', value.value.type);
|
571
|
-
i += removeAndAdd(label.lines, i, range(2).map(function(x) {
|
572
|
-
return {
|
573
|
-
intertype: 'va_arg',
|
574
|
-
assignTo: value.assignTo + '$' + x,
|
575
|
-
type: 'i32',
|
576
|
-
value: {
|
577
|
-
intertype: 'value',
|
578
|
-
ident: value.value.ident, // We read twice from the same i32* var, incrementing // + '$' + x,
|
579
|
-
type: 'i32*'
|
580
|
-
}
|
581
|
-
};
|
582
|
-
}));
|
583
|
-
continue;
|
584
|
-
}
|
585
|
-
case 'extractvalue': { // XXX we assume 32-bit alignment in extractvalue/insertvalue,
|
586
|
-
// but in theory they can run on packed structs too (see use getStructuralTypePartBits)
|
587
|
-
// potentially legalize the actual extracted value too if it is >32 bits, not just the extraction in general
|
588
|
-
var index = item.indexes[0][0].text;
|
589
|
-
var parts = getStructureTypeParts(item.type);
|
590
|
-
var indexedType = parts[index];
|
591
|
-
var targetBits = getBits(indexedType);
|
592
|
-
var sourceBits = getBits(item.type);
|
593
|
-
var elements = getLegalVars(item.assignTo, targetBits, true); // possibly illegal
|
594
|
-
var sourceElements = getLegalVars(item.ident, sourceBits); // definitely illegal
|
595
|
-
var toAdd = [];
|
596
|
-
var sourceIndex = 0;
|
597
|
-
for (var partIndex = 0; partIndex < parts.length; partIndex++) {
|
598
|
-
if (partIndex == index) {
|
599
|
-
for (var j = 0; j < elements.length; j++) {
|
600
|
-
toAdd.push({
|
601
|
-
intertype: 'value',
|
602
|
-
assignTo: elements[j].ident,
|
603
|
-
type: 'i' + elements[j].bits,
|
604
|
-
ident: sourceElements[sourceIndex+j].ident
|
605
|
-
});
|
606
|
-
}
|
607
|
-
break;
|
608
|
-
}
|
609
|
-
sourceIndex += getStructuralTypePartBits(parts[partIndex])/32;
|
610
|
-
}
|
611
|
-
i += removeAndAdd(label.lines, i, toAdd);
|
612
|
-
continue;
|
613
|
-
}
|
614
|
-
case 'insertvalue': {
|
615
|
-
var index = item.indexes[0][0].text; // the modified index
|
616
|
-
var parts = getStructureTypeParts(item.type);
|
617
|
-
var indexedType = parts[index];
|
618
|
-
var indexBits = getBits(indexedType);
|
619
|
-
var bits = getBits(item.type); // source and target
|
620
|
-
bits = getBits(value.type);
|
621
|
-
var toAdd = [];
|
622
|
-
var elements = getLegalVars(item.assignTo, bits);
|
623
|
-
var sourceElements = getLegalVars(item.ident, bits);
|
624
|
-
var indexElements = getLegalVars(item.value.ident, indexBits, true); // possibly legal
|
625
|
-
var sourceIndex = 0;
|
626
|
-
for (var partIndex = 0; partIndex < parts.length; partIndex++) {
|
627
|
-
var currNum = getStructuralTypePartBits(parts[partIndex])/32;
|
628
|
-
for (var j = 0; j < currNum; j++) {
|
629
|
-
toAdd.push({
|
630
|
-
intertype: 'value',
|
631
|
-
assignTo: elements[sourceIndex+j].ident,
|
632
|
-
type: 'i' + elements[sourceIndex+j].bits,
|
633
|
-
ident: partIndex == index ? indexElements[j].ident : sourceElements[sourceIndex+j].ident
|
634
|
-
});
|
635
|
-
}
|
636
|
-
sourceIndex += currNum;
|
637
|
-
}
|
638
|
-
i += removeAndAdd(label.lines, i, toAdd);
|
639
|
-
continue;
|
640
|
-
}
|
641
|
-
case 'bitcast': {
|
642
|
-
var inType = item.type2;
|
643
|
-
var outType = item.type;
|
644
|
-
if ((inType in Runtime.INT_TYPES && outType in Runtime.FLOAT_TYPES) ||
|
645
|
-
(inType in Runtime.FLOAT_TYPES && outType in Runtime.INT_TYPES)) {
|
646
|
-
i++;
|
647
|
-
continue; // special case, handled in processMathop
|
648
|
-
}
|
649
|
-
// fall through
|
650
|
-
}
|
651
|
-
case 'inttoptr': case 'ptrtoint': case 'zext': case 'sext': case 'trunc': case 'ashr': case 'lshr': case 'shl': case 'or': case 'and': case 'xor': {
|
652
|
-
value = {
|
653
|
-
op: item.intertype,
|
654
|
-
variant: item.variant,
|
655
|
-
type: item.type,
|
656
|
-
params: item.params
|
657
|
-
};
|
658
|
-
// fall through
|
659
|
-
}
|
660
|
-
case 'mathop': {
|
661
|
-
var toAdd = [];
|
662
|
-
var sourceBits = getBits(value.params[0].type);
|
663
|
-
// All mathops can be parametrized by how many shifts we do, and how big the source is
|
664
|
-
var shifts = 0;
|
665
|
-
var targetBits = sourceBits;
|
666
|
-
var processor = null;
|
667
|
-
var signed = false;
|
668
|
-
switch (value.op) {
|
669
|
-
case 'ashr': {
|
670
|
-
signed = true;
|
671
|
-
// fall through
|
672
|
-
}
|
673
|
-
case 'lshr': {
|
674
|
-
shifts = parseInt(value.params[1].ident);
|
675
|
-
break;
|
676
|
-
}
|
677
|
-
case 'shl': {
|
678
|
-
shifts = -parseInt(value.params[1].ident);
|
679
|
-
break;
|
680
|
-
}
|
681
|
-
case 'sext': {
|
682
|
-
signed = true;
|
683
|
-
// fall through
|
684
|
-
}
|
685
|
-
case 'trunc': case 'zext': case 'ptrtoint': {
|
686
|
-
targetBits = getBits(value.params[1] ? value.params[1].ident : value.type);
|
687
|
-
break;
|
688
|
-
}
|
689
|
-
case 'inttoptr': {
|
690
|
-
targetBits = 32;
|
691
|
-
break;
|
692
|
-
}
|
693
|
-
case 'bitcast': {
|
694
|
-
if (!sourceBits) {
|
695
|
-
// we can be asked to bitcast doubles or such to integers, handle that as best we can (if it's a double that
|
696
|
-
// was an x86_fp80, this code will likely break when called)
|
697
|
-
sourceBits = targetBits = Runtime.getNativeTypeSize(value.params[0].type);
|
698
|
-
warn('legalizing non-integer bitcast on ll #' + item.lineNum);
|
699
|
-
}
|
700
|
-
break;
|
701
|
-
}
|
702
|
-
case 'select': {
|
703
|
-
sourceBits = targetBits = getBits(value.params[1].type);
|
704
|
-
var params = getLegalParams(value.params.slice(1), sourceBits);
|
705
|
-
processor = function(result, j) {
|
706
|
-
return {
|
707
|
-
intertype: 'mathop',
|
708
|
-
op: 'select',
|
709
|
-
type: 'i' + params[0][j].bits,
|
710
|
-
params: [
|
711
|
-
value.params[0],
|
712
|
-
{ intertype: 'value', ident: params[0][j].ident, type: 'i' + params[0][j].bits },
|
713
|
-
{ intertype: 'value', ident: params[1][j].ident, type: 'i' + params[1][j].bits }
|
714
|
-
]
|
715
|
-
};
|
716
|
-
};
|
717
|
-
break;
|
718
|
-
}
|
719
|
-
case 'or': case 'and': case 'xor': case 'icmp': {
|
720
|
-
var otherElements = getLegalVars(value.params[1].ident, sourceBits);
|
721
|
-
processor = function(result, j) {
|
722
|
-
return {
|
723
|
-
intertype: 'mathop',
|
724
|
-
op: value.op,
|
725
|
-
variant: value.variant,
|
726
|
-
type: 'i' + otherElements[j].bits,
|
727
|
-
params: [
|
728
|
-
result,
|
729
|
-
{ intertype: 'value', ident: otherElements[j].ident, type: 'i' + otherElements[j].bits }
|
730
|
-
]
|
731
|
-
};
|
732
|
-
};
|
733
|
-
if (value.op == 'icmp') {
|
734
|
-
if (sourceBits == 64) { // handle the i64 case in processMathOp, where we handle full i64 math
|
735
|
-
i++;
|
736
|
-
continue;
|
737
|
-
}
|
738
|
-
finalizer = function() {
|
739
|
-
var ident = '';
|
740
|
-
for (var i = 0; i < targetElements.length; i++) {
|
741
|
-
if (i > 0) {
|
742
|
-
switch(value.variant) {
|
743
|
-
case 'eq': ident += '&'; break;
|
744
|
-
case 'ne': ident += '|'; break;
|
745
|
-
default: throw 'unhandleable illegal icmp: ' + value.variant;
|
746
|
-
}
|
747
|
-
}
|
748
|
-
ident += targetElements[i].ident;
|
749
|
-
}
|
750
|
-
return {
|
751
|
-
intertype: 'value',
|
752
|
-
ident: ident,
|
753
|
-
type: 'rawJS',
|
754
|
-
assignTo: item.assignTo
|
755
|
-
};
|
756
|
-
}
|
757
|
-
}
|
758
|
-
break;
|
759
|
-
}
|
760
|
-
case 'add': case 'sub': case 'sdiv': case 'udiv': case 'mul': case 'urem': case 'srem': {
|
761
|
-
if (sourceBits < 32) {
|
762
|
-
// when we add illegal types like i24, we must work on the singleton chunks
|
763
|
-
item.assignTo += '$0';
|
764
|
-
item.params[0].ident += '$0';
|
765
|
-
item.params[1].ident += '$0';
|
766
|
-
}
|
767
|
-
// fall through
|
768
|
-
}
|
769
|
-
case 'uitofp': case 'sitofp': case 'fptosi': case 'fptoui': {
|
770
|
-
// We cannot do these in parallel chunks of 32-bit operations. We will handle these in processMathop
|
771
|
-
i++;
|
772
|
-
continue;
|
773
|
-
}
|
774
|
-
default: throw 'Invalid mathop for legalization: ' + [value.op, item.lineNum, dump(item)];
|
775
|
-
}
|
776
|
-
// Do the legalization
|
777
|
-
var sourceElements = getLegalVars(value.params[0].ident, sourceBits, true);
|
778
|
-
if (!isNumber(shifts)) {
|
779
|
-
// We can't statically legalize this, do the operation at runtime TODO: optimize
|
780
|
-
assert(sourceBits == 64, 'TODO: handle nonconstant shifts on != 64 bits');
|
781
|
-
assert(PRECISE_I64_MATH, 'Must have precise i64 math for non-constant 64-bit shifts');
|
782
|
-
Types.preciseI64MathUsed = 1;
|
783
|
-
value.intertype = 'value';
|
784
|
-
value.ident = makeVarDef(value.assignTo) + '$0=' +
|
785
|
-
asmCoercion('_bitshift64' + value.op[0].toUpperCase() + value.op.substr(1) + '(' +
|
786
|
-
asmCoercion(sourceElements[0].ident, 'i32') + ',' +
|
787
|
-
asmCoercion(sourceElements[1].ident, 'i32') + ',' +
|
788
|
-
asmCoercion(value.params[1].ident + '$0', 'i32') + ')', 'i32'
|
789
|
-
) + ';' +
|
790
|
-
makeVarDef(value.assignTo) + '$1=tempRet0;';
|
791
|
-
value.vars = [[value.assignTo + '$0', 'i32'], [value.assignTo + '$1', 'i32']];
|
792
|
-
value.assignTo = null;
|
793
|
-
i++;
|
794
|
-
continue;
|
795
|
-
}
|
796
|
-
var targetElements = getLegalVars(item.assignTo, targetBits);
|
797
|
-
var sign = shifts >= 0 ? 1 : -1;
|
798
|
-
var shiftOp = shifts >= 0 ? 'shl' : 'lshr';
|
799
|
-
var shiftOpReverse = shifts >= 0 ? 'lshr' : 'shl';
|
800
|
-
var whole = shifts >= 0 ? Math.floor(shifts/32) : Math.ceil(shifts/32);
|
801
|
-
var fraction = Math.abs(shifts % 32);
|
802
|
-
if (signed) {
|
803
|
-
var signedFill = {
|
804
|
-
intertype: 'mathop',
|
805
|
-
op: 'select',
|
806
|
-
variant: 's',
|
807
|
-
type: 'i32',
|
808
|
-
params: [{
|
809
|
-
intertype: 'mathop',
|
810
|
-
op: 'icmp',
|
811
|
-
variant: 'slt',
|
812
|
-
type: 'i32',
|
813
|
-
params: [
|
814
|
-
{ intertype: 'value', ident: sourceElements[sourceElements.length-1].ident, type: 'i' + Math.min(sourceBits, 32) },
|
815
|
-
{ intertype: 'value', ident: '0', type: 'i32' }
|
816
|
-
]
|
817
|
-
},
|
818
|
-
{ intertype: 'value', ident: '-1', type: 'i32' },
|
819
|
-
{ intertype: 'value', ident: '0', type: 'i32' },
|
820
|
-
]
|
821
|
-
};
|
822
|
-
}
|
823
|
-
for (var j = 0; j < targetElements.length; j++) {
|
824
|
-
var inBounds = j + whole >= 0 && j + whole < sourceElements.length;
|
825
|
-
var result;
|
826
|
-
if (inBounds || !signed) {
|
827
|
-
result = {
|
828
|
-
intertype: 'value',
|
829
|
-
ident: inBounds ? sourceElements[j + whole].ident : '0',
|
830
|
-
type: 'i' + Math.min(sourceBits, 32),
|
831
|
-
};
|
832
|
-
if (j == 0 && sourceBits < 32) {
|
833
|
-
// zext sign correction
|
834
|
-
var result2 = {
|
835
|
-
intertype: 'mathop',
|
836
|
-
op: isUnsignedOp(value.op) ? 'zext' : 'sext',
|
837
|
-
params: [result, {
|
838
|
-
intertype: 'type',
|
839
|
-
ident: 'i32',
|
840
|
-
type: 'i' + sourceBits
|
841
|
-
}],
|
842
|
-
type: 'i32'
|
843
|
-
};
|
844
|
-
result = result2;
|
845
|
-
}
|
846
|
-
} else {
|
847
|
-
// out of bounds and signed
|
848
|
-
result = copy(signedFill);
|
849
|
-
}
|
850
|
-
if (fraction != 0) {
|
851
|
-
var other;
|
852
|
-
var otherInBounds = j + sign + whole >= 0 && j + sign + whole < sourceElements.length;
|
853
|
-
if (otherInBounds || !signed) {
|
854
|
-
other = {
|
855
|
-
intertype: 'value',
|
856
|
-
ident: otherInBounds ? sourceElements[j + sign + whole].ident : '0',
|
857
|
-
type: 'i32',
|
858
|
-
};
|
859
|
-
} else {
|
860
|
-
other = copy(signedFill);
|
861
|
-
}
|
862
|
-
other = {
|
863
|
-
intertype: 'mathop',
|
864
|
-
op: shiftOp,
|
865
|
-
type: 'i32',
|
866
|
-
params: [
|
867
|
-
other,
|
868
|
-
{ intertype: 'value', ident: (32 - fraction).toString(), type: 'i32' }
|
869
|
-
]
|
870
|
-
};
|
871
|
-
result = {
|
872
|
-
intertype: 'mathop',
|
873
|
-
// shifting in 1s from the top is a special case
|
874
|
-
op: (signed && shifts >= 0 && j + sign + whole >= sourceElements.length) ? 'ashr' : shiftOpReverse,
|
875
|
-
type: 'i32',
|
876
|
-
params: [
|
877
|
-
result,
|
878
|
-
{ intertype: 'value', ident: fraction.toString(), type: 'i32' }
|
879
|
-
]
|
880
|
-
};
|
881
|
-
result = {
|
882
|
-
intertype: 'mathop',
|
883
|
-
op: 'or',
|
884
|
-
type: 'i32',
|
885
|
-
params: [
|
886
|
-
result,
|
887
|
-
other
|
888
|
-
]
|
889
|
-
}
|
890
|
-
}
|
891
|
-
if (targetElements[j].bits < 32 && shifts < 0) {
|
892
|
-
// truncate bits that fall off the end. This is not needed in most cases, can probably be optimized out
|
893
|
-
result = {
|
894
|
-
intertype: 'mathop',
|
895
|
-
op: 'and',
|
896
|
-
type: 'i32',
|
897
|
-
params: [
|
898
|
-
result,
|
899
|
-
{ intertype: 'value', ident: (Math.pow(2, targetElements[j].bits)-1).toString(), type: 'i32' }
|
900
|
-
]
|
901
|
-
}
|
902
|
-
}
|
903
|
-
if (processor) {
|
904
|
-
result = processor(result, j);
|
905
|
-
}
|
906
|
-
result.assignTo = targetElements[j].ident;
|
907
|
-
toAdd.push(result);
|
908
|
-
}
|
909
|
-
if (targetBits <= 32) {
|
910
|
-
// We are generating a normal legal type here
|
911
|
-
legalValue = { intertype: 'value', ident: targetElements[0].ident, type: 'i32' };
|
912
|
-
if (targetBits < 32) {
|
913
|
-
legalValue = {
|
914
|
-
intertype: 'mathop',
|
915
|
-
op: 'and',
|
916
|
-
type: 'i32',
|
917
|
-
params: [
|
918
|
-
legalValue,
|
919
|
-
{ intertype: 'value', ident: (Math.pow(2, targetBits)-1).toString(), type: 'i32' }
|
920
|
-
]
|
921
|
-
}
|
922
|
-
};
|
923
|
-
legalValue.assignTo = item.assignTo;
|
924
|
-
toAdd.push(legalValue);
|
925
|
-
} else if (finalizer) {
|
926
|
-
toAdd.push(finalizer());
|
927
|
-
}
|
928
|
-
i += removeAndAdd(label.lines, i, toAdd);
|
929
|
-
continue;
|
930
|
-
}
|
931
|
-
}
|
932
|
-
assert(0, 'Could not legalize illegal line: ' + [item.lineNum, dump(item)]);
|
933
|
-
}
|
934
|
-
if (dcheck('legalizer')) dprint('zz legalized: \n' + dump(label.lines));
|
935
|
-
});
|
936
|
-
});
|
937
|
-
}
|
938
|
-
|
939
|
-
// Add function lines to func.lines, after our modifications to the label lines
|
940
|
-
data.functions.forEach(function(func) {
|
941
|
-
func.labels.forEach(function(label) {
|
942
|
-
func.lines = func.lines.concat(label.lines);
|
943
|
-
});
|
944
|
-
});
|
945
|
-
}
|
946
|
-
|
947
|
-
function addTypeInternal(type) {
|
948
|
-
if (type.length == 1) return;
|
949
|
-
if (Types.types[type]) return;
|
950
|
-
if (['internal', 'hidden', 'inbounds', 'void'].indexOf(type) != -1) return;
|
951
|
-
if (Runtime.isNumberType(type)) return;
|
952
|
-
dprint('types', 'Adding type: ' + type);
|
953
|
-
|
954
|
-
// 'blocks': [14 x %struct.X] etc. If this is a pointer, we need
|
955
|
-
// to look at the underlying type - it was not defined explicitly
|
956
|
-
// anywhere else.
|
957
|
-
var nonPointing = removeAllPointing(type);
|
958
|
-
if (Types.types[nonPointing]) return;
|
959
|
-
var check = /^\[(\d+)\ x\ (.*)\]$/.exec(nonPointing);
|
960
|
-
if (check) {
|
961
|
-
var num = parseInt(check[1]);
|
962
|
-
num = Math.max(num, 1); // [0 x something] is used not for allocations and such of course, but
|
963
|
-
// for indexing - for an |array of unknown length|, basically. So we
|
964
|
-
// define the 'type' as having a single field. TODO: Ensure as a sanity
|
965
|
-
// check that we never allocate with this (either as a child structure
|
966
|
-
// in the analyzer, or in calcSize in alloca).
|
967
|
-
var subType = check[2];
|
968
|
-
addTypeInternal(subType); // needed for anonymous structure definitions (see below)
|
969
|
-
|
970
|
-
var fields = [subType, subType]; // Two, so we get the flatFactor right. We care about the flatFactor, not the size here. see calculateStructAlignment
|
971
|
-
Types.types[nonPointing] = {
|
972
|
-
name_: nonPointing,
|
973
|
-
fields: fields,
|
974
|
-
lineNum: '?'
|
975
|
-
};
|
976
|
-
newTypes[nonPointing] = 1;
|
977
|
-
// Also add a |[0 x type]| type
|
978
|
-
var zerod = '[0 x ' + subType + ']';
|
979
|
-
if (!Types.types[zerod]) {
|
980
|
-
Types.types[zerod] = {
|
981
|
-
name_: zerod,
|
982
|
-
fields: fields,
|
983
|
-
lineNum: '?'
|
984
|
-
};
|
985
|
-
newTypes[zerod] = 1;
|
986
|
-
}
|
987
|
-
return;
|
988
|
-
}
|
989
|
-
|
990
|
-
// anonymous structure definition, for example |{ i32, i8*, void ()*, i32 }|
|
991
|
-
if (type[0] == '{' || type[0] == '<') {
|
992
|
-
type = nonPointing;
|
993
|
-
var packed = type[0] == '<';
|
994
|
-
var internal = type;
|
995
|
-
if (packed) {
|
996
|
-
if (type[1] !== '{') {
|
997
|
-
// vector type, <4 x float> etc.
|
998
|
-
var size = getVectorSize(type);
|
999
|
-
Types.types[type] = {
|
1000
|
-
name_: type,
|
1001
|
-
fields: zeros(size).map(function() {
|
1002
|
-
return getVectorNativeType(type);
|
1003
|
-
}),
|
1004
|
-
packed: false,
|
1005
|
-
flatSize: 4*size,
|
1006
|
-
lineNum: '?'
|
1007
|
-
};
|
1008
|
-
return;
|
1009
|
-
}
|
1010
|
-
if (internal[internal.length-1] != '>') {
|
1011
|
-
warnOnce('ignoring type ' + internal);
|
1012
|
-
return; // function pointer or such
|
1013
|
-
}
|
1014
|
-
internal = internal.substr(1, internal.length-2);
|
1015
|
-
}
|
1016
|
-
assert(internal[0] == '{', internal);
|
1017
|
-
if (internal[internal.length-1] != '}') {
|
1018
|
-
warnOnce('ignoring type ' + internal);
|
1019
|
-
return; // function pointer or such
|
1020
|
-
}
|
1021
|
-
internal = internal.substr(2, internal.length-4);
|
1022
|
-
Types.types[type] = {
|
1023
|
-
name_: type,
|
1024
|
-
fields: splitTokenList(tokenize(internal)).map(function(segment) {
|
1025
|
-
return segment[0].text;
|
1026
|
-
}),
|
1027
|
-
packed: packed,
|
1028
|
-
lineNum: '?'
|
1029
|
-
};
|
1030
|
-
newTypes[type] = 1;
|
1031
|
-
return;
|
1032
|
-
}
|
1033
|
-
|
1034
|
-
if (isPointerType(type)) return;
|
1035
|
-
if (['['].indexOf(type) != -1) return;
|
1036
|
-
Types.types[type] = {
|
1037
|
-
name_: type,
|
1038
|
-
fields: [ 'i' + (QUANTUM_SIZE*8) ], // a single quantum size
|
1039
|
-
flatSize: 1,
|
1040
|
-
lineNum: '?'
|
1041
|
-
};
|
1042
|
-
newTypes[type] = 1;
|
1043
|
-
}
|
1044
|
-
|
1045
|
-
function addType(type) {
|
1046
|
-
addTypeInternal(type);
|
1047
|
-
if (QUANTUM_SIZE === 1) {
|
1048
|
-
Types.flipTypes();
|
1049
|
-
addTypeInternal(type);
|
1050
|
-
Types.flipTypes();
|
1051
|
-
}
|
1052
|
-
}
|
1053
|
-
|
1054
|
-
// Typevestigator
|
1055
|
-
function typevestigator() {
|
1056
|
-
if (sidePass) { // Do not investigate in the main pass - it is only valid to start to do so in the first side pass,
|
1057
|
-
// which handles type definitions, and later. Doing so before the first side pass will result in
|
1058
|
-
// making bad guesses about types which are actually defined
|
1059
|
-
for (var type in Types.needAnalysis) {
|
1060
|
-
if (type) addType(type);
|
1061
|
-
}
|
1062
|
-
Types.needAnalysis = {};
|
1063
|
-
}
|
1064
|
-
}
|
1065
|
-
|
1066
|
-
// Type analyzer
|
1067
|
-
function analyzeTypes(fatTypes) {
|
1068
|
-
var types = Types.types;
|
1069
|
-
|
1070
|
-
// 'fields' is the raw list of LLVM fields. However, we embed
|
1071
|
-
// child structures into parent structures, basically like C.
|
1072
|
-
// So { int, { int, int }, int } would be represented as
|
1073
|
-
// an Array of 4 ints. getelementptr on the parent would take
|
1074
|
-
// values 0, 1, 2, where 2 is the entire middle structure.
|
1075
|
-
// We also need to be careful with getelementptr to child
|
1076
|
-
// structures - we return a pointer to the same slab, just
|
1077
|
-
// a different offset. Likewise, need to be careful for
|
1078
|
-
// getelementptr of 2 (the last int) - it's real index is 4.
|
1079
|
-
// The benefit of this approach is inheritance -
|
1080
|
-
// { { ancestor } , etc. } = descendant
|
1081
|
-
// In this case it is easy to bitcast ancestor to descendant
|
1082
|
-
// pointers - nothing needs to be done. If the ancestor were
|
1083
|
-
// a new slab, it would need some pointer to the outer one
|
1084
|
-
// for casting in that direction.
|
1085
|
-
// TODO: bitcasts of non-inheritance cases of embedding (not at start)
|
1086
|
-
var more = true;
|
1087
|
-
while (more) {
|
1088
|
-
more = false;
|
1089
|
-
for (var typeName in newTypes) {
|
1090
|
-
var type = types[typeName];
|
1091
|
-
if (type.flatIndexes) continue;
|
1092
|
-
var ready = true;
|
1093
|
-
type.fields.forEach(function(field) {
|
1094
|
-
if (isStructType(field)) {
|
1095
|
-
if (!types[field]) {
|
1096
|
-
addType(field);
|
1097
|
-
ready = false;
|
1098
|
-
} else {
|
1099
|
-
if (!types[field].flatIndexes) {
|
1100
|
-
newTypes[field] = 1;
|
1101
|
-
ready = false;
|
1102
|
-
}
|
1103
|
-
}
|
1104
|
-
}
|
1105
|
-
});
|
1106
|
-
if (!ready) {
|
1107
|
-
more = true;
|
1108
|
-
continue;
|
1109
|
-
}
|
1110
|
-
|
1111
|
-
Runtime.calculateStructAlignment(type);
|
1112
|
-
|
1113
|
-
if (dcheck('types')) dprint('type (fat=' + !!fatTypes + '): ' + type.name_ + ' : ' + JSON.stringify(type.fields));
|
1114
|
-
if (dcheck('types')) dprint(' has final size of ' + type.flatSize + ', flatting: ' + type.needsFlattening + ' ? ' + (type.flatFactor ? type.flatFactor : JSON.stringify(type.flatIndexes)));
|
1115
|
-
}
|
1116
|
-
}
|
1117
|
-
|
1118
|
-
if (QUANTUM_SIZE === 1 && !fatTypes) {
|
1119
|
-
Types.flipTypes();
|
1120
|
-
// Fake a quantum size of 4 for fat types. TODO: Might want non-4 for some reason?
|
1121
|
-
var trueQuantumSize = QUANTUM_SIZE;
|
1122
|
-
Runtime.QUANTUM_SIZE = 4;
|
1123
|
-
analyzeTypes(true);
|
1124
|
-
Runtime.QUANTUM_SIZE = trueQuantumSize;
|
1125
|
-
Types.flipTypes();
|
1126
|
-
}
|
1127
|
-
|
1128
|
-
newTypes = null;
|
1129
|
-
}
|
1130
|
-
|
1131
|
-
// Variable analyzer
|
1132
|
-
function variableAnalyzer() {
|
1133
|
-
// Globals
|
1134
|
-
|
1135
|
-
var old = item.globalVariables;
|
1136
|
-
item.globalVariables = {};
|
1137
|
-
old.forEach(function(variable) {
|
1138
|
-
variable.impl = 'emulated'; // All global variables are emulated, for now. Consider optimizing later if useful
|
1139
|
-
item.globalVariables[variable.ident] = variable;
|
1140
|
-
});
|
1141
|
-
|
1142
|
-
// Function locals
|
1143
|
-
|
1144
|
-
item.functions.forEach(function(func) {
|
1145
|
-
func.variables = {};
|
1146
|
-
|
1147
|
-
// LLVM is SSA, so we always have a single assignment/write. We care about
|
1148
|
-
// the reads/other uses.
|
1149
|
-
|
1150
|
-
// Function parameters
|
1151
|
-
func.params.forEach(function(param) {
|
1152
|
-
if (param.intertype !== 'varargs') {
|
1153
|
-
if (func.variables[param.ident]) warn('cannot have duplicate variable names: ' + param.ident); // toNiceIdent collisions?
|
1154
|
-
func.variables[param.ident] = {
|
1155
|
-
ident: param.ident,
|
1156
|
-
type: param.type,
|
1157
|
-
origin: 'funcparam',
|
1158
|
-
lineNum: func.lineNum,
|
1159
|
-
rawLinesIndex: -1
|
1160
|
-
};
|
1161
|
-
}
|
1162
|
-
});
|
1163
|
-
|
1164
|
-
// Normal variables
|
1165
|
-
func.lines.forEach(function(item, i) {
|
1166
|
-
if (item.assignTo) {
|
1167
|
-
if (func.variables[item.assignTo]) warn('cannot have duplicate variable names: ' + item.assignTo); // toNiceIdent collisions?
|
1168
|
-
var variable = func.variables[item.assignTo] = {
|
1169
|
-
ident: item.assignTo,
|
1170
|
-
type: item.type,
|
1171
|
-
origin: item.intertype,
|
1172
|
-
lineNum: item.lineNum,
|
1173
|
-
rawLinesIndex: i
|
1174
|
-
};
|
1175
|
-
if (variable.origin === 'alloca') {
|
1176
|
-
variable.allocatedNum = item.ident;
|
1177
|
-
}
|
1178
|
-
if (variable.origin === 'call') {
|
1179
|
-
variable.type = getReturnType(variable.type);
|
1180
|
-
}
|
1181
|
-
}
|
1182
|
-
});
|
1183
|
-
|
1184
|
-
if (QUANTUM_SIZE === 1) {
|
1185
|
-
// Second pass over variables - notice when types are crossed by bitcast
|
1186
|
-
|
1187
|
-
func.lines.forEach(function(item) {
|
1188
|
-
if (item.assignTo && item.intertype === 'bitcast') {
|
1189
|
-
// bitcasts are unique in that they convert one pointer to another. We
|
1190
|
-
// sometimes need to know the original type of a pointer, so we save that.
|
1191
|
-
//
|
1192
|
-
// originalType is the type this variable is created from
|
1193
|
-
// derivedTypes are the types that this variable is cast into
|
1194
|
-
func.variables[item.assignTo].originalType = item.type2;
|
1195
|
-
|
1196
|
-
if (!isNumber(item.assignTo)) {
|
1197
|
-
if (!func.variables[item.assignTo].derivedTypes) {
|
1198
|
-
func.variables[item.assignTo].derivedTypes = [];
|
1199
|
-
}
|
1200
|
-
func.variables[item.assignTo].derivedTypes.push(item.type);
|
1201
|
-
}
|
1202
|
-
}
|
1203
|
-
});
|
1204
|
-
}
|
1205
|
-
|
1206
|
-
// Analyze variable uses
|
1207
|
-
|
1208
|
-
function analyzeVariableUses() {
|
1209
|
-
dprint('vars', 'Analyzing variables for ' + func.ident + '\n');
|
1210
|
-
|
1211
|
-
for (vname in func.variables) {
|
1212
|
-
var variable = func.variables[vname];
|
1213
|
-
|
1214
|
-
// Whether the value itself is used. For an int, always yes. For a pointer,
|
1215
|
-
// we might never use the pointer's value - we might always just store to it /
|
1216
|
-
// read from it. If so, then we can optimize away the pointer.
|
1217
|
-
variable.hasValueTaken = false;
|
1218
|
-
|
1219
|
-
variable.pointingLevels = pointingLevels(variable.type);
|
1220
|
-
|
1221
|
-
variable.uses = 0;
|
1222
|
-
}
|
1223
|
-
|
1224
|
-
// TODO: improve the analysis precision. bitcast, for example, means we take the value, but perhaps we only use it to load/store
|
1225
|
-
var inNoop = 0;
|
1226
|
-
func.lines.forEach(function(line) {
|
1227
|
-
walkInterdata(line, function(item) {
|
1228
|
-
if (item.intertype == 'noop') inNoop++;
|
1229
|
-
if (!inNoop) {
|
1230
|
-
if (item.ident in func.variables) {
|
1231
|
-
func.variables[item.ident].uses++;
|
1232
|
-
|
1233
|
-
if (item.intertype != 'load' && item.intertype != 'store') {
|
1234
|
-
func.variables[item.ident].hasValueTaken = true;
|
1235
|
-
}
|
1236
|
-
}
|
1237
|
-
}
|
1238
|
-
}, function(item) {
|
1239
|
-
if (item.intertype == 'noop') inNoop--;
|
1240
|
-
});
|
1241
|
-
});
|
1242
|
-
|
1243
|
-
//if (dcheck('vars')) dprint('analyzed variables: ' + dump(func.variables));
|
1244
|
-
}
|
1245
|
-
|
1246
|
-
analyzeVariableUses();
|
1247
|
-
|
1248
|
-
// Decision time
|
1249
|
-
|
1250
|
-
for (vname in func.variables) {
|
1251
|
-
var variable = func.variables[vname];
|
1252
|
-
var pointedType = pointingLevels(variable.type) > 0 ? removePointing(variable.type) : null;
|
1253
|
-
if (variable.origin == 'getelementptr') {
|
1254
|
-
// Use our implementation that emulates pointers etc.
|
1255
|
-
// TODO Can we perhaps nativize some of these? However to do so, we need to discover their
|
1256
|
-
// true types; we have '?' for them now, as they cannot be discovered in the intertyper.
|
1257
|
-
variable.impl = VAR_EMULATED;
|
1258
|
-
} else if (variable.origin == 'funcparam') {
|
1259
|
-
variable.impl = VAR_EMULATED;
|
1260
|
-
} else if (variable.type == 'i64*' && USE_TYPED_ARRAYS == 2) {
|
1261
|
-
variable.impl = VAR_EMULATED;
|
1262
|
-
} else if (MICRO_OPTS && variable.pointingLevels === 0) {
|
1263
|
-
// A simple int value, can be implemented as a native variable
|
1264
|
-
variable.impl = VAR_NATIVE;
|
1265
|
-
} else if (MICRO_OPTS && variable.origin === 'alloca' && !variable.hasValueTaken &&
|
1266
|
-
variable.allocatedNum === 1 &&
|
1267
|
-
(Runtime.isNumberType(pointedType) || Runtime.isPointerType(pointedType))) {
|
1268
|
-
// A pointer to a value which is only accessible through this pointer. Basically
|
1269
|
-
// a local value on the stack, which nothing fancy is done on. So we can
|
1270
|
-
// optimize away the pointing altogether, and just have a native variable
|
1271
|
-
variable.impl = VAR_NATIVIZED;
|
1272
|
-
} else {
|
1273
|
-
variable.impl = VAR_EMULATED;
|
1274
|
-
}
|
1275
|
-
if (dcheck('vars')) dprint('// var ' + vname + ': ' + JSON.stringify(variable));
|
1276
|
-
}
|
1277
|
-
});
|
1278
|
-
}
|
1279
|
-
|
1280
|
-
// Sign analyzer
|
1281
|
-
//
|
1282
|
-
// Analyze our variables and detect their signs. In USE_TYPED_ARRAYS == 2,
|
1283
|
-
// we can read signed or unsigned values and prevent the need for signing
|
1284
|
-
// corrections. If on the other hand we are doing corrections anyhow, then
|
1285
|
-
// we can skip this pass.
|
1286
|
-
//
|
1287
|
-
// For each variable that is the result of a Load, we look a little forward
|
1288
|
-
// to see where it is used. We only care about mathops, since only they
|
1289
|
-
// need signs.
|
1290
|
-
//
|
1291
|
-
function signalyzer() {
|
1292
|
-
if (USE_TYPED_ARRAYS != 2 || CORRECT_SIGNS == 1) return;
|
1293
|
-
|
1294
|
-
function seekIdent(item, obj) {
|
1295
|
-
if (item.ident === obj.ident) {
|
1296
|
-
obj.found++;
|
1297
|
-
}
|
1298
|
-
}
|
1299
|
-
|
1300
|
-
function seekMathop(item, obj) {
|
1301
|
-
if (item.intertype === 'mathop' && obj.found && !obj.decided) {
|
1302
|
-
if (isUnsignedOp(item.op, item.variant)) {
|
1303
|
-
obj.unsigned++;
|
1304
|
-
} else {
|
1305
|
-
obj.signed++;
|
1306
|
-
}
|
1307
|
-
}
|
1308
|
-
}
|
1309
|
-
|
1310
|
-
item.functions.forEach(function(func) {
|
1311
|
-
func.lines.forEach(function(line, i) {
|
1312
|
-
if (line.intertype === 'load') {
|
1313
|
-
// Floats have no concept of signedness. Mark them as 'signed', which is the default, for which we do nothing
|
1314
|
-
if (line.type in Runtime.FLOAT_TYPES) {
|
1315
|
-
line.unsigned = false;
|
1316
|
-
return;
|
1317
|
-
}
|
1318
|
-
// Booleans are always unsigned
|
1319
|
-
var data = func.variables[line.assignTo];
|
1320
|
-
if (data.type === 'i1') {
|
1321
|
-
line.unsigned = true;
|
1322
|
-
return;
|
1323
|
-
}
|
1324
|
-
|
1325
|
-
var total = data.uses;
|
1326
|
-
if (total === 0) return;
|
1327
|
-
var obj = { ident: line.assignTo, found: 0, unsigned: 0, signed: 0, total: total };
|
1328
|
-
// in loops with phis, we can also be used *before* we are defined
|
1329
|
-
var j = i-1, k = i+1;
|
1330
|
-
while(1) {
|
1331
|
-
assert(j >= 0 || k < func.lines.length, 'Signalyzer ran out of space to look for sign indications for line ' + line.lineNum);
|
1332
|
-
if (j >= 0 && walkInterdata(func.lines[j], seekIdent, seekMathop, obj)) break;
|
1333
|
-
if (k < func.lines.length && walkInterdata(func.lines[k], seekIdent, seekMathop, obj)) break;
|
1334
|
-
if (obj.total && obj.found >= obj.total) break; // see comment below
|
1335
|
-
j -= 1;
|
1336
|
-
k += 1;
|
1337
|
-
}
|
1338
|
-
|
1339
|
-
// unsigned+signed might be < total, since the same ident can appear multiple times in the same mathop.
|
1340
|
-
// found can actually be > total, since we currently have the same ident in a GEP (see cubescript test)
|
1341
|
-
// in the GEP item, and a child item (we have the ident copied onto the GEP item as a convenience).
|
1342
|
-
// probably not a bug-causer, but FIXME. see also a reference to this above
|
1343
|
-
// we also leave the loop above potentially early due to this. otherwise, though, we end up scanning the
|
1344
|
-
// entire function in some cases which is very slow
|
1345
|
-
assert(obj.found >= obj.total, 'Could not Signalyze line ' + line.lineNum);
|
1346
|
-
line.unsigned = obj.unsigned > 0;
|
1347
|
-
dprint('vars', 'Signalyzer: ' + line.assignTo + ' has unsigned == ' + line.unsigned + ' (line ' + line.lineNum + ')');
|
1348
|
-
}
|
1349
|
-
});
|
1350
|
-
});
|
1351
|
-
}
|
1352
|
-
|
1353
|
-
// Quantum fixer
|
1354
|
-
//
|
1355
|
-
// See settings.js for the meaning of QUANTUM_SIZE. The issue we fix here is,
|
1356
|
-
// to correct the .ll assembly code so that things work with QUANTUM_SIZE=1.
|
1357
|
-
//
|
1358
|
-
function quantumFixer() {
|
1359
|
-
if (QUANTUM_SIZE !== 1) return;
|
1360
|
-
|
1361
|
-
// ptrs: the indexes of parameters that are pointers, whose originalType is what we want
|
1362
|
-
// bytes: the index of the 'bytes' parameter
|
1363
|
-
// TODO: malloc, realloc?
|
1364
|
-
var FIXABLE_CALLS = {
|
1365
|
-
'memcpy': { ptrs: [0,1], bytes: 2 },
|
1366
|
-
'memmove': { ptrs: [0,1], bytes: 2 },
|
1367
|
-
'memset': { ptrs: [0], bytes: 2 },
|
1368
|
-
'qsort': { ptrs: [0], bytes: 2 }
|
1369
|
-
};
|
1370
|
-
|
1371
|
-
function getSize(types, type, fat) {
|
1372
|
-
if (types[type]) return types[type].flatSize;
|
1373
|
-
if (fat) {
|
1374
|
-
Runtime.QUANTUM_SIZE = 4;
|
1375
|
-
}
|
1376
|
-
var ret = Runtime.getNativeTypeSize(type);
|
1377
|
-
if (fat) {
|
1378
|
-
Runtime.QUANTUM_SIZE = 1;
|
1379
|
-
}
|
1380
|
-
return ret;
|
1381
|
-
}
|
1382
|
-
|
1383
|
-
function getFlatIndexes(types, type) {
|
1384
|
-
if (types[type]) return types[type].flatIndexes;
|
1385
|
-
return [0];
|
1386
|
-
}
|
1387
|
-
|
1388
|
-
item.functions.forEach(function(func) {
|
1389
|
-
function getOriginalType(param) {
|
1390
|
-
function get() {
|
1391
|
-
if (param.intertype === 'value' && !isNumber(param.ident)) {
|
1392
|
-
if (func.variables[param.ident]) {
|
1393
|
-
return func.variables[param.ident].originalType || null;
|
1394
|
-
} else {
|
1395
|
-
return item.globalVariables[param.ident].originalType;
|
1396
|
-
}
|
1397
|
-
} else if (param.intertype === 'bitcast') {
|
1398
|
-
return param.params[0].type;
|
1399
|
-
} else if (param.intertype === 'getelementptr') {
|
1400
|
-
if (param.params[0].type[0] === '[') return param.params[0].type;
|
1401
|
-
}
|
1402
|
-
return null;
|
1403
|
-
}
|
1404
|
-
var ret = get();
|
1405
|
-
if (ret && ret[0] === '[') {
|
1406
|
-
var check = /^\[(\d+)\ x\ (.*)\]\*$/.exec(ret);
|
1407
|
-
assert(check);
|
1408
|
-
ret = check[2] + '*';
|
1409
|
-
}
|
1410
|
-
return ret;
|
1411
|
-
}
|
1412
|
-
|
1413
|
-
func.lines.forEach(function(line) {
|
1414
|
-
// Call
|
1415
|
-
if (line.intertype === 'call') {
|
1416
|
-
var funcIdent = LibraryManager.getRootIdent(line.ident.substr(1));
|
1417
|
-
var fixData = FIXABLE_CALLS[funcIdent];
|
1418
|
-
if (!fixData) return;
|
1419
|
-
var ptrs = fixData.ptrs.map(function(ptr) { return line.params[ptr] });
|
1420
|
-
var bytes = line.params[fixData.bytes].ident;
|
1421
|
-
|
1422
|
-
// Only consider original types. This assumes memcpy always has pointers bitcast to i8*
|
1423
|
-
var originalTypes = ptrs.map(getOriginalType);
|
1424
|
-
for (var i = 0; i < originalTypes.length; i++) {
|
1425
|
-
if (!originalTypes[i]) return;
|
1426
|
-
}
|
1427
|
-
originalTypes = originalTypes.map(function(type) { return removePointing(type) });
|
1428
|
-
var sizes = originalTypes.map(function(type) { return getSize(Types.types, type) });
|
1429
|
-
var fatSizes = originalTypes.map(function(type) { return getSize(Types.fatTypes, type, true) });
|
1430
|
-
// The sizes may not be identical, if we copy a descendant class into a parent class. We use
|
1431
|
-
// the smaller size in that case. However, this may also be a bug, it is hard to tell, hence a warning
|
1432
|
-
warn(dedup(sizes).length === 1, 'All sizes should probably be identical here: ' + dump(originalTypes) + ':' + dump(sizes) + ':' +
|
1433
|
-
line.lineNum);
|
1434
|
-
warn(dedup(fatSizes).length === 1, 'All fat sizes should probably be identical here: ' + dump(originalTypes) + ':' + dump(sizes) + ':' +
|
1435
|
-
line.lineNum);
|
1436
|
-
var size = Math.min.apply(null, sizes);
|
1437
|
-
var fatSize = Math.min.apply(null, fatSizes);
|
1438
|
-
if (isNumber(bytes)) {
|
1439
|
-
// Figure out how much to copy.
|
1440
|
-
var fixedBytes;
|
1441
|
-
if (bytes % fatSize === 0) {
|
1442
|
-
fixedBytes = size*(bytes/fatSize);
|
1443
|
-
} else if (fatSize % bytes === 0 && size % (fatSize/bytes) === 0) {
|
1444
|
-
// Assume this is a simple array. XXX We can be wrong though! See next TODO
|
1445
|
-
fixedBytes = size/(fatSize/bytes);
|
1446
|
-
} else {
|
1447
|
-
// Just part of a structure. Align them to see how many fields. Err on copying more.
|
1448
|
-
// TODO: properly generate a complete structure, including nesteds, and calculate on that
|
1449
|
-
var flatIndexes = getFlatIndexes(Types.types, originalTypes[0]).concat(size);
|
1450
|
-
var fatFlatIndexes = getFlatIndexes(Types.fatTypes, originalTypes[0]).concat(fatSize);
|
1451
|
-
var index = 0;
|
1452
|
-
var left = bytes;
|
1453
|
-
fixedBytes = 0;
|
1454
|
-
while (left > 0) {
|
1455
|
-
left -= fatFlatIndexes[index+1] - fatFlatIndexes[index]; // note: we copy the alignment bytes too, which is unneeded
|
1456
|
-
fixedBytes += flatIndexes[index+1] - flatIndexes[index];
|
1457
|
-
}
|
1458
|
-
}
|
1459
|
-
line.params[fixData.bytes].ident = fixedBytes;
|
1460
|
-
} else {
|
1461
|
-
line.params[fixData.bytes].intertype = 'jsvalue';
|
1462
|
-
// We have an assertion in library::memcpy() that this is round
|
1463
|
-
line.params[fixData.bytes].ident = size + '*(' + bytes + '/' + fatSize + ')';
|
1464
|
-
}
|
1465
|
-
}
|
1466
|
-
});
|
1467
|
-
});
|
1468
|
-
|
1469
|
-
// 2nd part - fix hardcoded constant offsets in global constants
|
1470
|
-
values(item.globalVariables).forEach(function(variable) {
|
1471
|
-
function recurse(item) {
|
1472
|
-
if (item.contents) {
|
1473
|
-
item.contents.forEach(recurse);
|
1474
|
-
} else if (item.intertype === 'getelementptr' && item.params[0].intertype === 'bitcast' && item.params[0].type === 'i8*') {
|
1475
|
-
var originalType = removePointing(item.params[0].params[0].type);
|
1476
|
-
var fatSize = getSize(Types.fatTypes, originalType, true);
|
1477
|
-
var slimSize = getSize(Types.types, originalType, false);
|
1478
|
-
assert(fatSize % slimSize === 0);
|
1479
|
-
item.params.slice(1).forEach(function(param) {
|
1480
|
-
if (param.intertype === 'value' && isNumber(param.ident)) {
|
1481
|
-
var corrected = parseInt(param.ident)/(fatSize/slimSize);
|
1482
|
-
assert(corrected % 1 === 0);
|
1483
|
-
param.ident = corrected.toString();
|
1484
|
-
}
|
1485
|
-
});
|
1486
|
-
} else if (item.params) {
|
1487
|
-
item.params.forEach(recurse);
|
1488
|
-
}
|
1489
|
-
}
|
1490
|
-
if (!variable.external && variable.value) recurse(variable.value);
|
1491
|
-
});
|
1492
|
-
}
|
1493
|
-
|
1494
|
-
function operateOnLabels(line, func) {
|
1495
|
-
function process(item, id) {
|
1496
|
-
['label', 'labelTrue', 'labelFalse', 'toLabel', 'unwindLabel', 'defaultLabel'].forEach(function(id) {
|
1497
|
-
if (item[id]) {
|
1498
|
-
func(item, id);
|
1499
|
-
}
|
1500
|
-
});
|
1501
|
-
}
|
1502
|
-
if (line.intertype in BRANCH_INVOKE) {
|
1503
|
-
process(line);
|
1504
|
-
} else if (line.intertype == 'switch') {
|
1505
|
-
process(line);
|
1506
|
-
line.switchLabels.forEach(process);
|
1507
|
-
}
|
1508
|
-
}
|
1509
|
-
|
1510
|
-
// Label analyzer
|
1511
|
-
function labelAnalyzer() {
|
1512
|
-
item.functions.forEach(function(func) {
|
1513
|
-
func.labelsDict = {};
|
1514
|
-
func.labelIds = {};
|
1515
|
-
func.labelIdsInverse = {};
|
1516
|
-
func.labelIdCounter = 1;
|
1517
|
-
func.labels.forEach(function(label) {
|
1518
|
-
if (!(label.ident in func.labelIds)) {
|
1519
|
-
func.labelIds[label.ident] = func.labelIdCounter++;
|
1520
|
-
func.labelIdsInverse[func.labelIdCounter-1] = label.ident;
|
1521
|
-
}
|
1522
|
-
});
|
1523
|
-
var entryIdent = func.labels[0].ident;
|
1524
|
-
|
1525
|
-
// Minify label ids to numeric ids.
|
1526
|
-
func.labels.forEach(function(label) {
|
1527
|
-
label.ident = func.labelIds[label.ident];
|
1528
|
-
label.lines.forEach(function(line) {
|
1529
|
-
operateOnLabels(line, function(item, id) {
|
1530
|
-
item[id] = func.labelIds[item[id]].toString(); // strings, because we will append as we process
|
1531
|
-
});
|
1532
|
-
});
|
1533
|
-
});
|
1534
|
-
|
1535
|
-
func.labels.forEach(function(label) {
|
1536
|
-
func.labelsDict[label.ident] = label;
|
1537
|
-
});
|
1538
|
-
|
1539
|
-
// Correct phis
|
1540
|
-
func.labels.forEach(function(label) {
|
1541
|
-
label.lines.forEach(function(phi) {
|
1542
|
-
if (phi.intertype == 'phi') {
|
1543
|
-
for (var i = 0; i < phi.params.length; i++) {
|
1544
|
-
phi.params[i].label = func.labelIds[phi.params[i].label];
|
1545
|
-
if (VERBOSE && !phi.params[i].label) warn('phi refers to nonexistent label on line ' + phi.lineNum);
|
1546
|
-
}
|
1547
|
-
}
|
1548
|
-
});
|
1549
|
-
});
|
1550
|
-
|
1551
|
-
func.lines.forEach(function(line) {
|
1552
|
-
if (line.intertype == 'indirectbr') {
|
1553
|
-
func.forceEmulated = true;
|
1554
|
-
}
|
1555
|
-
});
|
1556
|
-
|
1557
|
-
function getActualLabelId(labelId) {
|
1558
|
-
if (func.labelsDict[labelId]) return labelId;
|
1559
|
-
// If not present, it must be a surprisingly-named entry (or undefined behavior, in which case, still ok to use the entry)
|
1560
|
-
labelId = func.labelIds[entryIdent];
|
1561
|
-
assert(func.labelsDict[labelId]);
|
1562
|
-
return labelId;
|
1563
|
-
}
|
1564
|
-
|
1565
|
-
// Basic longjmp support, see library.js setjmp/longjmp
|
1566
|
-
var setjmp = toNiceIdent('@setjmp');
|
1567
|
-
func.setjmpTable = null;
|
1568
|
-
for (var i = 0; i < func.labels.length; i++) {
|
1569
|
-
var label = func.labels[i];
|
1570
|
-
for (var j = 0; j < label.lines.length; j++) {
|
1571
|
-
var line = label.lines[j];
|
1572
|
-
if ((line.intertype == 'call' || line.intertype == 'invoke') && line.ident == setjmp) {
|
1573
|
-
if (line.intertype == 'invoke') {
|
1574
|
-
// setjmp cannot trigger unwinding, so just reduce the invoke to a call + branch
|
1575
|
-
line.intertype = 'call';
|
1576
|
-
label.lines.push({
|
1577
|
-
intertype: 'branch',
|
1578
|
-
label: line.toLabel,
|
1579
|
-
lineNum: line.lineNum + 0.01, // XXX legalizing might confuse this
|
1580
|
-
});
|
1581
|
-
line.toLabel = line.unwindLabel = -2;
|
1582
|
-
}
|
1583
|
-
// split this label into up to the setjmp (including), then a new label for the rest. longjmp will reach the rest
|
1584
|
-
var oldLabel = label.ident;
|
1585
|
-
var newLabel = func.labelIdCounter++;
|
1586
|
-
if (!func.setjmpTable) func.setjmpTable = [];
|
1587
|
-
func.setjmpTable.push({ oldLabel: oldLabel, newLabel: newLabel, assignTo: line.assignTo });
|
1588
|
-
func.labels.splice(i+1, 0, {
|
1589
|
-
intertype: 'label',
|
1590
|
-
ident: newLabel,
|
1591
|
-
lineNum: label.lineNum + 0.5,
|
1592
|
-
lines: label.lines.slice(j+1)
|
1593
|
-
});
|
1594
|
-
func.labelsDict[newLabel] = func.labels[i+1];
|
1595
|
-
label.lines = label.lines.slice(0, j+1);
|
1596
|
-
label.lines.push({
|
1597
|
-
intertype: 'branch',
|
1598
|
-
label: toNiceIdent(newLabel),
|
1599
|
-
lineNum: line.lineNum + 0.01, // XXX legalizing might confuse this
|
1600
|
-
});
|
1601
|
-
// Correct phis
|
1602
|
-
func.labels.forEach(function(label) {
|
1603
|
-
label.lines.forEach(function(phi) {
|
1604
|
-
if (phi.intertype == 'phi') {
|
1605
|
-
for (var i = 0; i < phi.params.length; i++) {
|
1606
|
-
var sourceLabelId = getActualLabelId(phi.params[i].label);
|
1607
|
-
if (sourceLabelId == oldLabel) {
|
1608
|
-
phi.params[i].label = newLabel;
|
1609
|
-
}
|
1610
|
-
}
|
1611
|
-
}
|
1612
|
-
});
|
1613
|
-
});
|
1614
|
-
}
|
1615
|
-
}
|
1616
|
-
}
|
1617
|
-
if (func.setjmpTable) {
|
1618
|
-
func.forceEmulated = true;
|
1619
|
-
recomputeLines(func);
|
1620
|
-
}
|
1621
|
-
|
1622
|
-
// Properly implement phis, by pushing them back into the branch
|
1623
|
-
// that leads to here. We will only have the |var| definition in this location.
|
1624
|
-
|
1625
|
-
// First, push phis back
|
1626
|
-
func.labels.forEach(function(label) {
|
1627
|
-
label.lines.forEach(function(phi) {
|
1628
|
-
if (phi.intertype == 'phi') {
|
1629
|
-
for (var i = 0; i < phi.params.length; i++) {
|
1630
|
-
var param = phi.params[i];
|
1631
|
-
if (VERBOSE && !param.label) warn('phi refers to nonexistent label on line ' + phi.lineNum);
|
1632
|
-
var sourceLabelId = getActualLabelId(param.label);
|
1633
|
-
if (sourceLabelId) {
|
1634
|
-
var sourceLabel = func.labelsDict[sourceLabelId];
|
1635
|
-
var lastLine = sourceLabel.lines.slice(-1)[0];
|
1636
|
-
assert(lastLine.intertype in LLVM.PHI_REACHERS, 'Only some can lead to labels with phis:' + [func.ident, label.ident, lastLine.intertype]);
|
1637
|
-
if (!lastLine.phi) {
|
1638
|
-
lastLine.phi = true;
|
1639
|
-
assert(!lastLine.dependent);
|
1640
|
-
lastLine.dependent = {
|
1641
|
-
intertype: 'phiassigns',
|
1642
|
-
params: []
|
1643
|
-
};
|
1644
|
-
};
|
1645
|
-
lastLine.dependent.params.push({
|
1646
|
-
intertype: 'phiassign',
|
1647
|
-
ident: phi.assignTo,
|
1648
|
-
value: param.value,
|
1649
|
-
targetLabel: label.ident
|
1650
|
-
});
|
1651
|
-
}
|
1652
|
-
}
|
1653
|
-
// The assign to phi is now just a var
|
1654
|
-
phi.intertype = 'var';
|
1655
|
-
phi.ident = phi.assignTo;
|
1656
|
-
phi.assignTo = null;
|
1657
|
-
}
|
1658
|
-
});
|
1659
|
-
});
|
1660
|
-
|
1661
|
-
if (func.ident in NECESSARY_BLOCKADDRS) {
|
1662
|
-
Functions.blockAddresses[func.ident] = {};
|
1663
|
-
for (var needed in NECESSARY_BLOCKADDRS[func.ident]) {
|
1664
|
-
assert(needed in func.labelIds);
|
1665
|
-
Functions.blockAddresses[func.ident][needed] = func.labelIds[needed];
|
1666
|
-
}
|
1667
|
-
}
|
1668
|
-
});
|
1669
|
-
}
|
1670
|
-
|
1671
|
-
// Stack analyzer - calculate the base stack usage
|
1672
|
-
function stackAnalyzer() {
|
1673
|
-
data.functions.forEach(function(func) {
|
1674
|
-
var lines = func.labels[0].lines;
|
1675
|
-
var hasAlloca = false;
|
1676
|
-
for (var i = 0; i < lines.length; i++) {
|
1677
|
-
var item = lines[i];
|
1678
|
-
if (!item.assignTo || item.intertype != 'alloca' || !isNumber(item.ident)) break;
|
1679
|
-
item.allocatedSize = func.variables[item.assignTo].impl === VAR_EMULATED ?
|
1680
|
-
calcAllocatedSize(item.allocatedType)*item.ident: 0;
|
1681
|
-
hasAlloca = true;
|
1682
|
-
if (USE_TYPED_ARRAYS === 2) {
|
1683
|
-
// We need to keep the stack aligned
|
1684
|
-
item.allocatedSize = Runtime.forceAlign(item.allocatedSize, Runtime.STACK_ALIGN);
|
1685
|
-
}
|
1686
|
-
}
|
1687
|
-
var index = 0;
|
1688
|
-
for (var i = 0; i < lines.length; i++) {
|
1689
|
-
var item = lines[i];
|
1690
|
-
if (!item.assignTo || item.intertype != 'alloca' || !isNumber(item.ident)) break;
|
1691
|
-
item.allocatedIndex = index;
|
1692
|
-
index += item.allocatedSize;
|
1693
|
-
delete item.allocatedSize;
|
1694
|
-
}
|
1695
|
-
func.initialStack = index;
|
1696
|
-
func.otherStackAllocations = false;
|
1697
|
-
if (func.initialStack === 0 && hasAlloca) func.otherStackAllocations = true; // a single alloca of zero still requires us to emit stack support code
|
1698
|
-
while (func.initialStack == 0) { // one-time loop with possible abort in the middle
|
1699
|
-
// If there is no obvious need for stack management, perhaps we don't need it
|
1700
|
-
// (we try to optimize that way with SKIP_STACK_IN_SMALL). However,
|
1701
|
-
// we need to note if stack allocations other than initial allocs can happen here
|
1702
|
-
// If so, we need to rewind the stack when we leave.
|
1703
|
-
|
1704
|
-
// By-value params are causes of additional allocas (although we could in theory make them normal allocas too)
|
1705
|
-
func.params.forEach(function(param) {
|
1706
|
-
if (param.byVal) {
|
1707
|
-
func.otherStackAllocations = true;
|
1708
|
-
}
|
1709
|
-
});
|
1710
|
-
if (func.otherStackAllocations) break;
|
1711
|
-
|
1712
|
-
// Allocas
|
1713
|
-
var finishedInitial = false;
|
1714
|
-
|
1715
|
-
lines = func.lines; // We need to consider all the function lines now, not just the first label
|
1716
|
-
|
1717
|
-
for (var i = 0; i < lines.length; i++) {
|
1718
|
-
var item = lines[i];
|
1719
|
-
if (!finishedInitial && (!item.assignTo || item.intertype != 'alloca' || !isNumber(item.ident))) {
|
1720
|
-
finishedInitial = true;
|
1721
|
-
}
|
1722
|
-
if (item.intertype == 'alloca' && finishedInitial) {
|
1723
|
-
func.otherStackAllocations = true;
|
1724
|
-
break;
|
1725
|
-
}
|
1726
|
-
}
|
1727
|
-
if (func.otherStackAllocations) break;
|
1728
|
-
|
1729
|
-
// Varargs
|
1730
|
-
for (var i = 0; i < lines.length; i++) {
|
1731
|
-
var item = lines[i];
|
1732
|
-
if (item.intertype == 'call' && isVarArgsFunctionType(item.type)) {
|
1733
|
-
func.otherStackAllocations = true;
|
1734
|
-
break;
|
1735
|
-
}
|
1736
|
-
}
|
1737
|
-
if (func.otherStackAllocations) break;
|
1738
|
-
|
1739
|
-
break;
|
1740
|
-
}
|
1741
|
-
});
|
1742
|
-
}
|
1743
|
-
|
1744
|
-
// ReLooper - reconstruct nice loops, as much as possible
|
1745
|
-
// This is now done in the jsify stage, using compiled relooper2
|
1746
|
-
function relooper() {
|
1747
|
-
function makeBlock(labels, entries, labelsDict, forceEmulated) {
|
1748
|
-
if (labels.length == 0) return null;
|
1749
|
-
dprint('relooping', 'prelooping: ' + entries + ',' + labels.length + ' labels');
|
1750
|
-
assert(entries && entries[0]); // need at least 1 entry
|
1751
|
-
|
1752
|
-
var emulated = {
|
1753
|
-
type: 'emulated',
|
1754
|
-
id: 'B',
|
1755
|
-
labels: labels,
|
1756
|
-
entries: entries.slice(0)
|
1757
|
-
};
|
1758
|
-
return emulated;
|
1759
|
-
}
|
1760
|
-
item.functions.forEach(function(func) {
|
1761
|
-
dprint('relooping', "// relooping function: " + func.ident);
|
1762
|
-
func.block = makeBlock(func.labels, [func.labels[0].ident], func.labelsDict, func.forceEmulated);
|
1763
|
-
});
|
1764
|
-
}
|
1765
|
-
|
1766
|
-
// main
|
1767
|
-
castAway();
|
1768
|
-
legalizer();
|
1769
|
-
typevestigator();
|
1770
|
-
analyzeTypes();
|
1771
|
-
variableAnalyzer();
|
1772
|
-
signalyzer();
|
1773
|
-
quantumFixer();
|
1774
|
-
labelAnalyzer();
|
1775
|
-
stackAnalyzer();
|
1776
|
-
relooper();
|
1777
|
-
|
1778
|
-
//B.stop('analyzer');
|
1779
|
-
return item;
|
1780
|
-
}
|
1781
|
-
|