@ai-ecoverse/slicc-kernel 1.108.3 → 1.108.4
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 +3 -3
- package/dist/kernel-worker.js +15 -3
- package/dist/kernel-worker.js.map +2 -2
- package/dist/node-process-worker.js +58 -25
- package/dist/node-process-worker.js.map +3 -3
- package/dist/node.js +15 -3
- package/dist/node.js.map +2 -2
- package/dist/process-worker.js +58 -25
- package/dist/process-worker.js.map +3 -3
- package/dist/types/kernel/process.d.ts +3 -0
- package/dist/types/process/wasi/wasi-fds.d.ts +1 -0
- package/dist/types/process/wasi/wasi-files.d.ts +2 -0
- package/dist/types/process/wasi/wasi-host.d.ts +1 -0
- package/package.json +1 -1
package/dist/node.js
CHANGED
|
@@ -6435,7 +6435,7 @@ function satisfies(version, range2) {
|
|
|
6435
6435
|
}
|
|
6436
6436
|
|
|
6437
6437
|
// src/version.ts
|
|
6438
|
-
var KERNEL_VERSION = true ? "1.108.
|
|
6438
|
+
var KERNEL_VERSION = true ? "1.108.4" : "0.0.0-dev";
|
|
6439
6439
|
var OS_RELEASE = "6.0.0-slicc";
|
|
6440
6440
|
function procVersion() {
|
|
6441
6441
|
return `Linux version ${OS_RELEASE} (slicc-kernel ${KERNEL_VERSION}) #1 SMP PREEMPT_DYNAMIC
|
|
@@ -12338,7 +12338,9 @@ function normalize(path) {
|
|
|
12338
12338
|
var RING2 = 8;
|
|
12339
12339
|
var RING_SIZE2 = 64;
|
|
12340
12340
|
var SLOT2 = 3;
|
|
12341
|
-
var
|
|
12341
|
+
var FD_RING = RING2 + RING_SIZE2 * SLOT2;
|
|
12342
|
+
var FD_RING_SIZE = 64;
|
|
12343
|
+
var SHARED_IDS_BYTES = (FD_RING + FD_RING_SIZE * 2) * 4;
|
|
12342
12344
|
|
|
12343
12345
|
// src/process/wasi/wasi-procfs.ts
|
|
12344
12346
|
var DIR_MODE = 16749;
|
|
@@ -16778,6 +16780,16 @@ var WasmProcess = class {
|
|
|
16778
16780
|
sendDeath(target, sig) {
|
|
16779
16781
|
void Promise.resolve(this.options.kill?.(target, sig)).catch(() => void 0);
|
|
16780
16782
|
}
|
|
16783
|
+
selfKill(req) {
|
|
16784
|
+
if (req.dry) return Promise.resolve(this.spares(req.sig));
|
|
16785
|
+
return this.killSelf(req.sig, req.target, req.probe);
|
|
16786
|
+
}
|
|
16787
|
+
spares(sig) {
|
|
16788
|
+
const { caught, ignored } = this.signalMasks();
|
|
16789
|
+
const bit = isSignal(sig) ? sigbit(sig) : 0;
|
|
16790
|
+
const answer = (ignored & bit) !== 0 ? "ignore" : (caught & bit) !== 0 ? "spare" : "terminate";
|
|
16791
|
+
return { ok: true, kind: "json", json: answer };
|
|
16792
|
+
}
|
|
16781
16793
|
async killSelf(sig, target, probe2) {
|
|
16782
16794
|
if (!this.options.exitSignal) throw new KernelError("ENOSYS");
|
|
16783
16795
|
if (!isSignal(sig) || defaultAction(sig) !== "terminate") throw new KernelError("EINVAL");
|
|
@@ -17679,7 +17691,7 @@ var WasmProcess = class {
|
|
|
17679
17691
|
this.options.exitNow(req.status & 255);
|
|
17680
17692
|
return DYING;
|
|
17681
17693
|
case "proc-kill-self":
|
|
17682
|
-
return this.
|
|
17694
|
+
return this.selfKill(req);
|
|
17683
17695
|
case "proc-identity":
|
|
17684
17696
|
return { ok: true, kind: "json", json: await this.options.identity?.() ?? null };
|
|
17685
17697
|
case "proc-exec": {
|