RISCV: [Codegen] Add VisitConstructorFence

Test: m test-art-host-gtest
Bug: 283082089
Signed-off-by: Lifang Xia <lifang_xia@linux.alibaba.com>
Signed-off-by: Wendong Wang <wangwd@xcvmbyte.com>
Change-Id: I99bf8301c275174a33ae6cf1d14b82967b87b3d6
diff --git a/compiler/optimizing/code_generator_riscv64.cc b/compiler/optimizing/code_generator_riscv64.cc
index 02a50a1..6266461 100644
--- a/compiler/optimizing/code_generator_riscv64.cc
+++ b/compiler/optimizing/code_generator_riscv64.cc
@@ -1198,13 +1198,11 @@
 }
 
 void LocationsBuilderRISCV64::VisitConstructorFence(HConstructorFence* instruction) {
-  UNUSED(instruction);
-  LOG(FATAL) << "Unimplemented";
+  instruction->SetLocations(nullptr);
 }
-
-void InstructionCodeGeneratorRISCV64::VisitConstructorFence(HConstructorFence* instruction) {
-  UNUSED(instruction);
-  LOG(FATAL) << "Unimplemented";
+void InstructionCodeGeneratorRISCV64::VisitConstructorFence(
+    [[maybe_unused]] HConstructorFence* instruction) {
+  codegen_->GenerateMemoryBarrier(MemBarrierKind::kStoreStore);
 }
 
 void LocationsBuilderRISCV64::VisitCurrentMethod(HCurrentMethod* instruction) {