Skip to content

Conversation

@Sonicadvance1
Copy link
Member

On top of the previous PRs.

There is only one registration that I've not been able to track down why
it happens, but it is something to do with std::ostream. This just
ensures in CI that we don't ever register anymore atexit handlers so we
don't regress on crashing on exit.

@Sonicadvance1 Sonicadvance1 force-pushed the 59 branch 2 times, most recently from 68faf8b to 7ce6dda Compare January 14, 2026 20:37
@Sonicadvance1
Copy link
Member Author

Looks like the bash implementation doesn't work. I don't know bash well enough to know what's wrong. 🤷

Comment on lines 240 to 244
COUNT = `llvm-objdump -D ${{runner.workspace}}/build/Bin/FEX | grep "__cxa_atexit@plt>$" | wc -l`
if [ $COUNT -eq 1 ]
echo "Expected 1 atexit handlers, found $COUNT"
exit 1
fi
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
COUNT = `llvm-objdump -D ${{runner.workspace}}/build/Bin/FEX | grep "__cxa_atexit@plt>$" | wc -l`
if [ $COUNT -eq 1 ]
echo "Expected 1 atexit handlers, found $COUNT"
exit 1
fi
COUNT=`llvm-objdump -D ${{runner.workspace}}/build/Bin/FEX | grep '__cxa_atexit@plt>\\$' | wc -l`
if [ $COUNT -ne 1 ]
echo "Expected 1 atexit handlers, found $COUNT"
exit 1
fi

Something to this effect should be good. Otherwise you might need to open a terminal and run it once to find the last typo.

@Sonicadvance1 Sonicadvance1 force-pushed the 59 branch 2 times, most recently from 9e813de to 905df53 Compare January 14, 2026 21:04
run: mv ${{runner.workspace}}/build/Testing/Temporary/LastTest.log ${{runner.workspace}}/build/Testing/Temporary/LastTest_StructVerifier.log || true

- name: Ensure expected atexit registrations
working-directory: ${{runner.workspace}}/build
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
working-directory: ${{runner.workspace}}/build
COUNT=$(llvm-objdump -D build/Bin/FEX | grep '__cxa_atexit@plt>\\$' | wc -l)
[ "$COUNT" -eq 1 ] || { echo "Expected 1 atexit handlers, found $COUNT"; exit 1; }

Slightly more concise. Also ensure to remove the redundant working-directory and shell directives (cc. #5243 and #5245)

@Sonicadvance1 Sonicadvance1 force-pushed the 59 branch 3 times, most recently from 6877ea1 to ba52cbd Compare January 26, 2026 23:01
…ic object

Just a little bit of late initialization to this pmr object using
placement new.

Removes an `atexit` registration that contributes to crashing on exit.
Even though we leak `Alloc64` on shutdown, that isn't good enough to
avoid the `atexit` handler deallocating memory. So we need to use a raw
pointer and leak it.

Removes an `atexit` registration that contributes to crashing on exit.
These need to be late initialized because they allocate memory and
register an `atexit` handler to deallocate.

Removes an `atexit` registration that contributes to crashing on exit.
There is only one registration that I've not been able to track down why
it happens, but it is something to do with std::ostream. This just
ensures in CI that we don't ever register anymore atexit handlers so we
don't regress on crashing on `exit`.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants