Commit 3b0ecec8 authored by Mike Wittman's avatar Mike Wittman Committed by Commit Bot

Revert "[Sampling profiler] Minimize use of loader lock on profiled threads"

This reverts commit bab78c6c.

Reason for revert: temporarily reverting to check whether this CL triggered the flaky Clusterfuzz CHECK failure in https://crbug.com/1034896.

Original change's description:
> [Sampling profiler] Minimize use of loader lock on profiled threads
> 
> Saves off the function pointer obtained from ntdll.dll so that we don't
> need to repeatedly query its module handle and take the loader lock
> while doing so.
> 
> Bug: 1028808
> Change-Id: I25c0dd2872524a28a87df7c4bf2db7551eab6311
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1940882
> Auto-Submit: Mike Wittman <wittman@chromium.org>
> Commit-Queue: Bruce Dawson <brucedawson@chromium.org>
> Reviewed-by: Bruce Dawson <brucedawson@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#719811}

TBR=wittman@chromium.org,brucedawson@chromium.org

# Not skipping CQ checks because original CL landed > 1 day ago.

Bug: 1028808, 1034896
Change-Id: Ifbda46060fbac279bee2289a6ac8f1df6afb0cbf
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1998008Reviewed-by: default avatarMike Wittman <wittman@chromium.org>
Reviewed-by: default avatarBruce Dawson <brucedawson@chromium.org>
Commit-Queue: Mike Wittman <wittman@chromium.org>
Cr-Commit-Position: refs/heads/master@{#730687}
parent 647392b6
......@@ -72,7 +72,7 @@ const TEB* GetThreadEnvironmentBlock(HANDLE thread_handle) {
using NtQueryInformationThreadFunction =
NTSTATUS(WINAPI*)(HANDLE, THREAD_INFORMATION_CLASS, PVOID, ULONG, PULONG);
static const auto nt_query_information_thread =
const auto nt_query_information_thread =
reinterpret_cast<NtQueryInformationThreadFunction>(::GetProcAddress(
::GetModuleHandle(L"ntdll.dll"), "NtQueryInformationThread"));
if (!nt_query_information_thread)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment