Sergey Pepyakin
a3719e08e5
Pass arguments.
6 years ago
Sergey Pepyakin
eb60c2587a
Basic form of a function call
6 years ago
Sergey Pepyakin
635ccc6916
Introduce TranslationContext
6 years ago
Sergey Pepyakin
f22b9903b6
Pass function sig in function_body::translate
6 years ago
Jef
1e04dc90b6
Make more tests quickcheck-compatible, remove unused code
6 years ago
Jef
b832832c76
Add const folding, fix returning values from blocks
6 years ago
Jef
17ecd049a1
Register allocation V2
This lays the groundwork for other on-the-fly optimisations,
like passing literals through in order to do const folding
in linear time, while compiling.
6 years ago
Jef
4994e3671c
Remove unused argument from fibonacci example
6 years ago
Jef
912fa83fff
Add benchmarks
6 years ago
Jef
5bb7430976
Add quickcheck, implement simple binary operations
6 years ago
Jef
5b448ce3c7
Stop leaking stack space on function call
6 years ago
Dan Gohman
3f24098edc
Implement the remaining valid spec tests.
And lots of other miscellaneous changes. Rename InstanceWorld to
InstancePlus and reorganize its contents. This still isn't a great name,
but at least now it has a clear purpose.
6 years ago
Jef
189996accd
Fix receiving more than 6 arguments, allow calling functions with more than 6 arguments
6 years ago
Jef
86353cba5e
Allow calling functions with any signature
6 years ago
Dan Gohman
56850d481d
Initial support for function, table, memory, and global imports.
6 years ago
Sergey Pepyakin
b32f77ea02
Add the fib test.
6 years ago
Sergey Pepyakin
0cd70c649a
Implement returns.
6 years ago
Sergey Pepyakin
e02dbf1bc2
Add i32 literals support.
6 years ago
Sergey Pepyakin
0e9ba8332f
Pass arguments.
6 years ago
Dan Gohman
7dcca6be5b
Improve error handling, and start refactoring Instance.
Introduce proper error handling in several places, and perform a first
pass at refactoring Instance to make it easier to use.
6 years ago
Sergey Pepyakin
078486e080
Basic form of a function call
6 years ago
Dan Gohman
fe562297a7
Rename wasmtime's --function to --invoke.
This highlights the similarity with the `invoke` command in `wast` files.
6 years ago
Dan Gohman
a635861425
Report traps in functions invoked from the command line.
6 years ago
Dan Gohman
dca7729313
Improve error handling and misc cleanups.
6 years ago
Dan Gohman
08488591a9
Fix clippy warning namespaces.
6 years ago
Dan Gohman
d9b4bd1de8
Support imports.
6 years ago
Dan Gohman
8170a9db79
Update to the rustfmt in rust 1.31, which is now stable.
6 years ago
Dan Gohman
57635eb62b
Implement minimal call_indirect signature checking.
6 years ago
Dan Gohman
04b7f0c0df
Fix the description of the wasmtime program.
6 years ago
Dan Gohman
7faa15d7ac
More infrastructure.
Improve handling of memory.grow/size, add a standalone wast runner,
test harness improvements.
6 years ago
Dan Gohman
bd69768e0d
Improve infrastructure.
Do more encapsulation of raw pointers, use more PrimaryMaps instead of
Vecs, add a table.rs for managing table storage.
6 years ago
Dan Gohman
099f85f821
Rename main.rs to wasmtime.rs.
6 years ago
Dan Gohman
8dbd4b8d7c
Start a wast testing harness and add some tests.
This implements a minimal wast testing harness in tests/wast.rs, which
runs the wast tests under tests/wast.
It also adds tests for trapping in a variety of ways, and fixes several
bugs exposed by those tests.
6 years ago
Dan Gohman
f44fe25f9c
Rewrite linear memory handling in terms of simple mmap/VirtualAlloc.
The memmap crate doesn't make it straightforward to have part of the
region be writeable and part readonly. Since this is a fairly boutique
use case, and we don't need all that much code, just use the low-level
APIs directly.
Also, introduce a concept of "tunables" for adjusting the parameters of
the runtime.
6 years ago
Frank Rehberger
ec940ee8af
Migrating to wabt::wat2wasm ( #29 )
* Add test_environ_translate
* Migrating to wabt::wat2wasm
6 years ago
Dan Gohman
b3d831015c
Add basic logging support to the wasmtime binary.
6 years ago
Sergey Pepyakin
5eb43f027a
Introduce TranslationContext
6 years ago
Sergey Pepyakin
52c0443368
Pass function sig in function_body::translate
6 years ago
Sergey Pepyakin
13c36612b5
increment → reserve.
6 years ago
Sergey Pepyakin
aa5643b9b5
Implement if then else
6 years ago
Sergey Pepyakin
ba216b2e8a
Add a simple i32.eq operator.
6 years ago
Sergey Pepyakin
b42696f207
Add a simple boilerplate.
6 years ago
Frank Rehberger
4ac41213ad
Add test_environ_translate
6 years ago
Geoffroy Couprie
bf5a06bc95
separate the context intialization from the function execution ( #21 )
the start function is called from the initialization phase
6 years ago
Dan Gohman
74ccddcd64
Update to Cranelift 0.24.
6 years ago
Geoffroy Couprie
7fca0792dd
add a way to provide imported functions during relocation
They are provided as a closure taking the module (&str) and function name (&str) as arguments,
returning an address (Option<isize>)
6 years ago
Sergey Pepyakin
08240761d5
Compile a simple function ( #2 )
* Implement basics.
* Execute code
* Add wasm2wat test cases.
* abi_loc_for_arg for stack.
* Assert that sp_depth is 0 at the epilogue
* Do 32bit add.
* Assert that RAX can be used as a scratch register
* Reuse assembler.
* Align stack slots.
6 years ago
Dan Gohman
154b35ecc1
Initial experiment.
6 years ago
Nathan Froyd
5f11f44482
add a --target option to wasm2obj
6 years ago
Dan Gohman
5a96e022db
Update to the rustfmt in rust 1.29, which is now stable.
6 years ago