> Yes, there is only one optimization trick for the scheduler that requires
> leon3, but it doesn't affect correctness.  We could easily change that, i.e.
> enable the trick for leon too if -mfix-ut699 is passed.

Like this, applied on all branches.


2015-06-30  Eric Botcazou  <ebotca...@adacore.com>

        * config/sparc/leon.md (leon_load): Enable for all LEON variants if
        -mfix-ut699 is not specified.
        (leon3_load): Rename into...
        (ut699_load): ...this.  Enable for all LEON variants if -mfix-ut699
        is specified.

-- 
Eric Botcazou
Index: config/sparc/leon.md
===================================================================
--- config/sparc/leon.md	(revision 225111)
+++ config/sparc/leon.md	(working copy)
@@ -24,12 +24,14 @@ (define_automaton "leon")
 (define_cpu_unit "leon_memory" "leon")
 
 (define_insn_reservation "leon_load" 1
-  (and (eq_attr "cpu" "leon") (eq_attr "type" "load,sload"))
+  (and (eq_attr "cpu" "leon,leon3,leon3v7")
+       (and (eq_attr "fix_ut699" "false") (eq_attr "type" "load,sload")))
   "leon_memory")
 
 ;; Use a double reservation to work around the load pipeline hazard on UT699.
-(define_insn_reservation "leon3_load" 1
-  (and (eq_attr "cpu" "leon3,leon3v7") (eq_attr "type" "load,sload"))
+(define_insn_reservation "ut699_load" 1
+  (and (eq_attr "cpu" "leon,leon3,leon3v7")
+       (and (eq_attr "fix_ut699" "true") (eq_attr "type" "load,sload")))
   "leon_memory*2")
 
 (define_insn_reservation "leon_store" 2

Reply via email to