Rename memory instructions; Rework constant handling (#177)

* Rename memory instructions as proposed by the bulk-memory-operations spec.
* Rename memory manager functions to memory.* as well
* Remove automatic inlining of constant globals (Binaryen does this now)
* Improve 'const' enum compatibility
* Improve module-level export generation
* Enable the inline decorator for constant variables
* Add ERROR, WARNING and INFO macros that emit a user-defined diagnostic
* Reintroduce builtin decorator so these can appear anywhere in stdlib again
* Inline isNaN and isFinite by default
* Make an interface around gc.* similar to memory.*
* Emit an error when trying to inline a mutable variable
* Slim down CI stages
* Add a more convenient tracing utility for debugging
* Implement some prequesites for an eventual bundled GC
This commit is contained in:
Daniel Wirtz
2018-07-20 22:53:33 +02:00
committed by GitHub
parent 34e8facfdc
commit 39b489bee2
196 changed files with 28714 additions and 6674 deletions

View File

@ -4,7 +4,8 @@
(type $iiiiv (func (param i32 i32 i32 i32)))
(global $assembly/i64/lo (mut i32) (i32.const 0))
(global $assembly/i64/hi (mut i32) (i32.const 0))
(memory $0 1)
(memory $0 0)
(export "memory" (memory $0))
(export "getLo" (func $assembly/i64/getLo))
(export "getHi" (func $assembly/i64/getHi))
(export "clz" (func $assembly/i64/clz))
@ -36,7 +37,6 @@
(export "gt_u" (func $assembly/i64/gt_u))
(export "ge_s" (func $assembly/i64/ge_s))
(export "ge_u" (func $assembly/i64/ge_u))
(export "memory" (memory $0))
(func $assembly/i64/getLo (; 0 ;) (type $i) (result i32)
;;@ assembly/i64.ts:4:9
(get_global $assembly/i64/lo)

View File

@ -7,7 +7,8 @@
(global $NaN f64 (f64.const nan:0x8000000000000))
(global $Infinity f64 (f64.const inf))
(global $HEAP_BASE i32 (i32.const 8))
(memory $0 1)
(memory $0 0)
(export "memory" (memory $0))
(export "getLo" (func $assembly/i64/getLo))
(export "getHi" (func $assembly/i64/getHi))
(export "clz" (func $assembly/i64/clz))
@ -39,7 +40,6 @@
(export "gt_u" (func $assembly/i64/gt_u))
(export "ge_s" (func $assembly/i64/ge_s))
(export "ge_u" (func $assembly/i64/ge_u))
(export "memory" (memory $0))
(func $assembly/i64/getLo (; 0 ;) (type $i) (result i32)
;;@ assembly/i64.ts:4:9
(get_global $assembly/i64/lo)