Dan Gohman
0826e32c9a
Tidy up unnecessary return statements.
2019-01-05 16:23:04 -08:00
Dan Gohman
3143e22566
Move the creation of linear-memory guard pages into the mmap module.
...
Create linear-memory pages as PROT_NONE and then make them accessible on
demand.
2019-01-05 16:23:04 -08:00
Dan Gohman
3ac4269dc5
Add host_state() accessors to InstanceContents and VMContext too.
2019-01-04 17:24:14 -08:00
Dan Gohman
73b2c45313
Add a host_state field to Instance.
...
This allows hosts to embed arbitrary state along with instances.
2019-01-04 17:15:22 -08:00
Dan Gohman
3aef763046
Delete an unneeded comment.
2019-01-03 15:50:04 -08:00
Dan Gohman
6661228c86
Tidy up whitespace.
2019-01-03 14:44:30 -08:00
Dan Gohman
e876f0fb1d
Add some Cargo.toml keywords.
2019-01-03 14:25:33 -08:00
Dan Gohman
35d7f78a11
Handle errors cleanly in the wast runner.
2019-01-03 14:16:48 -08:00
Dan Gohman
40acc1f340
Add crate version identifiers.
2019-01-03 14:16:48 -08:00
Dan Gohman
585bdac91e
Use vec![0; size] instead of creating an empty Vec and resizing.
2019-01-03 14:16:48 -08:00
Dan Gohman
a41bc1fe1e
Fix unused use warnings.
2019-01-03 14:16:48 -08:00
Dan Gohman
ca2fdc5ccb
Update no_std support.
...
This `no_std` support isn't complete though, as some dependencies
don't support it.
2019-01-03 14:16:48 -08:00
Dan Gohman
f6c2fe7d2d
Update to Rust 2018 Edition.
2019-01-03 12:58:11 -08:00
Dan Gohman
00a84672f7
Use Vec::with_capacity.
2019-01-03 12:37:14 -08:00
Benjamin Bouvier
03c22ed67a
Remove warnings in tests;
2019-01-03 12:14:39 -08:00
Benjamin Bouvier
c78a9a4a7c
Bump log and file-per-thread-logger;
2019-01-03 12:14:39 -08:00
Benjamin Bouvier
813810008b
Replace deprecated trim_left_matches by trim_start_matches;
2019-01-03 12:14:39 -08:00
Benjamin Bouvier
7e42966c68
Use snake case for magic numbers computation;
2019-01-03 12:13:25 -08:00
Dan Gohman
fdc66e130f
Eliminate unneeded casts.
2019-01-03 12:05:32 -08:00
Dan Gohman
39770ec72c
Minor code tidying.
2019-01-03 12:05:26 -08:00
Dan Gohman
701b1998e9
Avoid creating slices with null pointers.
2019-01-03 12:05:17 -08:00
Dan Gohman
57e183f5f8
Use TablePlan::for_table and MemoryPlan::for_memory instead of manual code.
2019-01-03 12:05:07 -08:00
Dan Gohman
8a5429ce74
Factor out functions for working with table and memory initializers.
2019-01-03 12:04:58 -08:00
Dan Gohman
747dbb23e7
Add fuzz targets for module instantiation.
2019-01-03 12:04:48 -08:00
Dan Gohman
df7724ce2b
Update Cargo.toml authors fields.
2019-01-03 12:04:37 -08:00
Dan Gohman
2f04b78ecf
Use cast::usize rather than as usize to avoid silent overflow.
2019-01-03 12:04:24 -08:00
Dan Gohman
529de7ca60
Tidy up unneeded '&'s.
2019-01-03 12:03:52 -08:00
Dan Gohman
c66a3c23f3
Tidy up some documentation comments.
2019-01-03 12:03:43 -08:00
Dan Gohman
3ce2127bfa
Eliminate the intermediate "base" global variables.
2019-01-03 12:03:33 -08:00
Dan Gohman
3431122440
Update to bindgen 0.46.
2019-01-03 12:03:22 -08:00
Dan Gohman
1ae5c13b8c
Signature ID loads are readonly.
2019-01-03 12:03:14 -08:00
Dan Gohman
8939d1252a
Document that wasmtime-runtime is meant to be compiled for the target.
2019-01-03 12:02:57 -08:00
Dan Gohman
3270369a69
Restructure VMContext to eliminate a level of indirection.
2019-01-03 12:02:35 -08:00
Dan Gohman
ff6776fe10
Refactor instance accessor routines.
...
This helps localize the unsafe code needed to access these fields.
2019-01-03 11:49:25 -08:00
Dan Gohman
482a054c75
Move the signature_ids field first.
2019-01-03 11:49:15 -08:00
Dan Gohman
e8e8f453a4
Refactor out the code for creating the signature_ids base global value.
2019-01-03 11:49:04 -08:00
Dan Gohman
087b5b4dff
Implement cross-instance indirect calls.
2019-01-03 11:48:53 -08:00
Dan Gohman
b646f9b4e0
Clarify a comment.
2019-01-03 11:48:43 -08:00
Dan Gohman
9d73123e3e
Reformat a comment to fit within 100 columns.
2019-01-03 11:48:34 -08:00
Dan Gohman
bec724b501
Whitespace tidying.
2019-01-03 11:48:26 -08:00
Dan Gohman
b704f5ad30
Update to wasmparser 0.23.0.
2019-01-03 11:48:13 -08:00
Dan Gohman
63c9143e87
Update to bindgen 0.45.
2019-01-03 11:48:05 -08:00
Dan Gohman
7592c99f3b
Refactor the compilation and instantiation pipeline.
...
wasmtime-execute is now wasmtime-jit. Move `JITCode` and the TargetIsa
into a new `Compiler` type. `InstancePlus` is no more, with trampoline
functionality now handled by `Compiler`.
2019-01-03 11:47:55 -08:00
Dan Gohman
450a279e18
Rename wasmtime's logfile names.
2019-01-03 11:47:40 -08:00
bjorn3
e9cb50313d
Fix emit_small_mem{cpy,set} when size == 0 or access_size > 8
2019-01-02 12:18:49 -08:00
Dan Gohman
c8e47177fc
Add an assert to append_ebb_params_for_function_params.
2019-01-02 12:05:32 -08:00
Dan Gohman
831d033471
Add a shrink_to_fit function to PrimaryMap.
2019-01-02 12:01:36 -08:00
Dan Gohman
cd4f96c066
Use Vec::with_capacity when we know the eventual size of the Vec.
2019-01-02 11:59:57 -08:00
Dan Gohman
29edc3fe50
Make ListPool's alloc fill new memory with reserved values.
...
This makes it harder to misuse, as 0 could be confused for a valid value.
2019-01-02 11:59:22 -08:00
Dan Gohman
8a11bd6af7
Remove BoxedSlice's next_key() function, which is unneeded.
...
`BoxedSlice` does not support appending elements, so it isn't useful to
look up the next key.
2019-01-02 11:58:44 -08:00