Added bash A profile update scripts and restored ports_arch as their source - #592
Merged
fdesbiens merged 1 commit intoAug 9, 2026
Merged
Conversation
fdesbiens
force-pushed
the
fix/armv7a-armv8a-source-sync
branch
from
August 9, 2026 14:45
ccb40fe to
2703db4
Compare
…source The ARMv7-A and ARMv8-A ports are generated by update.ps1, which needs PowerShell, so the cortex-a job in ports_arch_check ran on a Windows image and nobody could reproduce it locally on Linux. Add update.sh beside each update.ps1, with the same cores, compilers, copy sets and patches, and move the job to the same Linux image as everything else. The bash scripts were checked against the PowerShell ones by comparing what each reports as drifted. They agree exactly on the 63 files the Windows job last reported, and differ on 12 more, which turn out to be a defect in update.ps1 rather than in the port. Its two .cproject patterns are written as 'value=`"cortex-a7`"' with backticks that survive into the pattern, so that replacement has never matched, while the neighbouring Cortex-A7.NoFPU pattern has no backticks and always worked. The result is that the AC6 example builds for the A5, A8, A9, A12, A15 and A17 cores name cortex-a7 as their CPU while their FPU string is correct. The bash scripts do what the PowerShell ones intended, so regenerating corrects those twelve files. Restore ports_arch as the source for the rest. The implementation of _tx_thread_smp_time_get from eclipse-threadx#555 was applied to the twenty four generated SMP ports and never to ports_arch, which still held MOV x0, #0 with a FIXME comment, so regenerating would have replaced a working generic timer read with a stub. That implementation now lives in the source. The remaining differences are cosmetic and resolve in favour of the source: a trailing blank line in 38 copies of tx_thread_schedule.S and comment spacing in one tx_port.h. Note that the Cortex-A VFP fix is already present in ports_arch and was never at risk, contrary to what the description of the port consistency checks change said before this was measured. Extend scripts/check_ports.sh to run the A profile generators too, and make it fail when a generator fails or is missing rather than reporting a clean tree, which would have been a false pass. Pin every workflow to ubuntu-24.04. ubuntu-latest already resolves to that image, so nothing changes today, but a future migration becomes a deliberate commit rather than something that happens underneath the -m32 builds. Assisted-by: Claude Code (Opus 5) <noreply@anthropic.com>
fdesbiens
force-pushed
the
fix/armv7a-armv8a-source-sync
branch
from
August 9, 2026 14:52
2703db4 to
f5a4707
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Gives the ARMv7-A and ARMv8-A ports the same bash tooling the M profile has, restores
ports_archas their source, and moves thecortex-aCI job off Windows.Stacked on #591. Merge #590 and #591 first.
Bash equivalents of update.ps1
update.shsits beside eachupdate.ps1, with the same cores, compilers, copy sets and patches.--copy-example,--copy-validation-testand--copy-regression-testare accepted and ignored, exactly as in the PowerShell version, where they are declared but never consulted, so both take the same command line.The two were compared by what each reports as drifted, against the last Windows run of the job. They agree exactly on all 63 files, and the bash version reports 12 more.
Those 12 files are a bug in update.ps1
The ARMv7-A patch table writes its two
.cprojectpatterns differently:The shipped files show precisely that split:
cortex_a5/ac6value="cortex-a7"Cortex-A5.NoFPUcortex_a9/ac6value="cortex-a7"Cortex-A9.NoFPUSo the AC6 Eclipse example builds for six Cortex-A cores have been naming
cortex-a7as their CPU since the script was written. ARMv8-A uses plain double quotes and works, which is why the bash version matched it perfectly. The bash scripts do what the PowerShell ones intended, so regenerating corrects those twelve files.Restoring the source
One genuine revert hazard, the same shape as #590:
_tx_thread_smp_time_gethad been implemented in the generated ports only. #555 replaced the stub with a real generic timer read in all 24 SMP ports, but never touchedports_arch/ARMv8-A/threadx_smp/common/src/tx_thread_smp_time_get.S, which still held:Regenerating would have put that stub back in every ARMv8-A SMP port, replacing a working timer read. The implementation now lives in the source.
The rest is cosmetic and resolves in favour of the source, since these ports are generated: a trailing blank line removed from 38 copies of
tx_thread_schedule.S, and comment spacing in onetx_port.h.Correction to something I said on #591: I attributed the
tx_thread_schedule.Sdrift to the Cortex-A VFP fix and said regeneration would revert it. Measuring it showed otherwise. That fix is already inports_arch, was never at risk, and the drift in those 38 files is whitespace. The SMP timer above is the real hazard. #591's description has been corrected.CI
cortex-ajob moves fromwindows-latesttoubuntu-24.04and runs the bash scripts. It was the only job needing a Windows image, and only because of the tooling.ubuntu-24.04.ubuntu-latestalready resolves to that image, so nothing changes today; it means a future runner migration is a deliberate commit rather than something that happens underneath the-m32builds.scripts/check_ports.shnow runs the A profile generators too, so one local command covers both families.A flaw found in the checker itself
While testing,
check_ports.shreported a clean pass on a tree where the generators were absent: their failure was swallowed by the output redirect, so nothing regenerated and nothing drifted. A check that goes green when it did not run is worse than no check. Generator failures are now caught and reported:Verification
check_ports.shpasses and the generators are idempotent..cprojectCPU option lines across six cores, theFIXMEstub in the source, and one comment's spacing. Nothing else is lost.