]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
Revert "LoongArch: Fix PR122097 (2)."
authorXi Ruoyao <xry111@xry111.site>
Sat, 31 Jan 2026 16:04:23 +0000 (00:04 +0800)
committerXi Ruoyao <xry111@xry111.site>
Tue, 3 Feb 2026 03:01:50 +0000 (11:01 +0800)
This reverts commit e753fa38bb612a3bebe0fc596a44a104bbd2739b.

The commit is no longer needed with the new copysign/xorsign
implementaton.

gcc/config/loongarch/loongarch.cc

index 09339e6ed051ada5e826b507686fadf6be550a7c..1f26928e901a18a86d9723286686d6b24ece181a 100644 (file)
@@ -1851,27 +1851,7 @@ loongarch_const_vector_same_bytes_p (rtx op, machine_mode mode)
 
   first = CONST_VECTOR_ELT (op, 0);
   bytes = GET_MODE_UNIT_SIZE (mode);
-
-  if (GET_MODE_CLASS (mode) == MODE_VECTOR_FLOAT)
-    {
-      rtx val_s = CONST_VECTOR_ELT (op, 0);
-      const REAL_VALUE_TYPE *x = CONST_DOUBLE_REAL_VALUE (val_s);
-      if (GET_MODE (val_s) == DFmode)
-       {
-         long tmp[2];
-         REAL_VALUE_TO_TARGET_DOUBLE (*x, tmp);
-         val = (unsigned HOST_WIDE_INT) tmp[1] << 32 | tmp[0];
-       }
-      else
-       {
-         long tmp;
-         REAL_VALUE_TO_TARGET_SINGLE (*x, tmp);
-         val = (unsigned HOST_WIDE_INT) tmp;
-       }
-    }
-  else
-    val = UINTVAL (first);
-
+  val = INTVAL (first);
   first_byte = val & 0xff;
   for (i = 1; i < bytes; i++)
     {