This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH AArch64]: Add constraint letter for stack_protect_test pattern.


Hi Maintainers,

Below patch adds register constraint "r" for destination operand in
"stack_protect_test" pattern.

We need a general register here and adding "r" will avoid vector
register getting allocated.

regression tested on aarch64-unknown-linux-gnu.

Ok for trunk?

regards,
Venkat.


gcc/ChangeLog

2014-09-04 Venkataramanan Kumar <venkataramanan.kumar@linaro.org>

       * config/aarch64/aarch64.md (stack_protect_test_<mode>) Add register
       constraint for operand 0.


diff --git a/gcc/config/aarch64/aarch64.md b/gcc/config/aarch64/aarch64.md
index b5be79c..77588b9 100644
--- a/gcc/config/aarch64/aarch64.md
+++ b/gcc/config/aarch64/aarch64.md
@@ -4026,7 +4026,7 @@
 })

 (define_insn "stack_protect_test_<mode>"
-  [(set (match_operand:PTR 0 "register_operand")
+ [(set (match_operand:PTR 0 "register_operand" "r")
        (unspec:PTR [(match_operand:PTR 1 "memory_operand" "m")
                     (match_operand:PTR 2 "memory_operand" "m")]
         UNSPEC_SP_TEST))


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]