From 386062d13ce20d036555a9e24b73a67b4156b5cb Mon Sep 17 00:00:00 2001 From: Calin Juravle Date: Wed, 7 Oct 2015 18:55:43 +0100 Subject: Make sure classes with different access checks are not GVN-ed Change-Id: I89f72fef3be35a4dd9585d97d03a3150386e0891 --- compiler/optimizing/nodes.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'compiler/optimizing/nodes.h') diff --git a/compiler/optimizing/nodes.h b/compiler/optimizing/nodes.h index 95dd03970d..f009c410f4 100644 --- a/compiler/optimizing/nodes.h +++ b/compiler/optimizing/nodes.h @@ -4534,7 +4534,8 @@ class HLoadClass : public HExpression<1> { bool CanBeMoved() const OVERRIDE { return true; } bool InstructionDataEquals(HInstruction* other) const OVERRIDE { - return other->AsLoadClass()->type_index_ == type_index_; + return other->AsLoadClass()->type_index_ == type_index_ && + other->AsLoadClass()->needs_access_check_ == needs_access_check_; } size_t ComputeHashCode() const OVERRIDE { return type_index_; } -- cgit v1.2.3-59-g8ed1b