amos 2f32624d3b Batch 18 (20261026-C-hwe-codegen-18): add 100 calibrated HWE code-gen tasks; pause production for rollout
100 tasks from the HWE arm-linux code-gen pool (outside the lk/man/pth
range given to batch 22), each with at least one independent
contract-edge defect and plain public docs. Claude reviewed 100/100
USABLE against current digests; no ID or source overlap with main or
batch 22. Difficulty is unmeasured.

progress.md records the wrap-up: all Codex sessions and Qwen schedulers
stopped for the user's rollout, Qwen results so far (57 HARD of 373),
and what is left on each batch branch.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-27 17:52:13 +08:00

59 lines
2.6 KiB
C++

#include "interlock.hpp"
#include <array>
#include <cstdint>
#include <iostream>
using namespace maskwrite;
int main()
{
std::array<Interlock, 2> banks;
Number instance, code;
std::array<Number, 5> a;
while (std::cin >> instance >> code >> a[0] >> a[1] >> a[2] >> a[3] >> a[4]) {
Interlock& bank = banks[static_cast<std::size_t>(instance)];
Status status = OK;
std::uint32_t value = 2779096485U;
Operation operation{-9, -9, 2779096485U, 2779096485U};
switch (code) {
case 0: status = bank.reset(); break;
case 1: status = bank.load(a[0], a[1]); break;
case 2: status = bank.begin(a[0]); break;
case 3: status = bank.stage(a[0], a[1], a[2], a[3], a[4]); break;
case 4: status = bank.capture(a[0]); break;
case 5: status = bank.commit(a[0]); break;
case 6: status = bank.abort(a[0]); break;
case 7: status = bank.word(a[0], value); break;
case 8: status = bank.prepared(a[0], a[1], value); break;
case 9: status = bank.changed(a[0], a[1], value); break;
case 10: status = bank.operation(a[0], operation); break;
case 11: break;
}
std::cout << static_cast<int>(status) << ' ' << value << ' '
<< operation.reg << ' ' << operation.kind << ' '
<< operation.mask << ' ' << operation.value;
State state = bank.state();
std::cout << ' ' << state.owner << ' ' << state.phase << ' '
<< state.count << ' ' << state.generation;
for (Number reg = 0; reg < 4; ++reg) {
std::uint32_t word = 2779096485U;
Status read = bank.word(reg, word);
std::cout << ' ' << static_cast<int>(read) << ' ' << word;
}
for (Number index = 0; index < 8; ++index) {
Operation entry{-9, -9, 2779096485U, 2779096485U};
Status read = bank.operation(index, entry);
std::cout << ' ' << static_cast<int>(read) << ' ' << entry.reg << ' '
<< entry.kind << ' ' << entry.mask << ' ' << entry.value;
}
for (Number reg = 0; reg < 4; ++reg) {
std::uint32_t prospective = 2779096485U;
std::uint32_t delta = 2779096485U;
Status prepared = bank.prepared(state.owner, reg, prospective);
Status changed = bank.changed(state.owner, reg, delta);
std::cout << ' ' << static_cast<int>(prepared) << ' ' << prospective
<< ' ' << static_cast<int>(changed) << ' ' << delta;
}
std::cout << '\n';
}
return 0;
}