Overview
| Comment: | Version v15u is included in typeparse.zip. Loops over a typed list no longer recreate their elements, and the "annotated" step shows performance gains across the board in the geometry benchmark. Difference compared to plain Tcl (10,000 points): calculation v15s v15u area / 3.4 / 2.2 perimeter / 2.7 / 1.9 bounding box / 6.7 / 3.7 contains_all / 3.6 / 2.6 Bézier / 2.7 / 2.4 For 10,000 points, an empty `foreach` loop improves from 2.6 ms to 0.24 ms (plain Tcl: 0.16 ms). The change affects two core files: `tclExecute.c` and `tclCmdAH.c`. These are included in the new `boucles-typees.patch` (typed-loops patch), which has been added to the end of `ORDRE.txt`. All checks pass: the 53 tests—including the new `t75_boucles_typees`—produce the same output as before the change; output remains identical whether the compact form is used or not; `valgrind` reports no issues in either mode; the full Tcl test suite shows the same 61 failures as in v15. I have updated `noyau/LISEZMOI.md`, `ANNOTATIONS.fr.md` (section 15), the `LISEZMOI.md` file for the geometry component, `REPRISE.md`, and the project schedule. Within the loops, the primary remaining overhead comes from path-based lookups (e.g., `$q(x)`), which take approximately 0.2 µs each, compared to 0.06 µs for an index-based lookup. This corresponds to point 2: implementing a cache at the point of the lookup within the bytecode. |
|---|---|
| Timelines: | family | ancestors | descendants | both | tip-764_tcl90 |
| Files: | files | file ages | folders |
| SHA3-256: |
92c0c64aa5a725423bb902d2e918217a |
| User & Date: | Florentis on 2026-10-24 13:16:58.062 |
| Other Links: | branch diff | manifest | tags |
Context
|
2026-10-24
| ||
| 13:29 | Point 2 is complete and documented. All that remains is to wait for Valgrind and the full Tcl test s... check-in: 4269a60689 user: Florentis tags: tip-764_tcl90 | |
| 13:16 | Version v15u is included in typeparse.zip. Loops over a typed list no longer recreate their elements... check-in: 92c0c64aa5 user: Florentis tags: tip-764_tcl90 | |
| 11:46 | The v15t version is in typeparse.zip. Point 1: `type def {-compact}pointC {…}` is accepted, and a... check-in: e5b7824c45 user: Florentis tags: tip-764_tcl90 | |
Changes
Modified generic/tclAnnotObj.c
from [9d49159916]
to [c051e54058].
[diff]
Modified generic/tclCmdAH.c
from [0a62adc520]
to [2a90f01806].
[diff]
Modified generic/tclExecute.c
from [4b61ef36b2]
to [59f7f003d2].
[diff]
Modified generic/tclTypedVar.c
from [d9a35bb8db]
to [af8fca6a8c].
[diff]
Modified generic/tclTypes.h
from [82572c05ed]
to [844c350cc9].
[diff]
Modified typeparse/REPRISE.md
from [b1b8e84861]
to [cfc31c9ab1].
[diff]
Modified typeparse/doc/ANNOTATIONS.fr.md
from [42da663539]
to [f3fe66369b].
[diff]
Modified typeparse/exemples/geometrie/LISEZMOI.md
from [e0883b17ae]
to [31d189d036].
[diff]
Modified typeparse/exemples/geometrie/bench.tcl
from [ebebd50abb]
to [8f0dbcc9e9].
[diff]
Modified typeparse/noyau/LISEZMOI.md
from [fd70889d6f]
to [40b10151d3].
[diff]
Modified typeparse/noyau/ORDRE.txt
from [8167bca376]
to [a36ccd4b56].
[diff]
Added typeparse/noyau/boucles-typees.patch version [1012a4272f].
Modified typeparse/tclAnnotObj.c
from [9d49159916]
to [c051e54058].
[diff]
Modified typeparse/tclTypedVar.c
from [d9a35bb8db]
to [af8fca6a8c].
[diff]
Modified typeparse/tclTypes.h
from [82572c05ed]
to [844c350cc9].
[diff]
Added typeparse/tests_tclsh/t75_boucles_typees.out version [8c38d5973f].
Added typeparse/tests_tclsh/t75_boucles_typees.tcl version [c068acf398].