]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
s390.c (s390_extract_part, [...]): Type cast added.
authorAndreas Krebbel <krebbel1@de.ibm.com>
Fri, 12 Aug 2005 12:10:30 +0000 (12:10 +0000)
committerUlrich Weigand <uweigand@gcc.gnu.org>
Fri, 12 Aug 2005 12:10:30 +0000 (12:10 +0000)
2005-08-12  Andreas Krebbel  <krebbel1@de.ibm.com>

* config/s390/s390.c (s390_extract_part, s390_single_part):
Type cast added.
(s390_const_ok_for_constraint_p): Added SImode to the N constraint.
(s390_output_mi_thunk): Don't use lg on 31 bit.
* config/s390/s390.md ("*movdi_31", "*movdf_31"): Added lmy and stmy.
("*llgt_sisi" and splitter): Replaced TARGET_64BIT with TARGET_ZARCH.

From-SVN: r103027

gcc/ChangeLog
gcc/config/s390/s390.c
gcc/config/s390/s390.md

index 1c62e46469418397ccd0062a4df34abfd94abf7d..8378a7f504edb27160e0ca16b13f9eadb33122af 100644 (file)
@@ -1,3 +1,12 @@
+2005-08-12  Andreas Krebbel  <krebbel1@de.ibm.com>
+
+       * config/s390/s390.c (s390_extract_part, s390_single_part):
+       Type cast added.
+       (s390_const_ok_for_constraint_p): Added SImode to the N constraint.
+       (s390_output_mi_thunk): Don't use lg on 31 bit.
+       * config/s390/s390.md ("*movdi_31", "*movdf_31"): Added lmy and stmy.
+       ("*llgt_sisi" and splitter): Replaced TARGET_64BIT with TARGET_ZARCH.
+
 2005-08-12  Andreas Krebbel  <krebbel1@de.ibm.com>
 
        * config/s390/s390.c (CONST_OK_FOR_J, CONST_OK_FOR_K): New macros.
index 3a8c3a40ad7a0467ade4e553b543a446987ad3d2..551ffedbc8008972fded6989cc23728a798f6302 100644 (file)
@@ -947,7 +947,8 @@ s390_extract_part (rtx op, enum machine_mode mode, int def)
   unsigned HOST_WIDE_INT value = 0;
   int max_parts = HOST_BITS_PER_WIDE_INT / GET_MODE_BITSIZE (mode);
   int part_bits = GET_MODE_BITSIZE (mode);
-  unsigned HOST_WIDE_INT part_mask = (1 << part_bits) - 1;
+  unsigned HOST_WIDE_INT part_mask
+    = ((unsigned HOST_WIDE_INT)1 << part_bits) - 1;
   int i;
 
   for (i = 0; i < max_parts; i++)
