interplane.Get Omega
Read in your language

aienux

Aienux, the AienOS kernel: boot, scheduling, IPC and capability boundaries. Pre-alpha; host, emulator and physical evidence are labelled separately.

Brought by drakestapleton

branch main Branches Tags History

aienux / evidence / allen-omega-L694 / L748 / independent-review / raw / memory-restore-numbered.txt

51 lines · 1155 bytes Raw Blame History
1 370 if lt get St 2 2
2 371 put St 2 add get St 2 1
3 372 end
4 373 ret true
5 374 end
6 375 note Load each copy once into Unit. Caller resets St and calls loadcopy0,1.
7 376 fn loadbeg to void
8 377 for i ulong 3
9 378 put St i 0
10 379 end
11 380 put Load 0 0
12 381 end
13 382 fn loadcopy slot ulong to bool
14 383 if gt slot 1
15 384 ret false
16 385 end
17 386 if ne and get Load 0 shl ulong 1 slot 0
18 387 ret false
19 388 end
20 389 if not memvalid
21 390 ret false
22 391 end
23 392 put Load 0 or get Load 0 shl ulong 1 slot
24 393 put St 2 add get St 2 1
25 394 if gt get64 16 get St 0
26 395 b = memdec
27 396 put St 0 get Md 0
28 397 put St 1 slot
29 398 end
30 399 ret true
31 400 end
32 401 note Note transaction completes before the parent copy may publish its count.
33 402 fn nbegin to bool
34 403 if or ne get Nt 0 0 ne get Tx 0 0
35 404 ret false
36 405 end
37 406 if not noteenc
38 407 ret false
39 408 end
40 409 put Nt 1 get Ns 1
41 410 put Nt 0 1
42 411 ret true
43 412 end
44 413 fn nwrite ok bool to bool
45 414 if ne get Nt 0 1
46 415 ret false
47 416 end
48 417 if not ok
49 418 put Nt 0 0
50 419 ret false
51 420 end