@ai-ecoverse/slicc-kernel 1.107.1 → 1.108.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.
- package/README.md +8 -2
- package/dist/kernel-worker.js +27 -5
- package/dist/kernel-worker.js.map +2 -2
- package/dist/node-process-worker.js +191 -166
- package/dist/node-process-worker.js.map +4 -4
- package/dist/node.js +27 -5
- package/dist/node.js.map +2 -2
- package/dist/process-worker.js +191 -166
- package/dist/process-worker.js.map +4 -4
- package/dist/types/kernel/children.d.ts +3 -0
- package/dist/types/kernel/process.d.ts +6 -0
- package/dist/types/process/process-signals.d.ts +8 -6
- package/dist/types/process/wasi/wasi-fds.d.ts +1 -1
- package/dist/types/process/wasi/wasi-host.d.ts +1 -1
- package/dist/types/process/wasi/wasi-signals.d.ts +4 -7
- package/package.json +1 -1
|
@@ -70,6 +70,8 @@ export declare class ChildTable {
|
|
|
70
70
|
private readonly leftovers;
|
|
71
71
|
onChildState?: () => void;
|
|
72
72
|
onReap?: (pid: number) => void;
|
|
73
|
+
autoReap?: () => boolean;
|
|
74
|
+
private readonly kept;
|
|
73
75
|
private stateChanged;
|
|
74
76
|
private readonly watchers;
|
|
75
77
|
private readonly parentFds;
|
|
@@ -86,6 +88,7 @@ export declare class ChildTable {
|
|
|
86
88
|
private nextChange;
|
|
87
89
|
private stateReport;
|
|
88
90
|
private reap;
|
|
91
|
+
keep(pid: number): void;
|
|
89
92
|
pids(): number[];
|
|
90
93
|
captured(pid: number, slot: number): Uint8Array;
|
|
91
94
|
}
|
|
@@ -314,6 +314,9 @@ export type WasmSyscall = {
|
|
|
314
314
|
caught: number;
|
|
315
315
|
ignored: number;
|
|
316
316
|
defaults?: number;
|
|
317
|
+
nocldwait?: boolean;
|
|
318
|
+
} | {
|
|
319
|
+
op: 'sig-inherited';
|
|
317
320
|
} | {
|
|
318
321
|
op: 'sig-waiting';
|
|
319
322
|
tid: number;
|
|
@@ -400,6 +403,7 @@ export declare class WasmProcess {
|
|
|
400
403
|
private caught;
|
|
401
404
|
private ignored;
|
|
402
405
|
private inherited;
|
|
406
|
+
private nocldwait;
|
|
403
407
|
private interrupt;
|
|
404
408
|
private readonly gone;
|
|
405
409
|
private dying;
|
|
@@ -510,6 +514,8 @@ export declare class WasmProcess {
|
|
|
510
514
|
private socketSyscall;
|
|
511
515
|
private tty;
|
|
512
516
|
private procSyscall;
|
|
517
|
+
private signalSyscall;
|
|
518
|
+
private reapsChildren;
|
|
513
519
|
private sudo;
|
|
514
520
|
private mountSyscall;
|
|
515
521
|
private pause;
|
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
import type { SyncSabTransport } from '../realm/sync-sab-bridge.js';
|
|
2
|
+
export interface SignalMasks {
|
|
3
|
+
caught: number;
|
|
4
|
+
ignored: number;
|
|
5
|
+
restart: number;
|
|
6
|
+
defaults?: number;
|
|
7
|
+
nocldwait?: boolean;
|
|
8
|
+
}
|
|
2
9
|
export interface SignalHooks {
|
|
3
|
-
masks():
|
|
4
|
-
caught: number;
|
|
5
|
-
ignored: number;
|
|
6
|
-
restart: number;
|
|
7
|
-
defaults?: number;
|
|
8
|
-
} | null;
|
|
10
|
+
masks(): SignalMasks | null;
|
|
9
11
|
raise(sig: number): void;
|
|
10
12
|
timer?(which: number): void;
|
|
11
13
|
killed?(code: number): void;
|
|
@@ -114,7 +114,7 @@ export declare class WasiFds {
|
|
|
114
114
|
resolve(dirfd: number, path: string): string;
|
|
115
115
|
private openKernelDevice;
|
|
116
116
|
private openCharDevice;
|
|
117
|
-
open(path: string, oflags: number, rights: bigint, fdflags: number): number;
|
|
117
|
+
open(path: string, oflags: number, rights: bigint, fdflags: number, mode?: number): number;
|
|
118
118
|
private regular;
|
|
119
119
|
private kernelHolds;
|
|
120
120
|
private readonly learned;
|
|
@@ -2,7 +2,7 @@ import type { DeviceMeta, KernelFdKind } from '../../kernel/fd-table.js';
|
|
|
2
2
|
import type { SyncFsPosixBridge } from '../../realm/sync-fs-wire.js';
|
|
3
3
|
import { WasiFds, type WasiForkFd, type WasiKernel } from './wasi-fds.js';
|
|
4
4
|
import { WasiMemory } from './wasi-memory.js';
|
|
5
|
-
import type
|
|
5
|
+
import { type WasiSigmask } from './wasi-sigmask.js';
|
|
6
6
|
import type { WasiSignals } from './wasi-signals.js';
|
|
7
7
|
import type { ThreadEntry } from './wasix-fork.js';
|
|
8
8
|
export declare class WasiExit extends Error {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { SignalHooks } from '../process-signals.js';
|
|
1
|
+
import type { SignalHooks, SignalMasks } from '../process-signals.js';
|
|
2
2
|
export interface WasiSignalState {
|
|
3
3
|
callback?: string;
|
|
4
4
|
hooked?: true;
|
|
@@ -6,6 +6,7 @@ export interface WasiSignalState {
|
|
|
6
6
|
ignoring: number;
|
|
7
7
|
restarting: number;
|
|
8
8
|
uncaught: number;
|
|
9
|
+
nocldwait?: true;
|
|
9
10
|
}
|
|
10
11
|
export declare class WasiSignals implements SignalHooks {
|
|
11
12
|
private exports;
|
|
@@ -19,6 +20,7 @@ export declare class WasiSignals implements SignalHooks {
|
|
|
19
20
|
private ignoring;
|
|
20
21
|
private restarting;
|
|
21
22
|
private defaults;
|
|
23
|
+
private nocldwait;
|
|
22
24
|
private readonly fallBack;
|
|
23
25
|
private readonly onKilled;
|
|
24
26
|
constructor(fallBack: (sig: number) => void, onKilled?: (code: number) => void);
|
|
@@ -29,12 +31,7 @@ export declare class WasiSignals implements SignalHooks {
|
|
|
29
31
|
disposition(sig: number, disposition: number, flags: number): number;
|
|
30
32
|
snapshot(): WasiSignalState;
|
|
31
33
|
restore(state: WasiSignalState): void;
|
|
32
|
-
masks():
|
|
33
|
-
caught: number;
|
|
34
|
-
ignored: number;
|
|
35
|
-
restart: number;
|
|
36
|
-
defaults?: number;
|
|
37
|
-
} | null;
|
|
34
|
+
masks(): SignalMasks | null;
|
|
38
35
|
raise(sig: number): void;
|
|
39
36
|
muted(fd: number, data: Uint8Array): boolean;
|
|
40
37
|
raised(sig: number): boolean;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ai-ecoverse/slicc-kernel",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.108.1",
|
|
4
4
|
"description": "SLICC's wasm-realm kernel: run Emscripten programs in the browser against OPFS, with fork, spawn, pipes and waitpid",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "Apache-2.0",
|