[all-commits] [llvm/llvm-project] f715ed: [LVI] Cleanup/unify cache access
Nikita Popov via All-commits
all-commits at lists.llvm.org
Fri Apr 17 09:46:59 PDT 2020
Branch: refs/heads/master
Home: https://github.com/llvm/llvm-project
Commit: f715eda60403194bf844a169587726744d0e9cd7
https://github.com/llvm/llvm-project/commit/f715eda60403194bf844a169587726744d0e9cd7
Author: Nikita Popov <nikita.ppv at gmail.com>
Date: 2020-04-17 (Fri, 17 Apr 2020)
Changed paths:
M llvm/lib/Analysis/LazyValueInfo.cpp
Log Message:
-----------
[LVI] Cleanup/unify cache access
This patch combines the "has" and "get" parts of the cache access.
getCachedValueInfo() now both sets the BBLV return argument, and
returns whether the value was found.
Additionally, the management of the work stack is now integrated
into getBlockValue(). If the value is not cached yet, we try to
push to the stack (and return false, indicating that we need to
solve first), or return overdefined in case of a cycle.
These changes a) avoid a duplicate cache lookup for has & get and
b) ensure that the logic is uniform everywhere. For this reason
this change is also not quite NFC, because previously overdefined
values from the cache, and overdefined values from a cycle received
different treatment when it came to assumption intersection.
Differential Revision: https://reviews.llvm.org/D76788
More information about the All-commits
mailing list