From b5b98b9bb31acb2deffb692c50d0fbc71476663b Mon Sep 17 00:00:00 2001 From: Santiago Aboy Solanes Date: Mon, 22 Jan 2024 08:57:31 +0000 Subject: Revert^3 "Disable write-barrier elimination pass" This reverts commit 9f8df195b7ff2ce47eec4e9b193ff3214ebed19c. Reason for revert: Fix for x86_64 with heap poison enabled This case uses a temp with index `1` in the regular FieldSet case. This is done like this due to GenerateVarHandleSet also calling HandleFieldSet. The bug was that we were allocating only one temp in the regular FieldSet case and therefore not having the temp with index `1` available. PS1 is the revert as-is. PS2 contains the fix. Test: art/test/testrunner/testrunner.py --host --64 --optimizing -b Test: Same command with heap poison enabled too Bug: 301833859 Bug: 310755375 Bug: 260843353 Change-Id: Ie2740b4c443158c4e72810ce1d8268353c5f0055 --- compiler/optimizing/graph_checker.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'compiler/optimizing/graph_checker.h') diff --git a/compiler/optimizing/graph_checker.h b/compiler/optimizing/graph_checker.h index 38e2d7ced9..5704bcec1a 100644 --- a/compiler/optimizing/graph_checker.h +++ b/compiler/optimizing/graph_checker.h @@ -59,6 +59,8 @@ class GraphChecker : public HGraphDelegateVisitor { void VisitPhi(HPhi* phi) override; void VisitArraySet(HArraySet* instruction) override; + void VisitInstanceFieldSet(HInstanceFieldSet* instruction) override; + void VisitStaticFieldSet(HStaticFieldSet* instruction) override; void VisitBinaryOperation(HBinaryOperation* op) override; void VisitBooleanNot(HBooleanNot* instruction) override; void VisitBoundType(HBoundType* instruction) override; @@ -93,6 +95,9 @@ class GraphChecker : public HGraphDelegateVisitor { void HandleLoop(HBasicBlock* loop_header); void HandleBooleanInput(HInstruction* instruction, size_t input_index); + template + void CheckWriteBarrier(HInstruction* instruction, GetWriteBarrierKind&& get_write_barrier_kind); + // Was the last visit of the graph valid? bool IsValid() const { return errors_.empty(); -- cgit v1.2.3-59-g8ed1b