[all-commits] [llvm/llvm-project] e4a922: [GISel][KnownBits] Give up on PHI analysis as soon...
qcolombet via All-commits
all-commits at lists.llvm.org
Thu Feb 20 11:34:54 PST 2020
Branch: refs/heads/master
Home: https://github.com/llvm/llvm-project
Commit: e4a9225f5d10f35cf9cf3664bb93620880228782
https://github.com/llvm/llvm-project/commit/e4a9225f5d10f35cf9cf3664bb93620880228782
Author: Quentin Colombet <qcolombet at apple.com>
Date: 2020-02-20 (Thu, 20 Feb 2020)
Changed paths:
M llvm/lib/CodeGen/GlobalISel/GISelKnownBits.cpp
M llvm/unittests/CodeGen/GlobalISel/KnownBitsTest.cpp
Log Message:
-----------
[GISel][KnownBits] Give up on PHI analysis as soon as we don't know anything
When analyzing PHIs, we gather the known bits for every operand and
merge them together to get the known bits of the result of the PHI.
It is not unusual that merging the information leads to know nothing
on the result (e.g., phi a: i8 3, b: i8 unknown, ..., after looking at the
second argument we know we will know nothing on the result), thus, as
soon as we reach that state, stop analyzing the following operand (i.e.,
on the previous example, we won't process anything after looking at `b`).
This improves compile time in particular with PHIs with a large number
of operands.
NFC.
More information about the All-commits
mailing list