What is counted, where it is published, and how to read it.
tools/progress.py scans core/libs/xdll/<library>/ (excluding tests/) through tools/anybox_scan.py:
- implemented: an
ABX_APIfunction definition whose body does not callAbxNotImplemented; - stub: an
ABX_APIdefinition whose body callsAbxNotImplemented; - forwarded: a
Name=dll.Targetline in the library'sForwards.def.
Comments, string and character literals are blanked before matching, so braces or names inside them do not count. The percentage is (implemented + forwarded) / declared. A count says nothing about whether a title runs; compatibility lives in the Game bring-up discussions.
Progress also counts what AnyBox does not declare yet, from the export inventories and title needs records:
- not declared: a function a library's DLLs are known to export or titles import, with no declaration.
known = declared + not declared, andknownPercentis done of known. - export list not known yet (
*on the map): no inventory or needs record covers the library's DLLs, so its known total is just what it declares. - DLLs with no library (
unserved): DLLs that titles import or inventories list, that no library serves and Windows does not provide. Each is a dashed red tile on the map and a row on the page with thestubgen.py --new-librarycommand that starts it.
python tools/progress.py out/ # progress.json, progress.html, progress.svg, badge-libraries.svg
python tools/progress.py --module xgameruntime
python tools/progress.py --json
python tools/progress.py --compare base.json head.json # the pull request comment; empty when no library changed
python tools/progress.py --root ../other-checkout --json # count another checkout with this version of the tool
tools/progress_history.py measures the first-parent history: one point per UTC day, the last commit of that day, read through git show with today's counting rules. It writes history.json, history.svg and history.html. --cache <file> keeps measured commits between runs.
- Pages workflow: on pushes to
mainthat touchcore/libs, the tools or the docs, it publishes the progress page, map, badge and history to GitHub Pages. - Progress report workflow: on pull requests, it counts the base (
--root) and the merged head with the same version of the tool and compares them. Progress comment posts the result on the pull request as one comment, updated on each push and deleted when the change no longer touches a library: the new percentage and its change, the functions implemented, forwarded, newly stubbed, removed or no longer done, and a table of the changed libraries. It runs in a separate workflow because pull requests from forks get a read-only token.
Progress counts only what AnyBox already declares. Three tools find everything else and rank it, without implementing anything:
tools/lib_inventory.pylists every export of import libraries (.lib, short format) or DLLs, and stores the names indocs/inventorywith--json. The inventory from the public PC GDK is committed; its README says how it was made.tools/import_audit.py--needs docs/needs/<TitleId>.jsonstores what one title imports, minus host and bundled DLLs, indocs/needs.tools/needs.pymerges both with the current library scan:- every known function, with its DLL, the library that serves it, its status and the titles that import it, sorted so the functions most titles need and AnyBox lacks come first;
- per DLL: known exports, how many titles need it, declared, done;
- per title: how many of its imports are done, and its next blockers.
python tools/needs.py site/ # needs.json, needs.html; prints a Markdown summary
python tools/stubgen.py --from-audit site/needs.json # declares every absent function as a stub
The Pages workflow publishes needs.html next to the progress page.
tools/import_audit.py reads a title's PE files and classifies every import:
| Status | Meaning |
|---|---|
| implemented | the routed library implements it |
| forwarded | the routed library forwards it to the host |
| stub | declared; calling it stops the title with a run report |
| absent | the DLL is routed but the function is not declared; stubgen.py --from-audit adds it |
| bundled | the title ships the DLL itself |
| host | desktop Windows provides the DLL |
| unrouted | nothing serves the DLL; start a library with stubgen.py --new-library |
It exits with 1 when something is absent or unrouted (--strict-stubs also fails on stubs).