no bug - Bumping Firefox l10n changesets r=release a=l10n-bump DONTBUILD CLOSED TREE
[gecko.git] / mozglue / misc / StackWalk_windows.h
blob81c81257810b6e0d56587352b1be5368675a2e2c
1 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
3 /* This Source Code Form is subject to the terms of the Mozilla Public
4 * License, v. 2.0. If a copy of the MPL was not distributed with this
5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
7 #ifndef mozilla_StackWalk_windows_h
8 #define mozilla_StackWalk_windows_h
10 #include "mozilla/Types.h"
12 #if defined(_M_AMD64) || defined(_M_ARM64)
13 /**
14 * Allow stack walkers to work around the egregious win64 dynamic lookup table
15 * list API by locking around SuspendThread to avoid deadlock.
17 * See comment in StackWalk.cpp
19 struct MOZ_RAII AutoSuppressStackWalking {
20 MFBT_API AutoSuppressStackWalking();
21 MFBT_API ~AutoSuppressStackWalking();
24 # if defined(IMPL_MFBT)
25 void SuppressStackWalking();
26 void DesuppressStackWalking();
27 # endif // defined(IMPL_MFBT)
29 MFBT_API void RegisterJitCodeRegion(uint8_t* aStart, size_t size);
31 MFBT_API void UnregisterJitCodeRegion(uint8_t* aStart, size_t size);
32 #endif // _M_AMD64 || _M_ARM64
34 #endif // mozilla_StackWalk_windows_h