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]

PATCH: pa8000-specific changes


This patch makes 3 changes to the pa8000.  It removes autoincrement and 
autodecrement addressing, disables pa_combine_instructions, and removes cost
adjustment. 

I'm also submitting an adjustment to the 7100LC/7200 function unit
descriptions.  There are two changes:

1) pa7100LCalu SIMULTANEITY goes from 2 to 1.  This seems consistent with the
docs

2) pa7100LCalu now accepts all non-fp operations.  The pa7100LCshiftmem still
restricts load/store and shift to one per cycle.  Richard Henderson had
commented that we could in fact model the shift and mem ops executing in only
one of the two alu's and pointed me to alpha.md for examples.  This change
does the same kind of thing.

I'm not sure this will have any real impact, but it seems to be a more
accurate description.

egcs bootstraps with these changes.

-- 
Jerry Quinn                             Tel: (514) 761-8737
jquinn@nortelnetworks.com               Fax: (514) 761-8505
Speech Recognition Research

diff -c -r egcs-19990321/gcc/config/pa/pa.c src/gcc/config/pa/pa.c
*** egcs-19990321/gcc/config/pa/pa.c	Wed Mar 17 14:46:34 1999
--- src/gcc/config/pa/pa.c	Mon Mar 22 11:53:22 1999
***************
*** 3318,3323 ****
--- 3364,3373 ----
    if (! recog_memoized (insn))
      return 0;
  
+   /* Don't adjust costs for a pa8000 chip.  */
+   if (pa_cpu >= PROCESSOR_8000)
+     return cost;
+ 
    attr_type = get_attr_type (insn);
  
    if (REG_NOTE_KIND (link) == 0)
***************
*** 6030,6036 ****
  
    remove_useless_addtr_insns (insns, 1);
  
!   pa_combine_instructions (get_insns ());
  
    /* This is fairly cheap, so always run it if optimizing.  */
    if (optimize > 0 && !TARGET_BIG_SWITCH)
--- 6080,6087 ----
  
    remove_useless_addtr_insns (insns, 1);
  
!   if (pa_cpu < PROCESSOR_8000)
!     pa_combine_instructions (get_insns ());
  
    /* This is fairly cheap, so always run it if optimizing.  */
    if (optimize > 0 && !TARGET_BIG_SWITCH)
diff -c -r egcs-19990321/gcc/config/pa/pa.h src/gcc/config/pa/pa.h
*** egcs-19990321/gcc/config/pa/pa.h	Thu Mar 18 16:44:59 1999
--- src/gcc/config/pa/pa.h	Mon Mar 22 11:37:45 1999
***************
*** 1380,1390 ****
  
  /* Addressing modes, and classification of registers for them.  */
  
! #define HAVE_POST_INCREMENT 1
! #define HAVE_POST_DECREMENT 1
  
! #define HAVE_PRE_DECREMENT 1
! #define HAVE_PRE_INCREMENT 1
  
  /* Macros to check register numbers against specific register classes.  */
  
--- 1401,1411 ----
  
  /* Addressing modes, and classification of registers for them.  */
  
! #define HAVE_POST_INCREMENT (pa_cpu < 8000)
! #define HAVE_POST_DECREMENT (pa_cpu < 8000)
  
! #define HAVE_PRE_DECREMENT (pa_cpu < 8000)
! #define HAVE_PRE_INCREMENT (pa_cpu < 8000)
  
  /* Macros to check register numbers against specific register classes.  */
  
diff -c -r egcs-19990321/gcc/config/pa/pa.md src/gcc/config/pa/pa.md
*** egcs-19990321/gcc/config/pa/pa.md	Wed Mar 17 15:15:18 1999
--- src/gcc/config/pa/pa.md	Mon Mar 22 11:48:53 1999
***************
*** 323,339 ****
      (eq_attr "type" "fpcc,fpalu,fpmulsgl,fpmuldbl,fpdivsgl,fpsqrtsgl,fpdivdbl,fpsqrtdbl")
      (eq_attr "cpu" "7100LC,7200")) 1 1)
  
! ;; Shifts and memory ops actually execute in one of the integer
! ;; ALUs, but we can't really model that.
  (define_function_unit "pa7100LCshiftmem" 1 1
    (and
      (eq_attr "type" "shift,nullshift,load,fpload,store,fpstore")
      (eq_attr "cpu" "7100LC,7200")) 1 1)
  
  ;; We have two basic ALUs.
! (define_function_unit "pa7100LCalu" 2 2
    (and
!     (eq_attr "type" "!fpcc,fpalu,fpmulsgl,fpmuldbl,fpdivsgl,fpsqrtsgl,fpdivdbl,fpsqrtdbl,load,fpload,store,fpstore,shift,nullshift")
     (eq_attr "cpu" "7100LC,7200")) 1 1)
  
  ;; I don't have complete information on the PA7200; however, most of
--- 323,338 ----
      (eq_attr "type" "fpcc,fpalu,fpmulsgl,fpmuldbl,fpdivsgl,fpsqrtsgl,fpdivdbl,fpsqrtdbl")
      (eq_attr "cpu" "7100LC,7200")) 1 1)
  
! ;; Shifts and memory ops execute in only one of the integer ALUs
  (define_function_unit "pa7100LCshiftmem" 1 1
    (and
      (eq_attr "type" "shift,nullshift,load,fpload,store,fpstore")
      (eq_attr "cpu" "7100LC,7200")) 1 1)
  
  ;; We have two basic ALUs.
! (define_function_unit "pa7100LCalu" 2 1
    (and
!     (eq_attr "type" "!fpcc,fpalu,fpmulsgl,fpmuldbl,fpdivsgl,fpsqrtsgl,fpdivdbl,fpsqrtdbl")
     (eq_attr "cpu" "7100LC,7200")) 1 1)
  
  ;; I don't have complete information on the PA7200; however, most of



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