OSDN Git Service

* config/picochip/picochip.c (picochip_override_options): Disable CFI
authorhariharans <hariharans@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 15 Dec 2008 16:20:44 +0000 (16:20 +0000)
committerhariharans <hariharans@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 15 Dec 2008 16:20:44 +0000 (16:20 +0000)
        asm and change the signature of brev and byteSwap functions to use
        unsigned values.
        * config/picochip/picochip.md (commsTestPort): This is a complex
        instruction and should not be vliwed. Dont set insn type.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@142765 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/config/picochip/picochip.c
gcc/config/picochip/picochip.md

index de6eded..a531498 100644 (file)
@@ -1,5 +1,12 @@
-2008-12-15  Wolfgang Gellerich  <gellerich@de.ibm.com>
+2008-12-15  Hariharan Sandanagobalane <hariharan@picochip.com>
+
+       * config/picochip/picochip.c (picochip_override_options): Disable CFI
+       asm and change the signature of brev and byteSwap functions to use
+       unsigned values.
+       * config/picochip/picochip.md (commsTestPort): This is a complex
+       instruction and should not be vliwed. Dont set insn type.
 
+2008-12-15  Wolfgang Gellerich  <gellerich@de.ibm.com>
        * config/s390/s390.c (s390_swap_cmp): New function.
        (s390_non_addr_reg_read_p): New function.
        (s390_z10_optimize_cmp): New function.
index 303b9e1..d929486 100644 (file)
@@ -324,6 +324,9 @@ picochip_override_options (void)
      This isnt the default at O2 as yet. */
   flag_section_anchors = 1;
 
+  /* CFI asm labels are not supported by the picochip assembler yet */
+  flag_dwarf2_cfi_asm = 0;
+
   /* Turn off the second scheduling pass, and move it to
      picochip_reorg, to avoid having the second jump optimisation
      trash the instruction modes (e.g., instructions are changed to
@@ -3914,6 +3917,7 @@ picochip_init_builtins (void)
 {
   tree endlink = void_list_node;
   tree int_endlink = tree_cons (NULL_TREE, integer_type_node, endlink);
+  tree unsigned_endlink = tree_cons (NULL_TREE, unsigned_type_node, endlink);
   tree long_endlink = tree_cons (NULL_TREE, long_integer_type_node, endlink);
   tree int_int_endlink =
     tree_cons (NULL_TREE, integer_type_node, int_endlink);
@@ -3929,7 +3933,7 @@ picochip_init_builtins (void)
   tree long_ftype_int, long_ftype_int_int, long_ftype_int_int_int;
   tree void_ftype_int_long, int_ftype_int_int_int,
     void_ftype_long_int_int_int;
-  tree void_ftype_void, void_ftype_int;
+  tree void_ftype_void, void_ftype_int, unsigned_ftype_unsigned;
 
   /* void func (void) */
   void_ftype_void = build_function_type (void_type_node, endlink);
@@ -3948,6 +3952,9 @@ picochip_init_builtins (void)
   /* int func (int) */
   int_ftype_int = build_function_type (integer_type_node, int_endlink);
 
+  /* unsigned int func (unsigned int) */
+  unsigned_ftype_unsigned = build_function_type (unsigned_type_node, unsigned_endlink);
+
   /* int func(int, int) */
   int_ftype_int_int
     = build_function_type (integer_type_node, int_int_endlink);
@@ -3991,18 +3998,18 @@ picochip_init_builtins (void)
                               NULL_TREE);
 
   /* Initialise the bit reverse function. */
-  add_builtin_function ("__builtin_brev", int_ftype_int,
+  add_builtin_function ("__builtin_brev", unsigned_ftype_unsigned,
                               PICOCHIP_BUILTIN_BREV, BUILT_IN_MD, NULL,
                               NULL_TREE);
-  add_builtin_function ("picoBrev", int_ftype_int,
+  add_builtin_function ("picoBrev", unsigned_ftype_unsigned,
                               PICOCHIP_BUILTIN_BREV, BUILT_IN_MD, NULL,
                               NULL_TREE);
 
   /* Initialise the byte swap function. */
-  add_builtin_function ("__builtin_byteswap", int_ftype_int,
+  add_builtin_function ("__builtin_byteswap", unsigned_ftype_unsigned,
                               PICOCHIP_BUILTIN_BYTESWAP, BUILT_IN_MD, NULL,
                               NULL_TREE);
-  add_builtin_function ("picoByteSwap", int_ftype_int,
+  add_builtin_function ("picoByteSwap", unsigned_ftype_unsigned,
                               PICOCHIP_BUILTIN_BYTESWAP, BUILT_IN_MD, NULL,
                               NULL_TREE);
 
index 3fe6652..fbe2280 100644 (file)
    (clobber (reg:CC CC_REGNUM))]
   ""
   "// %0 := TestPort(%1)\;TSTPORT %1\;COPYSW.0 %0\;AND.0 %0,8,%0"
-  [(set_attr "length" "9")
-   (set_attr "type" "picoAlu")])
+  [(set_attr "length" "9")])
 
 ; Entry point for array tstport (the actual port index is computed as the
 ; sum of the index, and the base).