summaryrefslogtreecommitdiffstats
path: root/compiler-rt/lib/xray
diff options
context:
space:
mode:
authorDean Michael Berris <dberris@google.com>2018-12-05 07:14:06 +0000
committerDean Michael Berris <dberris@google.com>2018-12-05 07:14:06 +0000
commit9e4b7efa0eaf8dbbb6d7af5fda1e7e090a970e21 (patch)
treee020410322dd7435ceda59192890aaf85dfbb4d4 /compiler-rt/lib/xray
parentefd2cb8a0d5e40a2392da6a5b6ce4d06eb60e7c5 (diff)
downloadbcm5719-llvm-9e4b7efa0eaf8dbbb6d7af5fda1e7e090a970e21.tar.gz
bcm5719-llvm-9e4b7efa0eaf8dbbb6d7af5fda1e7e090a970e21.zip
[XRay] Use uptr instead of uintptr_t
Follow-up to D54989. llvm-svn: 348338
Diffstat (limited to 'compiler-rt/lib/xray')
-rw-r--r--compiler-rt/lib/xray/xray_profiling.cc16
1 files changed, 8 insertions, 8 deletions
diff --git a/compiler-rt/lib/xray/xray_profiling.cc b/compiler-rt/lib/xray/xray_profiling.cc
index 65c39b98b4b..6db4b6ff9a0 100644
--- a/compiler-rt/lib/xray/xray_profiling.cc
+++ b/compiler-rt/lib/xray/xray_profiling.cc
@@ -78,21 +78,21 @@ static ProfilingData *getThreadLocalData() XRAY_NEVER_INSTRUMENT {
if (atomic_load_relaxed(&ThreadExitingLatch))
return nullptr;
- uintptr_t Allocators = 0;
+ uptr Allocators = 0;
if (atomic_compare_exchange_strong(&TLD.Allocators, &Allocators, 1,
memory_order_acq_rel)) {
new (&AllocatorsStorage)
FunctionCallTrie::Allocators(FunctionCallTrie::InitAllocators());
- Allocators = reinterpret_cast<uintptr_t>(
+ Allocators = reinterpret_cast<uptr>(
reinterpret_cast<FunctionCallTrie::Allocators *>(&AllocatorsStorage));
atomic_store(&TLD.Allocators, Allocators, memory_order_release);
}
- uintptr_t FCT = 0;
+ uptr FCT = 0;
if (atomic_compare_exchange_strong(&TLD.FCT, &FCT, 1, memory_order_acq_rel)) {
new (&FunctionCallTrieStorage) FunctionCallTrie(
*reinterpret_cast<FunctionCallTrie::Allocators *>(Allocators));
- FCT = reinterpret_cast<uintptr_t>(
+ FCT = reinterpret_cast<uptr>(
reinterpret_cast<FunctionCallTrie *>(&FunctionCallTrieStorage));
atomic_store(&TLD.FCT, FCT, memory_order_release);
}
@@ -109,13 +109,13 @@ static void cleanupTLD() XRAY_NEVER_INSTRUMENT {
return;
auto FCT = atomic_exchange(&TLD.FCT, 0, memory_order_acq_rel);
- if (FCT == reinterpret_cast<uintptr_t>(reinterpret_cast<FunctionCallTrie *>(
+ if (FCT == reinterpret_cast<uptr>(reinterpret_cast<FunctionCallTrie *>(
&FunctionCallTrieStorage)))
reinterpret_cast<FunctionCallTrie *>(FCT)->~FunctionCallTrie();
auto Allocators = atomic_exchange(&TLD.Allocators, 0, memory_order_acq_rel);
if (Allocators ==
- reinterpret_cast<uintptr_t>(
+ reinterpret_cast<uptr>(
reinterpret_cast<FunctionCallTrie::Allocators *>(&AllocatorsStorage)))
reinterpret_cast<FunctionCallTrie::Allocators *>(Allocators)->~Allocators();
}
@@ -125,8 +125,8 @@ static void postCurrentThreadFCT(ProfilingData &T) XRAY_NEVER_INSTRUMENT {
if (!TLDInit)
return;
- uintptr_t P = atomic_load(&T.FCT, memory_order_acquire);
- if (P != reinterpret_cast<uintptr_t>(
+ uptr P = atomic_load(&T.FCT, memory_order_acquire);
+ if (P != reinterpret_cast<uptr>(
reinterpret_cast<FunctionCallTrie *>(&FunctionCallTrieStorage)))
return;
OpenPOWER on IntegriCloud