On 14/11/2023 17:01, Christophe Lyon wrote:
Hi,

On 11/13/23 15:26, Richard Earnshaw wrote:
diff --git a/gcc/testsuite/lib/target-supports.exp b/gcc/testsuite/lib/target-supports.exp
index 1a7bea96c1e..d414cddf4dc 100644
--- a/gcc/testsuite/lib/target-supports.exp
+++ b/gcc/testsuite/lib/target-supports.exp
@@ -5590,6 +5590,24 @@ proc check_effective_target_arm_thumb1_cbz_ok {} {
      }
  }
+# Return 1 if this is an Arm target which supports the Armv6t2 extensions.
+# This can be either in Arm state or in Thumb state.
+
+proc check_effective_target_arm_arch_v6t2_hw_ok {} {
+    if [check_effective_target_arm_thumb1_ok] {

Why arm_thumb1_ok and not arm_arch_v6t2_ok ?

Because I cloned the function immediately above, then only half fixed it. That's not the only bug though. It never tries to run the test (object only runs the compiler with '-c', so it stops after assembly), which it should if it's checking if the HW can run a test.

Ooops!

I'll fix that.  Thanks for catching.

R.


Thanks,

Christophe


+    return [check_no_compiler_messages arm_movt object {
+        int
+        main (void)
+        {
+          asm ("bfc r0, #1, #2");
+          return 0;
+        }
+    } [add_options_for_arm_arch_v6t2 ""]]
+    } else {
+    return 0
+    }
+}
+
  # Return 1 if this is an ARM target where ARMv8-M Security Extensions is
  # available.

Reply via email to