summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKyrylo Tkachov <kyrylo.tkachov@arm.com>2019-07-02 08:24:54 +0000
committerKyrylo Tkachov <ktkachov@gcc.gnu.org>2019-07-02 08:24:54 +0000
commit8bb9a5e66a150b73c97aeffee52b57147022a817 (patch)
treead25eff77ffcceb371d0439a550fcb2b7298963e
parentlto-common.c (lto_register_canonical_types_for_odr_types): Copy CXX_ODR_P fro... (diff)
[arm/AArch64] Assume unhandled NEON types are neon_arith_basic types when scheduling for Cortex-A57
Some scheduling descriptions, like the Cortex-A57 one, are reused for multiple -mcpu options. Sometimes those other -mcpu cores support more architecture features than the Armv8-A Cortex-A57. For example, the Cortex-A75 and Cortex-A76 support Armv8.2-A as well as the Dot Product instructions. These Dot Product instructions have the neon_dot and neon_dot_q scheduling type, but that type is not handled in cortex-a57.md, since the Cortex-A57 itself doesn't need to care about these instructions. But if we just ignore the neon_dot(_q) type at scheduling we get really terrible codegen when compiling for -mcpu=cortex-a76, for example, because the scheduler just pools all the UDOT instructions at the end of the basic block, since it doesn't assume anything about their behaviour. This patch ameliorates the situation somewhat by telling the Cortex-A57 scheduling model to treat any insn that doesn't get assigned a cortex_a57_neon_type but is actually a is_neon_type instruction as a simple neon_arith_basic instruction. This allows us to treat post-Armv8-A SIMD instructions more sanely without having to model each of them explicitly in cortex-a57.md. * config/arm/cortex-a57.md (cortex_a57_neon_type): Use neon_arith_basic for is_neon_type instructions that have not already been categorized. From-SVN: r272924
-rw-r--r--gcc/ChangeLog6
-rw-r--r--gcc/config/arm/cortex-a57.md7
2 files changed, 12 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 6a1e932ad739..9d1b64866158 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,9 @@
12019-07-02 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
2
3 * config/arm/cortex-a57.md (cortex_a57_neon_type): Use neon_arith_basic
4 for is_neon_type instructions that have not already been categorized.
5
6
12019-07-02 Richard Biener <rguenther@suse.de> 72019-07-02 Richard Biener <rguenther@suse.de>
2 8
3 PR tree-optimization/58483 9 PR tree-optimization/58483
diff --git a/gcc/config/arm/cortex-a57.md b/gcc/config/arm/cortex-a57.md
index 577dc8d7fe25..a5f0b10d1421 100644
--- a/gcc/config/arm/cortex-a57.md
+++ b/gcc/config/arm/cortex-a57.md
@@ -236,7 +236,12 @@
236 neon_store1_4reg, neon_store1_4reg_q,\ 236 neon_store1_4reg, neon_store1_4reg_q,\
237 neon_store1_one_lane, neon_store1_one_lane_q,\ 237 neon_store1_one_lane, neon_store1_one_lane_q,\
238 neon_store2_one_lane, neon_store2_one_lane_q") 238 neon_store2_one_lane, neon_store2_one_lane_q")
239 (const_string "neon_store_complex")] 239 (const_string "neon_store_complex")
240;; If it doesn't match any of the above that we want to treat specially but is
241;; still a NEON type, treat it as a basic NEON type. This is better than
242;; dropping it on the floor and making no assumptions about it whatsoever.
243 (eq_attr "is_neon_type" "yes")
244 (const_string "neon_arith_basic")]
240 (const_string "unknown"))) 245 (const_string "unknown")))
241 246
242;; The Cortex-A57 core is modelled as a triple issue pipeline that has 247;; The Cortex-A57 core is modelled as a triple issue pipeline that has