Project Campaign
This document turns the next differential-testing wave into a concrete
execution plan inside the repository. fortsh remains the flagship proof
point, but it is no longer the only real-world target we use to evaluate
armfortas.
The corresponding runner/catalog lives in bencch and
is exposed through:
cargo run -p afs-tests -- projects list
cargo run -p afs-tests -- projects run --project fortbite --armfortas-bin ./target/release/armfortas
Objectives
- Prioritize compiler coverage first, with some C interop allowed.
- Use native project build systems before inventing custom harnesses.
- Compare
armfortasagainstflang-newon real codebases, not only reduced reproducers. - Classify every armfortas-only divergence before accepting it as a project bug.
- Seed a reusable Fortran app/systems library surface from repeated patterns across the FortranGoingOnForty repos.
Benchmark Ladder
Current staged order:
fortbiteferpsniffertfortressfitfacsimileforttylater
Secondary targets worth keeping warm:
fuss- smaller git-oriented TUI with UTF-8 tree rendering and shell/workflow hooks
- good backup interactive target when we want less dependency noise than the editor/TUI stack
fgof-fs- filesystem/path library with dense native tests
- good for
.amod, packaging, and runtime I/O truthfulness
fgof-process- subprocess/process library with capture, timeout, and shell behavior tests
- good system-interop target without full application complexity
fgof-pty- PTY/session library with interactive subprocess and resize coverage
- good terminal-truthfulness target before the heavier TUI/editor programs
fgof-termios- terminal-mode helper library with raw/cbreak/echo and terminal-size coverage
- good low-noise tty truthfulness target before the heavier expect and line-edit stacks
fgof-lineedit- line editing state/history library for shells and REPL-style tools
- good focused target for interactive editing semantics without terminal-mode noise
fgof-watch- portable file-watching library with polling-backed watch-session semantics
- good low-dependency target for filesystem change detection and library packaging behavior
fgof-temp- temp-file, temp-directory, and atomic-write library with real filesystem lifecycle coverage
- good low-noise target for ownership, cleanup, and exact-text I/O truthfulness
fgof-cache- disk-cache library with sharding, stale pruning, and atomic text persistence
- good layered package target once
fgof-tempstays green
fgof-state- persistent state library with versioned document load/save and atomic replacement
- good layered package target for durable app/workspace state semantics after
fgof-temp
Current de-prioritized projects:
convolutionaero-emulationwasmfeducativekaraoPy
Those repos are still useful for spot checks, but they are too small or too specialized to drive the next compiler phase.
Differential Method
For each project:
- Build it cleanly with
armfortasandflang-new. - Use the project’s native build system first (
make,fpm,cmake). - If a project’s checked-in default flags are compiler-vendor-specific, keep the native build system and record the smallest override needed to reach a fair cross-compiler comparison.
- Record:
- build success/failure
- test success/failure
- runtime smoke behavior
- wall-clock compile time
- link/runtime crashes
- materially different warnings or stderr
- For interactive targets, keep the same feature toggles and build mode on both compilers.
- When behavior differs:
- reduce to the smallest project-local repro
- reduce again to a standalone compiler repro
- only then patch
armfortas
Use these buckets when summarizing each project:
Pure semantics/codegenCross-TU / .amod truthfulnessSystem / C interopInteractive / terminal behaviorPerformance
Acceptance Bar
The next campaign is considered successful when:
fortbite,ferp,sniffert,fortress, andfitall build under botharmfortasandflang-new- their native tests or smoke workflows run under both
- all armfortas-only failures are reduced and classified
facsimilebecomes the next flagship bring-up target after that smaller ladder is mostly green- no compiler fix lands without either:
- a standalone regression, or
- a project-local regression plus a documented reason no smaller repro exists
Library Seeding
The gap worth filling is not BLAS-style numerics. The real missing batteries are app/systems modules that C ecosystems take for granted.
Target module families:
fortargs- argument parsing, subcommands, help text, env fallback
fortpath- path join/split/normalize, cwd/home/temp helpers, directory walking basics
fortproc- subprocesses, env vars, pipes, signals, exit codes, platform wrappers
fortterm- ANSI styling, terminal size, raw mode, key decoding, screen redraw helpers
fortds- hash maps, deques, ring buffers, gap buffers, tries, lookup tables
fortconfig- config loading and precedence helpers for TOML/env/CLI layering
These libraries should be module-first packages, ideally fpm-friendly, with
minimal C wrappers only where system APIs demand them.
Library-Backed Sample Apps
Use the library surface to drive the second wave of realistic but controlled sample projects:
- grep-like search CLI on
fortargs+fortpath - file tree / disk usage explorer on
fortterm+fortpath - merge conflict resolver on
fortterm+ diff helpers - process runner / task launcher on
fortproc - HTTP/REST client only later, after the terminal/filesystem/process substrate is solid
Notes
fortshremains the current flagship proof that the compiler can build and run a large interactive program.- The
bencchproject ladder is intentionally staged so dependency-heavy targets likeforttydo not hide compiler bugs too early. - Success here is not “we built one more repo once.” Success is a repeatable, explainable differential story across multiple real Fortran applications.
View source
| 1 | # Project Campaign |
| 2 | |
| 3 | This document turns the next differential-testing wave into a concrete |
| 4 | execution plan inside the repository. `fortsh` remains the flagship proof |
| 5 | point, but it is no longer the only real-world target we use to evaluate |
| 6 | `armfortas`. |
| 7 | |
| 8 | The corresponding runner/catalog lives in [`bencch`](./bencch/README.md) and |
| 9 | is exposed through: |
| 10 | |
| 11 | ```bash |
| 12 | cargo run -p afs-tests -- projects list |
| 13 | cargo run -p afs-tests -- projects run --project fortbite --armfortas-bin ./target/release/armfortas |
| 14 | ``` |
| 15 | |
| 16 | ## Objectives |
| 17 | |
| 18 | - Prioritize compiler coverage first, with some C interop allowed. |
| 19 | - Use native project build systems before inventing custom harnesses. |
| 20 | - Compare `armfortas` against `flang-new` on real codebases, not only reduced |
| 21 | reproducers. |
| 22 | - Classify every armfortas-only divergence before accepting it as a project bug. |
| 23 | - Seed a reusable Fortran app/systems library surface from repeated patterns |
| 24 | across the FortranGoingOnForty repos. |
| 25 | |
| 26 | ## Benchmark Ladder |
| 27 | |
| 28 | Current staged order: |
| 29 | |
| 30 | 1. `fortbite` |
| 31 | 2. `ferp` |
| 32 | 3. `sniffert` |
| 33 | 4. `fortress` |
| 34 | 5. `fit` |
| 35 | 6. `facsimile` |
| 36 | 7. `fortty` later |
| 37 | |
| 38 | Secondary targets worth keeping warm: |
| 39 | |
| 40 | - `fuss` |
| 41 | - smaller git-oriented TUI with UTF-8 tree rendering and shell/workflow hooks |
| 42 | - good backup interactive target when we want less dependency noise than the editor/TUI stack |
| 43 | - `fgof-fs` |
| 44 | - filesystem/path library with dense native tests |
| 45 | - good for `.amod`, packaging, and runtime I/O truthfulness |
| 46 | - `fgof-process` |
| 47 | - subprocess/process library with capture, timeout, and shell behavior tests |
| 48 | - good system-interop target without full application complexity |
| 49 | - `fgof-pty` |
| 50 | - PTY/session library with interactive subprocess and resize coverage |
| 51 | - good terminal-truthfulness target before the heavier TUI/editor programs |
| 52 | - `fgof-termios` |
| 53 | - terminal-mode helper library with raw/cbreak/echo and terminal-size coverage |
| 54 | - good low-noise tty truthfulness target before the heavier expect and line-edit stacks |
| 55 | - `fgof-lineedit` |
| 56 | - line editing state/history library for shells and REPL-style tools |
| 57 | - good focused target for interactive editing semantics without terminal-mode noise |
| 58 | - `fgof-watch` |
| 59 | - portable file-watching library with polling-backed watch-session semantics |
| 60 | - good low-dependency target for filesystem change detection and library packaging behavior |
| 61 | - `fgof-temp` |
| 62 | - temp-file, temp-directory, and atomic-write library with real filesystem lifecycle coverage |
| 63 | - good low-noise target for ownership, cleanup, and exact-text I/O truthfulness |
| 64 | - `fgof-cache` |
| 65 | - disk-cache library with sharding, stale pruning, and atomic text persistence |
| 66 | - good layered package target once `fgof-temp` stays green |
| 67 | - `fgof-state` |
| 68 | - persistent state library with versioned document load/save and atomic replacement |
| 69 | - good layered package target for durable app/workspace state semantics after `fgof-temp` |
| 70 | |
| 71 | Current de-prioritized projects: |
| 72 | |
| 73 | - `convolution` |
| 74 | - `aero-emulation` |
| 75 | - `wasm` |
| 76 | - `feducative` |
| 77 | - `karaoPy` |
| 78 | |
| 79 | Those repos are still useful for spot checks, but they are too small or too |
| 80 | specialized to drive the next compiler phase. |
| 81 | |
| 82 | ## Differential Method |
| 83 | |
| 84 | For each project: |
| 85 | |
| 86 | - Build it cleanly with `armfortas` and `flang-new`. |
| 87 | - Use the project’s native build system first (`make`, `fpm`, `cmake`). |
| 88 | - If a project’s checked-in default flags are compiler-vendor-specific, keep the |
| 89 | native build system and record the smallest override needed to reach a fair |
| 90 | cross-compiler comparison. |
| 91 | - Record: |
| 92 | - build success/failure |
| 93 | - test success/failure |
| 94 | - runtime smoke behavior |
| 95 | - wall-clock compile time |
| 96 | - link/runtime crashes |
| 97 | - materially different warnings or stderr |
| 98 | - For interactive targets, keep the same feature toggles and build mode on both |
| 99 | compilers. |
| 100 | - When behavior differs: |
| 101 | - reduce to the smallest project-local repro |
| 102 | - reduce again to a standalone compiler repro |
| 103 | - only then patch `armfortas` |
| 104 | |
| 105 | Use these buckets when summarizing each project: |
| 106 | |
| 107 | - `Pure semantics/codegen` |
| 108 | - `Cross-TU / .amod truthfulness` |
| 109 | - `System / C interop` |
| 110 | - `Interactive / terminal behavior` |
| 111 | - `Performance` |
| 112 | |
| 113 | ## Acceptance Bar |
| 114 | |
| 115 | The next campaign is considered successful when: |
| 116 | |
| 117 | - `fortbite`, `ferp`, `sniffert`, `fortress`, and `fit` all build under both |
| 118 | `armfortas` and `flang-new` |
| 119 | - their native tests or smoke workflows run under both |
| 120 | - all armfortas-only failures are reduced and classified |
| 121 | - `facsimile` becomes the next flagship bring-up target after that smaller |
| 122 | ladder is mostly green |
| 123 | - no compiler fix lands without either: |
| 124 | - a standalone regression, or |
| 125 | - a project-local regression plus a documented reason no smaller repro exists |
| 126 | |
| 127 | ## Library Seeding |
| 128 | |
| 129 | The gap worth filling is not BLAS-style numerics. The real missing batteries |
| 130 | are app/systems modules that C ecosystems take for granted. |
| 131 | |
| 132 | Target module families: |
| 133 | |
| 134 | - `fortargs` |
| 135 | - argument parsing, subcommands, help text, env fallback |
| 136 | - `fortpath` |
| 137 | - path join/split/normalize, cwd/home/temp helpers, directory walking basics |
| 138 | - `fortproc` |
| 139 | - subprocesses, env vars, pipes, signals, exit codes, platform wrappers |
| 140 | - `fortterm` |
| 141 | - ANSI styling, terminal size, raw mode, key decoding, screen redraw helpers |
| 142 | - `fortds` |
| 143 | - hash maps, deques, ring buffers, gap buffers, tries, lookup tables |
| 144 | - `fortconfig` |
| 145 | - config loading and precedence helpers for TOML/env/CLI layering |
| 146 | |
| 147 | These libraries should be module-first packages, ideally `fpm`-friendly, with |
| 148 | minimal C wrappers only where system APIs demand them. |
| 149 | |
| 150 | ## Library-Backed Sample Apps |
| 151 | |
| 152 | Use the library surface to drive the second wave of realistic but controlled |
| 153 | sample projects: |
| 154 | |
| 155 | - grep-like search CLI on `fortargs` + `fortpath` |
| 156 | - file tree / disk usage explorer on `fortterm` + `fortpath` |
| 157 | - merge conflict resolver on `fortterm` + diff helpers |
| 158 | - process runner / task launcher on `fortproc` |
| 159 | - HTTP/REST client only later, after the terminal/filesystem/process substrate |
| 160 | is solid |
| 161 | |
| 162 | ## Notes |
| 163 | |
| 164 | - `fortsh` remains the current flagship proof that the compiler can build and |
| 165 | run a large interactive program. |
| 166 | - The `bencch` project ladder is intentionally staged so dependency-heavy |
| 167 | targets like `fortty` do not hide compiler bugs too early. |
| 168 | - Success here is not “we built one more repo once.” Success is a repeatable, |
| 169 | explainable differential story across multiple real Fortran applications. |