virtual-machine 0.0.3 → 0.0.10
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.
- package/build/{chunk-GZ343GYI.mjs → chunk-MELUIZWO.mjs} +6 -104
- package/build/cli.js +591 -709
- package/build/index.d.ts +2 -11
- package/build/index.js +9 -107
- package/build/index.mjs +4 -4
- package/build/{riscv_vm-3CIEJ5K7.mjs → riscv_vm-JTPPWIT3.mjs} +1 -1
- package/package.json +12 -5
- package/.yarn/install-state.gz +0 -0
- package/.yarnrc.yml +0 -1
- package/Cargo.toml +0 -49
- package/build/chunk-LJUNPJTY.mjs +0 -670
- package/build/chunk-Q7TFYQ5G.mjs +0 -670
- package/build/riscv_vm-MHIWEZQY.mjs +0 -12
- package/build/riscv_vm-VNML57ES.mjs +0 -12
- package/build.sh +0 -25
- package/cli.ts +0 -268
- package/index.ts +0 -16
- package/src/bus.rs +0 -558
- package/src/clint.rs +0 -132
- package/src/console.rs +0 -83
- package/src/cpu.rs +0 -1913
- package/src/csr.rs +0 -67
- package/src/decoder.rs +0 -789
- package/src/dram.rs +0 -146
- package/src/emulator.rs +0 -603
- package/src/lib.rs +0 -270
- package/src/main.rs +0 -373
- package/src/mmu.rs +0 -331
- package/src/net.rs +0 -121
- package/src/net_tap.rs +0 -164
- package/src/net_webtransport.rs +0 -446
- package/src/net_ws.rs +0 -396
- package/src/plic.rs +0 -261
- package/src/uart.rs +0 -233
- package/src/virtio.rs +0 -1074
- package/tsconfig.json +0 -19
- package/tsup/index.ts +0 -79
- package/tsup/tsup.cli.ts +0 -8
- package/tsup/tsup.core.cjs.ts +0 -7
- package/tsup/tsup.core.esm.ts +0 -8
package/build/index.d.ts
CHANGED
|
@@ -23,11 +23,6 @@ declare class WasmVm {
|
|
|
23
23
|
* Get the current network connection status.
|
|
24
24
|
*/
|
|
25
25
|
network_status(): NetworkStatus;
|
|
26
|
-
/**
|
|
27
|
-
* Connect to a WebSocket relay server for networking.
|
|
28
|
-
* The URL should be like "ws://localhost:8765".
|
|
29
|
-
*/
|
|
30
|
-
connect_network(ws_url: string): void;
|
|
31
26
|
/**
|
|
32
27
|
* Get current memory usage (DRAM size) in bytes.
|
|
33
28
|
*/
|
|
@@ -64,7 +59,6 @@ type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembly.Modul
|
|
|
64
59
|
interface InitOutput {
|
|
65
60
|
readonly memory: WebAssembly.Memory;
|
|
66
61
|
readonly __wbg_wasmvm_free: (a: number, b: number) => void;
|
|
67
|
-
readonly wasmvm_connect_network: (a: number, b: number, c: number) => [number, number];
|
|
68
62
|
readonly wasmvm_connect_webtransport: (a: number, b: number, c: number, d: number, e: number) => [number, number];
|
|
69
63
|
readonly wasmvm_disconnect_network: (a: number) => void;
|
|
70
64
|
readonly wasmvm_get_memory_usage: (a: number) => bigint;
|
|
@@ -74,11 +68,8 @@ interface InitOutput {
|
|
|
74
68
|
readonly wasmvm_network_status: (a: number) => number;
|
|
75
69
|
readonly wasmvm_new: (a: number, b: number) => [number, number, number];
|
|
76
70
|
readonly wasmvm_step: (a: number) => void;
|
|
77
|
-
readonly
|
|
78
|
-
readonly
|
|
79
|
-
readonly wasm_bindgen__convert__closures_____invoke__h6fd3101b14d9814b: (a: number, b: number, c: any) => void;
|
|
80
|
-
readonly wasm_bindgen__closure__destroy__hb2f3fe1158f30bc9: (a: number, b: number) => void;
|
|
81
|
-
readonly wasm_bindgen__convert__closures_____invoke__h74b0833075704714: (a: number, b: number, c: any) => void;
|
|
71
|
+
readonly wasm_bindgen__convert__closures_____invoke__hf80474e20f8b36e4: (a: number, b: number, c: any) => void;
|
|
72
|
+
readonly wasm_bindgen__closure__destroy__hb58eefa6e6233209: (a: number, b: number) => void;
|
|
82
73
|
readonly __wbindgen_malloc: (a: number, b: number) => number;
|
|
83
74
|
readonly __wbindgen_realloc: (a: number, b: number, c: number, d: number) => number;
|
|
84
75
|
readonly __wbindgen_exn_store: (a: number) => void;
|