diff options
author | Nicolas Geoffray <ngeoffray@google.com> | 2015-07-02 15:48:27 +0100 |
---|---|---|
committer | Nicolas Geoffray <ngeoffray@google.com> | 2015-07-02 15:58:52 +0100 |
commit | 3abd437507f8ba30a238a52c273c9944dcb9d5a1 (patch) | |
tree | 9e058e63cb1176446a2838436223d8b18119a2b0 /compiler/optimizing/nodes.h | |
parent | 4990f5c14a04b9aad1be50d206b7c1f8989d8923 (diff) | |
download | android_art-3abd437507f8ba30a238a52c273c9944dcb9d5a1.tar.gz android_art-3abd437507f8ba30a238a52c273c9944dcb9d5a1.tar.bz2 android_art-3abd437507f8ba30a238a52c273c9944dcb9d5a1.zip |
Do not create a HBoundType when the instruction is non-null.
We don't need to refine the type after a null check, if the
instruction is known non null or null. As a side effect, this
avoids replacing HLoadClass instructions with HBoundType instructions.
bug:22116987
Change-Id: I565ae95db5a64faec30e026674636e398e0bf445
Diffstat (limited to 'compiler/optimizing/nodes.h')
-rw-r--r-- | compiler/optimizing/nodes.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/compiler/optimizing/nodes.h b/compiler/optimizing/nodes.h index 01ba1101f2..f8149d16e3 100644 --- a/compiler/optimizing/nodes.h +++ b/compiler/optimizing/nodes.h @@ -3437,6 +3437,7 @@ class HLoadClass : public HExpression<0> { uint32_t GetDexPc() const OVERRIDE { return dex_pc_; } uint16_t GetTypeIndex() const { return type_index_; } bool IsReferrersClass() const { return is_referrers_class_; } + bool CanBeNull() const OVERRIDE { return false; } bool NeedsEnvironment() const OVERRIDE { // Will call runtime and load the class if the class is not loaded yet. |