1 From 07453188b18a2cbe815917dbb893b4ebfdd793b6 Mon Sep 17 00:00:00 2001
2 From: ktkachov <ktkachov@138bc75d-0d04-0410-961f-82ee72b054a4>
3 Date: Fri, 26 Aug 2016 10:23:20 +0000
4 Subject: [PATCH] [ARM] PR target/70473: Reduce size of Cortex-A8 automaton
7 * config/arm/cortex-a8-neon.md (cortex_a8_vfp_muld): Reduce
8 reservation duration to 15 cycles.
9 (cortex_a8_vfp_macs): Likewise.
10 (cortex_a8_vfp_macd): Likewise.
11 (cortex_a8_vfp_divs): Likewise.
12 (cortex_a8_vfp_divd): Likewise.
14 git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@239772
15 138bc75d-0d04-0410-961f-82ee72b054a4
17 [Backport from gcc upstream commit 79f5d5e3cd5a668d5ecb2b6b0cce80ef5706ac53.]
18 Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
20 gcc/config/arm/cortex-a8-neon.md | 14 +++++++++-----
21 1 file changed, 9 insertions(+), 5 deletions(-)
23 diff --git a/gcc/config/arm/cortex-a8-neon.md b/gcc/config/arm/cortex-a8-neon.md
24 index 45f861f..b16c299 100644
25 --- a/gcc/config/arm/cortex-a8-neon.md
26 +++ b/gcc/config/arm/cortex-a8-neon.md
28 (eq_attr "type" "fmuls"))
29 "cortex_a8_vfp,cortex_a8_vfplite*11")
31 +;; Don't model a reservation for more than 15 cycles as this explodes the
32 +;; state space of the automaton for little gain. It is unlikely that the
33 +;; scheduler will find enough instructions to hide the full latency of the
35 (define_insn_reservation "cortex_a8_vfp_muld" 17
36 (and (eq_attr "tune" "cortexa8")
37 (eq_attr "type" "fmuld"))
38 - "cortex_a8_vfp,cortex_a8_vfplite*16")
39 + "cortex_a8_vfp,cortex_a8_vfplite*15")
41 (define_insn_reservation "cortex_a8_vfp_macs" 21
42 (and (eq_attr "tune" "cortexa8")
43 (eq_attr "type" "fmacs,ffmas"))
44 - "cortex_a8_vfp,cortex_a8_vfplite*20")
45 + "cortex_a8_vfp,cortex_a8_vfplite*15")
47 (define_insn_reservation "cortex_a8_vfp_macd" 26
48 (and (eq_attr "tune" "cortexa8")
49 (eq_attr "type" "fmacd,ffmad"))
50 - "cortex_a8_vfp,cortex_a8_vfplite*25")
51 + "cortex_a8_vfp,cortex_a8_vfplite*15")
53 (define_insn_reservation "cortex_a8_vfp_divs" 37
54 (and (eq_attr "tune" "cortexa8")
55 (eq_attr "type" "fdivs, fsqrts"))
56 - "cortex_a8_vfp,cortex_a8_vfplite*36")
57 + "cortex_a8_vfp,cortex_a8_vfplite*15")
59 (define_insn_reservation "cortex_a8_vfp_divd" 65
60 (and (eq_attr "tune" "cortexa8")
61 (eq_attr "type" "fdivd, fsqrtd"))
62 - "cortex_a8_vfp,cortex_a8_vfplite*64")
63 + "cortex_a8_vfp,cortex_a8_vfplite*15")
65 ;; Comparisons can actually take 7 cycles sometimes instead of four,
66 ;; but given all the other instructions lumped into type=ffarith that