summaryrefslogtreecommitdiffstats
path: root/meta/packages/gcc/gcc-4.2.3/arm-crunch-predicates3.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta/packages/gcc/gcc-4.2.3/arm-crunch-predicates3.patch')
-rw-r--r--meta/packages/gcc/gcc-4.2.3/arm-crunch-predicates3.patch116
1 files changed, 116 insertions, 0 deletions
diff --git a/meta/packages/gcc/gcc-4.2.3/arm-crunch-predicates3.patch b/meta/packages/gcc/gcc-4.2.3/arm-crunch-predicates3.patch
new file mode 100644
index 0000000000..99e1e6c88c
--- /dev/null
+++ b/meta/packages/gcc/gcc-4.2.3/arm-crunch-predicates3.patch
@@ -0,0 +1,116 @@
1diff -urN ../gcc-cross-4.1.2-r4/gcc-4.1.2/gcc/config/arm/arm.md gcc-4.1.2/gcc/config/arm/arm.md
2--- ../gcc-cross-4.1.2-r4/gcc-4.1.2/gcc/config/arm/arm.md 2007-06-14 11:50:53.000000000 +1000
3+++ gcc-4.1.2/gcc/config/arm/arm.md 2007-06-14 11:43:17.000000000 +1000
4@@ -7488,6 +7488,22 @@
5 arm_compare_op1);"
6 )
7
8+;(define_expand "suneq"
9+; [(set (match_operand:SI 0 "s_register_operand" "")
10+; (uneq:SI (match_dup 1) (const_int 0)))]
11+; "TARGET_ARM && TARGET_HARD_FLOAT && (TARGET_MAVERICK)"
12+; "operands[1] = arm_gen_compare_reg (UNEQ, arm_compare_op0,
13+; arm_compare_op1);"
14+;)
15+
16+;(define_expand "sltgt"
17+; [(set (match_operand:SI 0 "s_register_operand" "")
18+; (ltgt:SI (match_dup 1) (const_int 0)))]
19+; "TARGET_ARM && TARGET_HARD_FLOAT && (TARGET_MAVERICK)"
20+; "operands[1] = arm_gen_compare_reg (LTGT, arm_compare_op0,
21+; arm_compare_op1);"
22+;)
23+
24 ;;; DO NOT add patterns for SUNEQ or SLTGT, these can't be represented with
25 ;;; simple ARM instructions.
26 ;
27@@ -10284,13 +10284,73 @@
28 "TARGET_ARM && arm_arch5e"
29 "pld\\t%a0")
30
31+;; Special predication pattern for Maverick Crunch floating-point
32+
33+(define_cond_exec
34+ [(match_operator 0 "maverick_comparison_operator"
35+ [(match_operand:CCFP 1 "cc_register" "")
36+ (const_int 0)])]
37+ "TARGET_ARM && TARGET_HARD_FLOAT && TARGET_MAVERICK"
38+ ""
39+)
40+
41+;; Special predication pattern for Maverick Crunch - !CCFP
42+
43+(define_cond_exec
44+ [(match_operator 0 "arm_comparison_operator"
45+ [(match_operand:CC_NOOV 1 "cc_register" "")
46+ (const_int 0)])]
47+ "TARGET_ARM && TARGET_HARD_FLOAT && TARGET_MAVERICK"
48+ ""
49+)
50+
51+(define_cond_exec
52+ [(match_operator 0 "arm_comparison_operator"
53+ [(match_operand:CC_Z 1 "cc_register" "")
54+ (const_int 0)])]
55+ "TARGET_ARM && TARGET_HARD_FLOAT && TARGET_MAVERICK"
56+ ""
57+)
58+
59+(define_cond_exec
60+ [(match_operator 0 "arm_comparison_operator"
61+ [(match_operand:CC_SWP 1 "cc_register" "")
62+ (const_int 0)])]
63+ "TARGET_ARM && TARGET_HARD_FLOAT && TARGET_MAVERICK"
64+ ""
65+)
66+
67+(define_cond_exec
68+ [(match_operator 0 "arm_comparison_operator"
69+ [(match_operand:CC_C 1 "cc_register" "")
70+ (const_int 0)])]
71+ "TARGET_ARM && TARGET_HARD_FLOAT && TARGET_MAVERICK"
72+ ""
73+)
74+
75+(define_cond_exec
76+ [(match_operator 0 "arm_comparison_operator"
77+ [(match_operand:CC_N 1 "cc_register" "")
78+ (const_int 0)])]
79+ "TARGET_ARM && TARGET_HARD_FLOAT && TARGET_MAVERICK"
80+ ""
81+)
82+
83+(define_cond_exec
84+ [(match_operator 0 "arm_comparison_operator"
85+ [(match_operand:CC 1 "cc_register" "")
86+ (const_int 0)])]
87+ "TARGET_ARM && TARGET_HARD_FLOAT && TARGET_MAVERICK"
88+ ""
89+)
90+
91 ;; General predication pattern
92
93 (define_cond_exec
94 [(match_operator 0 "arm_comparison_operator"
95 [(match_operand 1 "cc_register" "")
96 (const_int 0)])]
97- "TARGET_ARM"
98+ "TARGET_ARM && !(TARGET_HARD_FLOAT && TARGET_MAVERICK)"
99 ""
100 )
101
102diff -urN ../gcc-cross-4.1.2-r4/gcc-4.1.2/gcc/config/arm/predicates.md gcc-4.1.2/gcc/config/arm/predicates.md
103--- ../gcc-cross-4.1.2-r4/gcc-4.1.2/gcc/config/arm/predicates.md 2005-09-11 17:38:02.000000000 +1000
104+++ gcc-4.1.2/gcc/config/arm/predicates.md 2007-06-14 11:46:13.000000000 +1000
105@@ -172,7 +172,11 @@
106
107 ;; True for comparisons other than LTGT or UNEQ.
108 (define_special_predicate "arm_comparison_operator"
109 (match_code "eq,ne,le,lt,ge,gt,geu,gtu,leu,ltu,unordered,ordered,unlt,unle,unge,ungt"))
110+
111+;; True for comparisons other than GE, GEU, UNLT, UNORDERED or ORDERED - TODO add LTGT and UNEQ - needs extra support elsewhere
112+(define_special_predicate "maverick_comparison_operator"
113+(match_code "eq,ne,le,lt,gt,gtu,leu,ltu,unle,unge,ungt"))
114
115 (define_special_predicate "minmax_operator"
116 (and (match_code "smin,smax,umin,umax")