New target methods for memory tagging support
[deliverable/binutils-gdb.git] / gdb / ppc-linux-nat.c
index 72f0283e4af231f12f15bf921eea5ca0bbcaf038..f1ba165d54054eea06e31b6f4ef6c0868f305491 100644 (file)
@@ -2488,33 +2488,24 @@ ppc_linux_nat_target::check_condition (CORE_ADDR watch_addr,
                                       struct expression *cond,
                                       CORE_ADDR *data_value, int *len)
 {
-  int pc = 1, num_accesses_left, num_accesses_right;
+  int num_accesses_left, num_accesses_right;
   struct value *left_val, *right_val;
   std::vector<value_ref_ptr> left_chain, right_chain;
 
-  if (cond->first_opcode () != BINOP_EQUAL)
+  expr::equal_operation *eqop
+    = dynamic_cast<expr::equal_operation *> (cond->op.get ());
+  if (eqop == nullptr)
     return 0;
+  expr::operation *lhs = eqop->get_lhs ();
+  expr::operation *rhs = eqop->get_rhs ();
 
-  expr::operation *lhs = nullptr;
-  expr::operation *rhs = nullptr;
-  if (cond->op != nullptr)
-    {
-      expr::equal_operation *eqop
-       = dynamic_cast<expr::equal_operation *> (cond->op.get ());
-      if (eqop != nullptr)
-       {
-         lhs = eqop->get_lhs ();
-         rhs = eqop->get_rhs ();
-       }
-    }
-
-  fetch_subexp_value (cond, &pc, lhs, &left_val, NULL, &left_chain, false);
+  fetch_subexp_value (cond, lhs, &left_val, NULL, &left_chain, false);
   num_accesses_left = num_memory_accesses (left_chain);
 
   if (left_val == NULL || num_accesses_left < 0)
     return 0;
 
-  fetch_subexp_value (cond, &pc, rhs, &right_val, NULL, &right_chain, false);
+  fetch_subexp_value (cond, rhs, &right_val, NULL, &right_chain, false);
   num_accesses_right = num_memory_accesses (right_chain);
 
   if (right_val == NULL || num_accesses_right < 0)
This page took 0.025085 seconds and 4 git commands to generate.