diff options
author | Artur Pilipenko <apilipenko@azulsystems.com> | 2018-11-29 02:15:35 +0000 |
---|---|---|
committer | Artur Pilipenko <apilipenko@azulsystems.com> | 2018-11-29 02:15:35 +0000 |
commit | 8b92c1d1424d4a6298d4abbc54d8e9f866d0a307 (patch) | |
tree | 70a6f0afc15bc93e3e3b65dfd08e94d8bf9fc1e9 /llvm/lib/Analysis/CaptureTracking.cpp | |
parent | 54c82d36427361a5a93368d1dc6ad987faa5c757 (diff) | |
download | bcm5719-llvm-8b92c1d1424d4a6298d4abbc54d8e9f866d0a307.tar.gz bcm5719-llvm-8b92c1d1424d4a6298d4abbc54d8e9f866d0a307.zip |
NFC. Use unsigned type for uses counter in CaptureTracking
llvm-svn: 347826
Diffstat (limited to 'llvm/lib/Analysis/CaptureTracking.cpp')
-rw-r--r-- | llvm/lib/Analysis/CaptureTracking.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Analysis/CaptureTracking.cpp b/llvm/lib/Analysis/CaptureTracking.cpp index d4f73bdb436..259678982ed 100644 --- a/llvm/lib/Analysis/CaptureTracking.cpp +++ b/llvm/lib/Analysis/CaptureTracking.cpp @@ -210,7 +210,7 @@ bool llvm::PointerMayBeCapturedBefore(const Value *V, bool ReturnCaptures, /// TODO: Write a new FunctionPass AliasAnalysis so that it can keep /// a cache. Then we can move the code from BasicAliasAnalysis into /// that path, and remove this threshold. -static int const Threshold = 20; +static unsigned const Threshold = 20; void llvm::PointerMayBeCaptured(const Value *V, CaptureTracker *Tracker) { assert(V->getType()->isPointerTy() && "Capture is for pointers only!"); @@ -218,7 +218,7 @@ void llvm::PointerMayBeCaptured(const Value *V, CaptureTracker *Tracker) { SmallSet<const Use *, Threshold> Visited; auto AddUses = [&](const Value *V) { - int Count = 0; + unsigned Count = 0; for (const Use &U : V->uses()) { // If there are lots of uses, conservatively say that the value // is captured to avoid taking too much compile time. |