Hi gr, thanks for the feedback!
I took a closer look at the size question. From fada98b1 to win_arm64_reviewable the branch is currently about: 73 files changed, 9232 insertions(+), 358 deletions(-) So net roughly +8870 lines. For comparison, your arm64-win32 reference branch is about: 48 files changed, 5202 insertions(+), 578 deletions(-) So net roughly +4620 lines. However, I think the important point is that your arm64-win32 branch is not simply “the same result with less code”, but closer to a compacted snapshot of an earlier stage of the same Windows ARM64 work. In other words, a large part of the current size difference is not just history noise, but functionality and validation that was added later. The reason is that a large part of the extra size is not just noise, but actual functionality and coverage that is beyond the smaller subset. The “more code” currently covers in particular: fuller Windows ARM64 hosted `-run` support `-run` argv/wargv/env/wenv handling stdin and exit-path coverage for `-run` nested `tcc -run tcc.c ... -run ...` coverage, including `tests/test2` and `tests/test3` Windows ARM64 backtrace coverage ARM64 libtcc context save/restore coverage PE/alignment and Win32 runtime smoke tests broader GNU-style ARM64 inline asm support, including more operand/constraint/clobber handling and additional inline asm validation tests the Windows-specific reference outputs used by the test suite One especially large part is the two reference files: tests/test.ref.win32-arm64 tests/test.ref.win32-x86_64-ucrt Those two are mostly the same. My estimate is with the current behavior preserved, I can probably reduce the branch somewhat further, but the realistic floor is still much closer to ~+7000 than to ~+4000 to get down near your target, I would likely have to cut scope, not just rewrite smaller So I think the choice is roughly this: Keep the current behavior and test coverage. Then I can still try to trim the branch further, but not to half its current net size. Aim for the smaller upstreamable subset closer to your arm64-win32 branch. Then I would deliberately drop or postpone part of the current runtime/test/validation surface and keep only the minimal core needed for the port. I am fine with either direction, but I think it is better to say this explicitly rather than pretend that “same features, same tests, half the code” is easy here. If your preference is the smaller subset, I can work toward that and split the omitted parts into later follow-up work. Cheers, Ben > On 6 Apr 2026, at 01:45, grischka <[email protected]> wrote: > > On April 5, 2026 1:07:33 PM UTC, Benjamin Oldenburg > <[email protected]> wrote: >> Hi gr, >> >> I rewrote the history on a new review branch: >> >> https://github.com/bold84/tinycc/tree/win_arm64_reviewable >> [...] >> How to proceed? I seem to not be able to push to the mob branch… 🥺 > > Well, in this specific case I think this piece of work could still benefit > from r9eview before being pushed on mob anyway. > > For example: > git diff --shortstat mob win_arm64_reviewable > currently gives: > 73 files changed, 9182 insertions(+), 499 deletions(-) > > Which is about +8700 lines net. > > Now I believe this could be safely reduced to about the half of it, say +4000 > lines. > > (After all, tinycc is all about supporting features with the least possible > amount of code) > > I will however not have time to do this within the next 2 months. If in > between you feel to add or change something on your branch, no problem at all. > > Maybe AI could do that too. Like: "Now give me same results with only half of > the code plus still readable by humans, plus running the test suite on > GHActions, green, please..." ;) > > Thanks, > > -- grischka > > >> >> Some personal context on why I ended up doing the work here: >> >> My original goal was to get OpenCode running on Windows ARM64, which first >> led me to work on the Bun side. I submitted that work there. Instead of >> discussing it normally, the maintainer took that work, opened a separate PR, >> and merged it under his own name. Several of those commits were direct >> one-to-one copies of patches I had already authored and submitted. If >> useful, I can point to the corresponding commit pairs. >> >> Once that happened, I had no interest in continuing to contribute the TCC >> side through Bun’s fork, because I did not want to spend more time preparing >> another PR there only to watch it get consumed in the same way again. By >> then I had already realized that Bun was only half of the problem anyway, >> because TCC also needed proper Windows ARM64 support. >> >> So I made a deliberate decision not to continue downstream at Bun, but to >> contribute the compiler work at the actual upstream source instead. That is >> why I came to TinyCC directly and why I cleaned up the history here for >> review. >> >> I enjoy saying openly that I used OpenAI Codex, specifically the GPT-5.4 >> model, heavily while developing and validating this contribution. Claude >> Opus just couldn’t do it. So there is a certain irony in watching code >> developed that way later getting merged downstream by Bun, which is now part >> of Anthropic. 🤓 >> >> In any case, the important part is that the work exists upstream in the >> right place. >> >> Greetings, >> >> Ben >> >>> On 5 Apr 2026, at 01:07, Benjamin Oldenburg >>> <[email protected]> wrote: >>> >>> Ah.. “success” means built without warnings and all tests pass. >>> >>>> On 5 Apr 2026, at 01:07, Benjamin Oldenburg >>>> <[email protected]> wrote: >>>> >>>> Hi gr, >>>> >>>> alright. I will rewrite the history accordingly. >>>> >>>> The current state for >>>> https://github.com/bold84/tinycc/tree/win_arm64_clean : >>>> >>>> - arm64-win32 >>>> - Clang: success >>>> - MinGW GCC: not run >>>> - MSVC cl: success >>>> - x86_64-win32 >>>> - Clang: not run >>>> - MinGW GCC: success >>>> - MSVC cl: success >>>> Linux x86_64 >>>> - GCC: success >>>> - Clang: not installed >>>> Linux aarch64 >>>> - GCC: success >>>> - Clang: not installed >>>> macOS ARM64 (Darwin) >>>> - Clang: success >>>> >>>> Any other targets that need to be green? >>>> >>>> Kind regards, >>>> >>>> Ben >>>> >>>> >>>>> On 5 Apr 2026, at 00:52, grischka <[email protected]> wrote: >>>>> >>>>> On April 4, 2026 11:10:11 AM UTC, Benjamin Oldenburg >>>>> <[email protected]> wrote: >>>>>> I can complete the implementation in >>>>>> https://github.com/bold84/tinycc/tree/win_arm64_clean if there’s a >>>>>> chance it will actually be merged. >>>>> >>>>> Hi Ben, >>>>> sure it will, great work. >>>>> >>>>> It would make sense though if we could somewhat compress the history to >>>>> say less than 10 commits each addressing a theme such as for example >>>>> generator, asm, runtime, symbolic replacement, etc. (while omitting >>>>> unrelated whitespace changes and some stuff that we maybe dont really >>>>> need also). Just a suggestion though ;) >>>>> >>>>> Some first approach of mine here: >>>>> https://github.com/gr8001/tinycc/tree/arm64-win32 >>>>> >>>>> Greetings, >>>>> -- gr >>>>> >>>>>> >>>>>> Kind regards, >>>>>> >>>>>> Ben >>>>>> >>>>>> >>>> >>> >>
_______________________________________________ Tinycc-devel mailing list [email protected] https://lists.nongnu.org/mailman/listinfo/tinycc-devel
