This is an archive of the discontinued LLVM Phabricator instance.

[libcxxabi] Use the right calling convention for exception destructors on i386 Windows
ClosedPublic

Authored by mstorsjo on May 5 2022, 12:21 AM.

Details

Summary

On Windows on i386, C++ member functions use a different calling
convention (__thiscall) than the default one for regular functions
(__cdecl). (On Windows on architectures other than i386, both calling
convention attributes are no-ops.)

This matches how libstdc++ declares these types.

This fixes the std/thread/futures/futures.{shared,unique}_future/dtor.pass.cpp
tests on i386 mingw.

Diff Detail

Event Timeline

mstorsjo created this revision.May 5 2022, 12:21 AM
Herald added a project: Restricted Project. · View Herald TranscriptMay 5 2022, 12:21 AM
mstorsjo requested review of this revision.May 5 2022, 12:21 AM
Herald added a project: Restricted Project. · View Herald TranscriptMay 5 2022, 12:21 AM
Herald added a reviewer: Restricted Project. · View Herald Transcript
ldionne accepted this revision.May 5 2022, 8:26 AM
This revision is now accepted and ready to land.May 5 2022, 8:26 AM