@@ -976,7 +977,8 @@ s390_single_part (rtx op,
 {
   unsigned HOST_WIDE_INT value = 0;
   int n_parts = GET_MODE_SIZE (mode) / GET_MODE_SIZE (part_mode);
-  unsigned HOST_WIDE_INT part_mask = (1 << GET_MODE_BITSIZE (part_mode)) - 1;
+  unsigned HOST_WIDE_INT part_mask
+    = ((unsigned HOST_WIDE_INT)1 << GET_MODE_BITSIZE (part_mode)) - 1;
   int i, part = -1;
 
   if (GET_CODE (op) != CONST_INT)
@@ -1835,8 +1837,9 @@ s390_const_ok_for_constraint_p (HOST_WIDE_INT value,
 
       switch (str[2])
        {
-       case 'H': part_mode = HImode; break;
-       case 'Q': part_mode = QImode; break;
+       case 'Q': part_mode = QImode; break;
+       case 'H': part_mode = HImode; break;
+       case 'S': part_mode = SImode; break;
        default:  return 0;
        }
 
@@ -7780,12 +7783,12 @@ s390_output_mi_thunk (FILE *file, tree thunk ATTRIBUTE_UNUSED,
         {
          if (CONST_OK_FOR_J (vcall_offset))
            {
-             output_asm_insn ("lg\t%4,0(%1)", op);
+             output_asm_insn ("l\t%4,0(%1)", op);
              output_asm_insn ("a\t%1,%3(%4)", op);
            }
          else if (DISP_IN_RANGE (vcall_offset))
            {
-             output_asm_insn ("lg\t%4,0(%1)", op);
+             output_asm_insn ("l\t%4,0(%1)", op);
              output_asm_insn ("ay\t%1,%3(%4)", op);
            }
          else if (CONST_OK_FOR_K (vcall_offset))
index 453191457d69b61b0100a30fa639c11ab7973f06..ee87cf6938b72e8fef26d791a39f05b0930e1ba0 100644 (file)
    s390_split_access_reg (operands[0], &operands[3], &operands[4]);")
 
 (define_insn "*movdi_31"
-  [(set (match_operand:DI 0 "nonimmediate_operand" "=d,Q,d,o,!*f,!*f,!*f,!R,!T,Q")
-        (match_operand:DI 1 "general_operand" "Q,d,dKm,d,*f,R,T,*f,*f,Q"))]
+  [(set (match_operand:DI 0 "nonimmediate_operand" "=d,d,Q,S,d,o,!*f,!*f,!*f,!R,!T,Q")
+        (match_operand:DI 1 "general_operand" "Q,S,d,d,dKm,d,*f,R,T,*f,*f,Q"))]
   "!TARGET_64BIT"
   "@
    lm\t%0,%N0,%S1
+   lmy\t%0,%N0,%S1
    stm\t%1,%N1,%S0
+   stmy\t%1,%N1,%S0
    #
    #
    ldr\t%0,%1
    std\t%1,%0
    stdy\t%1,%0
    #"
-  [(set_attr "op_type" "RS,RS,*,*,RR,RX,RXY,RX,RXY,SS")
-   (set_attr "type" "lm,stm,*,*,floaddf,floaddf,floaddf,fstoredf,fstoredf,*")])
+  [(set_attr "op_type" "RS,RSY,RS,RSY,*,*,RR,RX,RXY,RX,RXY,SS")
+   (set_attr "type" "lm,lm,stm,stm,*,*,floaddf,floaddf,floaddf,fstoredf,fstoredf,*")])
 
 (define_split
   [(set (match_operand:DI 0 "nonimmediate_operand" "")
    (set_attr "type" "fsimpdf,floaddf,floaddf,floaddf,fstoredf,fstoredf,lr,load,store,*")])
 
 (define_insn "*movdf_31"
-  [(set (match_operand:DF 0 "nonimmediate_operand" "=f,f,f,f,R,T,d,Q,d,o,Q")
-        (match_operand:DF 1 "general_operand" "G,f,R,T,f,f,Q,d,dKm,d,Q"))]
+  [(set (match_operand:DF 0 "nonimmediate_operand" "=f,f,f,f,R,T,d,d,Q,S,d,o,Q")
+        (match_operand:DF 1 "general_operand" "G,f,R,T,f,f,Q,S,d,d,dPm,d,Q"))]
   "!TARGET_64BIT"
   "@
    lzdr\t%0
    std\t%1,%0
    stdy\t%1,%0
    lm\t%0,%N0,%S1
+   lmy\t%0,%N0,%S1
    stm\t%1,%N1,%S0
+   stmy\t%1,%N1,%S0
    #
    #
    #"
-  [(set_attr "op_type" "RRE,RR,RX,RXY,RX,RXY,RS,RS,*,*,SS")
-   (set_attr "type" "fsimpdf,floaddf,floaddf,floaddf,fstoredf,fstoredf,lm,stm,*,*,*")])
+  [(set_attr "op_type" "RRE,RR,RX,RXY,RX,RXY,RS,RSY,RS,RSY,*,*,SS")
+   (set_attr "type" "fsimpdf,floaddf,floaddf,floaddf,fstoredf,fstoredf,\
+                     lm,lm,stm,stm,*,*,*")])
 
 (define_split
   [(set (match_operand:DF 0 "nonimmediate_operand" "")
   [(set (match_operand:SI 0 "register_operand" "=d,d")
         (and:SI (match_operand:SI 1 "nonimmediate_operand" "d,m")
                (const_int 2147483647)))]
-  "TARGET_64BIT"
+  "TARGET_ZARCH"
   "@
    llgtr\t%0,%1
    llgt\t%0,%1"
         (and:GPR (match_operand:GPR 1 "nonimmediate_operand" "")
                  (const_int 2147483647)))
    (clobber (reg:CC CC_REGNUM))]
-  "TARGET_64BIT && reload_completed"
+  "TARGET_ZARCH && reload_completed"
   [(set (match_dup 0)
         (and:GPR (match_dup 1)
                  (const_int 2147483647)))]