aboutsummaryrefslogtreecommitdiff
path: root/llvm/tools/llvm-readobj/llvm-readobj.cpp
diff options
context:
space:
mode:
authorAdam Nemet <anemet@apple.com>2015-07-09 22:17:38 +0000
committerAdam Nemet <anemet@apple.com>2015-07-09 22:17:38 +0000
commitee61474a618e92892a56c73216ca365baa0c61cb (patch)
treeb600d4151bd44915b15ecdcca4d891d0e55bcb69 /llvm/tools/llvm-readobj/llvm-readobj.cpp
parent8eecb3c160ac1c51c8401daaa394d2f5bf9a2871 (diff)
downloadllvm-ee61474a618e92892a56c73216ca365baa0c61cb.zip
llvm-ee61474a618e92892a56c73216ca365baa0c61cb.tar.gz
llvm-ee61474a618e92892a56c73216ca365baa0c61cb.tar.bz2
[LAA] Hide NeedRTCheck logic completely inside canCheckPtrAtRT, NFC
Currently canCheckPtrAtRT returns two flags NeedRTCheck and CanDoRT. NeedRTCheck says whether we need checks and CanDoRT whether we can generate the checks. The idea is to encode three states with these: Need/Can: (1) false/dont-care: no checks are needed (2) true/false: we need checks but can't generate them (3) true/true: we need checks and we can generate them This is pretty unnecessary since the caller (analyzeLoop) is only interested in whether we can generate the checks if we actually need them (i.e. 1 or 3). So this change cleans up to return just that (CanDoRTIfNeeded) and pulls all the underlying logic into canCheckPtrAtRT. By doing all this, we simplify analyzeLoop which is the complex function in LAA. There is further room for improvement here by using RtCheck.Need directly rather than a new local variable NeedRTCheck but that's for a later patch. llvm-svn: 241866
Diffstat (limited to 'llvm/tools/llvm-readobj/llvm-readobj.cpp')
0 files changed, 0 insertions, 0 deletions