interplane.Get Omega
Read in your language

omega-mv

Omega: a language for verified programs, semantic identity and machine realization. Seed-born work and existing implementations have distinct provenance.

Brought by drakestapleton

branch main Branches Tags History

omega-mv / seed / qualification / om2 / sec / s5s7 / a5-exact.om

24 lines · 714 bytes Raw Blame History
1note SPDX-License-Identifier: Apache-2.0
2note contract 5 abstract, lines 131-150: dup32 with the exact constructor body (check erased),
3note open gives the ulong value, rotr is a 64-bit rotation equal to the dup of the 32-bit rotation
4note by n mod 32 (lines 140-141), xor of two dup32 values. stdout oracle exp/a5-exact.out (python3).
5om2
6abstract dup32 ulong ops rotr xor
7holds dup32 dup32
8fn dup32mk x uint to dup32
9ret seal dup32 or shl ulong x 32 ulong x
10end
11fn main to int
12d = dup32mk 0x89abcdef
13puth open d
14puth add open d 1
15puth open rotr d 0
16puth open rotr d 1
17puth open rotr d 8
18puth open rotr d 31
19puth open rotr d 32
20puth open rotr d 33
21puth open rotr d 63
22puth open xor d dup32mk 0x01234567
23ret 0
24end