Is a source-built TLS startup test available to take on? #75

Closed
opened 2026-11-21 15:36:56 +00:00 by sof9816 · 3 comments
sof9816 commented 2026-11-21 15:36:56 +00:00 (Migrated from github.com)
Contributor

Imported from R0Y00/Xbox2Windows. Originally posted by sof9816 on 2026-11-21T15:36:56Z.


@R0Y00, is anyone already working on a TLS callback order test for the native loader? I checked the public issues and PRs, including #46, #49 and #65, and saw that TLS callbacks and entry-point calls are still listed as open in docs/experiments.md.

I’d like to take one small Windows fixture that records whether a TLS process-attach callback runs before the entry point. I’d use the Windows loader as the reference and report the native mapper’s behavior in a focused test. The fixture would use repository-owned source only. I can test it on Windows 11 x64 with MSVC and Python 3.13.

Could you confirm whether the test is free to take on, or point me to any work already underway?

AI-assisted drafting and local testing.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:issue:6530847324 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/issues/76). Originally posted by [sof9816](https://github.com/sof9816) on 2026-11-21T15:36:56Z. --- @R0Y00, is anyone already working on a TLS callback order test for the native loader? I checked the public issues and PRs, including #46, #49 and #65, and saw that TLS callbacks and entry-point calls are still listed as open in `docs/experiments.md`. I’d like to take one small Windows fixture that records whether a TLS process-attach callback runs before the entry point. I’d use the Windows loader as the reference and report the native mapper’s behavior in a focused test. The fixture would use repository-owned source only. I can test it on Windows 11 x64 with MSVC and Python 3.13. Could you confirm whether the test is free to take on, or point me to any work already underway? AI-assisted drafting and local testing.
Leyukaka commented 2026-11-24 06:47:34 +00:00 (Migrated from github.com)
Author
Contributor

Imported from R0Y00/Xbox2Windows. Originally posted by Leyukaka on 2026-11-21T15:41:12Z.


Hi, #78 covers exactly this: a source-built tls_route fixture with one TLS callback and an entry point. The test compares LoadLibraryW/FreeLibrary with pe_map on attach, on detach and when the entry point returns FALSE. Sorry for the overlap; I hadn't seen this issue when I opened it.

Areas that #78 still leaves open, in case one of them interests you:

  • implicit TLS data, a non-empty template that needs a slot in each thread's ThreadLocalStoragePointer;
  • DLL_THREAD_ATTACH/DETACH for threads created after mapping;
  • delay imports.

Reviews of #78 are welcome too, especially a run on Python 3.13, since I only tested on 3.14.

AI-assisted.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7065066567 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/issues/76#issuecomment-7065066567). Originally posted by [Leyukaka](https://github.com/Leyukaka) on 2026-11-21T15:41:12Z. --- Hi, #78 covers exactly this: a source-built `tls_route` fixture with one TLS callback and an entry point. The test compares `LoadLibraryW`/`FreeLibrary` with `pe_map` on attach, on detach and when the entry point returns FALSE. Sorry for the overlap; I hadn't seen this issue when I opened it. Areas that #78 still leaves open, in case one of them interests you: - implicit TLS data, a non-empty template that needs a slot in each thread's `ThreadLocalStoragePointer`; - `DLL_THREAD_ATTACH`/`DETACH` for threads created after mapping; - delay imports. Reviews of #78 are welcome too, especially a run on Python 3.13, since I only tested on 3.14. _AI-assisted._
R0Y00 commented 2026-11-24 06:47:35 +00:00 (Migrated from github.com)
Author
Contributor

Imported from R0Y00/Xbox2Windows. Originally posted by R0Y00 on 2026-11-21T15:46:13Z.


Thanks for offering to test on Windows 11. Could you independently run the source-built TLS comparison in #78 with MSVC and Python 3.13 and post the commit, Windows build and results there? The fixture covers attach, detach and a refused attach.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7065129333 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/issues/76#issuecomment-7065129333). Originally posted by [R0Y00](https://github.com/R0Y00) on 2026-11-21T15:46:13Z. --- Thanks for offering to test on Windows 11. Could you independently run the source-built TLS comparison in #78 with MSVC and Python 3.13 and post the commit, Windows build and results there? The fixture covers attach, detach and a refused attach.
R0Y00 commented 2026-11-24 06:47:36 +00:00 (Migrated from github.com)
Author
Contributor

Imported from R0Y00/Xbox2Windows. Originally posted by R0Y00 on 2026-11-21T16:22:54Z.


The source-built TLS comparison landed in #78 and passes Windows CI, including process attach, detach, refused attach and the unreadable-table controls. Thanks for volunteering. A Python 3.13 retest is still welcome on the merged commit.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7065603815 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/issues/76#issuecomment-7065603815). Originally posted by [R0Y00](https://github.com/R0Y00) on 2026-11-21T16:22:54Z. --- The source-built TLS comparison landed in #78 and passes Windows CI, including process attach, detach, refused attach and the unreadable-table controls. Thanks for volunteering. A Python 3.13 retest is still welcome on the merged commit.
Sign in to join this conversation.
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
R0Y00/Xbox2Windows#75
No description provided.