Skip to content

Various fixes to set thread name - #13625

Merged
gasche merged 1 commit into
ocaml:trunkfrom
MisterDA:set-thread-name-fixes
Nov 20, 2024
Merged

gasche merged 1 commit into
ocaml:trunkfrom
MisterDA:set-thread-name-fixes

Conversation

@MisterDA

Copy link
Copy Markdown
Contributor
  • a Debian code search shows that projects check at configure-time for the prctl symbol, not the declaration.
    https://codesearch.debian.net/search?q=HAVE_PRCTL
    https://codesearch.debian.net/search?q=HAVE_DECL_PRCTL
  • only check for SetThreadDescription declaration if the symbol has been found;
  • fix SetThreadDescription missing declaration to include __declspec(import) and __cdecl (for x86). The declaration should have been copied from the header rather than from the documentation, which is missing these bits;
  • fix caml/osdeps.h include style.

cc @toots, @gasche who (resp.) authored and reviewed #13504.

- a Debian code search shows that projects check at configure-time for
  the prctl symbol, not the declaration.

  https://codesearch.debian.net/search?q=HAVE_PRCTL
  https://codesearch.debian.net/search?q=HAVE_DECL_PRCTL

- only check for SetThreadDescription declaration if the symbol has
  been found;

- fix SetThreadDescription missing declaration to include
  __declspec(import) and __cdecl (for x86). The declaration should
  have been copied from the header rather than from the documentation,
  which is missing these bits;

- fix caml/osdeps.h include style.
@gasche

gasche commented Nov 20, 2024

Copy link
Copy Markdown
Member

I started a precheck job number 994. I'm ignorant of the configure details but I trust you on those, and will be happy to merge if the CI is itself happy.

@shindere

shindere commented Nov 20, 2024 via email

Copy link
Copy Markdown
Contributor

@gasche

gasche commented Nov 20, 2024

Copy link
Copy Markdown
Member

Precheck is happy, let's merge when AppVeyor also agrees.

@toots toots left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me, thanks for the follow-up!

@gasche
gasche merged commit 6c4dac5 into ocaml:trunk Nov 20, 2024
@MisterDA
MisterDA deleted the set-thread-name-fixes branch November 20, 2024 15:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants