diff options
author | Aart Bik <ajcbik@google.com> | 2016-06-06 15:02:44 -0700 |
---|---|---|
committer | Aart Bik <ajcbik@google.com> | 2016-06-07 10:09:26 -0700 |
commit | 31883646547a036f58b9fa0894eb0fac0bcf05a1 (patch) | |
tree | 2b78c3b85254464f9f73826c26054ccefddd44e4 /compiler/optimizing/instruction_builder.cc | |
parent | 6b631dc9662d39ca0f89ee4653d911f1f5291913 (diff) |
Do not hide instance field hard failure with soft failure
Rationale:
Yet another verifier inaccuracy found with fuzz testing.
Instance field verification should proceed testing instance
field access after soft failures in cases where hard failures
could still follow. Failure to do so resulted in a compiler
crash (now made bit friendly with DCHECK as well).
With crash-before/pass-after test.
BUG=29126870
Change-Id: I8674d6171158eaa2aeb0492b35dfafea76416cac
Diffstat (limited to 'compiler/optimizing/instruction_builder.cc')
-rw-r--r-- | compiler/optimizing/instruction_builder.cc | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/compiler/optimizing/instruction_builder.cc b/compiler/optimizing/instruction_builder.cc index 5e691c7f5f..135038b753 100644 --- a/compiler/optimizing/instruction_builder.cc +++ b/compiler/optimizing/instruction_builder.cc @@ -381,10 +381,11 @@ HInstruction* HInstructionBuilder::LoadLocal(uint32_t reg_number, Primitive::Typ // If the operation requests a specific type, we make sure its input is of that type. if (type != value->GetType()) { if (Primitive::IsFloatingPointType(type)) { - return ssa_builder_->GetFloatOrDoubleEquivalent(value, type); + value = ssa_builder_->GetFloatOrDoubleEquivalent(value, type); } else if (type == Primitive::kPrimNot) { - return ssa_builder_->GetReferenceTypeEquivalent(value); + value = ssa_builder_->GetReferenceTypeEquivalent(value); } + DCHECK(value != nullptr); } return value; |