interplane.Get Omega
Read in your language

aien-train

AIEN training programme: language-model history, GB10 constraints and the route to training on the project engine. Plans and runnable checks are distinguished.

Brought by drakestapleton

branch main Branches Tags History

aien-train / evidence / ECOSYSTEM6 / ref32-review / mul-red.om

50 lines · 1439 bytes Raw Blame History
1note Missing multiply behavior, baseline must fail runtime assertions.
2fn mul32 a ulong b ulong to ulong
3ret 0
4end
5note SPDX-License-Identifier: AGPL-3.0-only
6global failed ulong 1
7global tested ulong 1
8global line uchar 48
9fn report ok bool to void
10id = add get tested 0 1
11put tested 0 id
12put line 0 48
13put line 1 uchar add 48 rem div id 100 10
14put line 2 uchar add 48 rem div id 10 10
15put line 3 uchar add 48 rem id 10
16put line 4 32
17put line 5 48
18if not ok
19put line 5 49
20put failed 0 add get failed 0 1
21end
22put line 6 10
23w = write 1 line 0 7
24if ne w 7
25exit 74
26end
27end
28note Binary32 multiply RNE. Expected bits independently checked with IEEE host oracle.
29note All NaNs canonicalized to positive quiet NaN; gradual underflow; signed zero.
30fn main to int
31report eq mul32 1065353216 1073741824 1073741824
32report eq mul32 3212836864 1073741824 3221225472
33report eq mul32 0 3212836864 2147483648
34report eq mul32 2147483648 3212836864 0
35report eq mul32 2139095040 0 2143289344
36report eq mul32 2139095040 3212836864 4286578688
37report eq mul32 2143289345 1065353216 2143289344
38report eq mul32 1 1065353216 1
39report eq mul32 8388608 1056964608 4194304
40report eq mul32 8388607 1073741824 16777214
41report eq mul32 2139095039 1073741824 2139095040
42report eq mul32 1069547520 1069547520 1074790400
43report eq mul32 1065353217 1065353217 1065353218
44report eq mul32 1 1056964608 0
45report eq mul32 3 1056964608 2
46if ne get failed 0 0
47ret 1
48end
49ret 0
50end