This is an archive of the discontinued LLVM Phabricator instance.

[Windows] Fix threads comparison on Windows
ClosedPublic

Authored by aleksandr.urakov on Oct 17 2018, 1:42 AM.

Details

Summary

This patch makes Windows threads to compare by a thread ID, not by a handle. It's because the same thread can have different handles on Windows (for example, GetCurrentThread always returns the fake handle -2). This leads to some incorrect behavior. For example, in Process::GetRunLock always m_public_run_lock is returned without this patch.

Diff Detail

Repository
rL LLVM

Event Timeline

This revision is now accepted and ready to land.Oct 17 2018, 10:30 AM
This revision was automatically updated to reflect the committed changes.