[patch,avr,committed]: Fix coding rules.

2014-10-23 Thread Georg-Johann Lay
This no-op change fixed typos and restored coding rules as obvious like: 
spaces around operators, space before opening parentheses, wrapping long lines, 
indentation rules, trailing blanks, etc...


http://gcc.gnu.org/r216592


Johann

gcc/
* config/avr/avr.c: Fix GNU coding rules and typos.
* config/avr/avr.h: Dito.
* config/avr/avr-c.c: Dito.
* config/avr/avr.md: Dito.
Index: config/avr/avr.md
===
--- config/avr/avr.md	(revision 216591)
+++ config/avr/avr.md	(revision 216592)
@@ -64,8 +64,8 @@ (define_constants
])
 
 (define_constants
-  [ (TMP_REGNO_TINY 16)  ; r16 is temp register for AVR_TINY
-(ZERO_REGNO_TINY 17) ; r17 is zero register for AVR_TINY
+  [(TMP_REGNO_TINY  16) ; r16 is temp register for AVR_TINY
+   (ZERO_REGNO_TINY 17) ; r17 is zero register for AVR_TINY
   ])
 
 (define_c_enum "unspec"
@@ -640,32 +640,31 @@ (define_expand "mov"
 DONE;
   }
 
-/* AVRTC-579
-if the source operand expression is out of range for 'lds' instruction
-  copy source operand expression to register
-For tiny core, LDS instruction's memory access range limited to 0x40..0xbf
-*/
-if (!tiny_valid_direct_memory_access_range(src,mode))
+// AVRTC-579
+// If the source operand expression is out of range for LDS instruction
+// copy source operand expression to register.
+// For tiny core, LDS instruction's memory access range limited to 0x40..0xbf.
+
+if (!tiny_valid_direct_memory_access_range (src, mode))
   {
-rtx srcx = XEXP(src,0);
-operands[1] = src = replace_equiv_address (src,copy_to_mode_reg (GET_MODE(srcx),srcx));
-emit_move_insn(dest,src);
+rtx srcx = XEXP (src, 0);
+operands[1] = src = replace_equiv_address (src, copy_to_mode_reg (GET_MODE (srcx), srcx));
+emit_move_insn (dest, src);
 DONE;
   }
 
-/* AVRTC-579
-if the destination operand expression is out of range for 'sts' instruction
-  copy destination operand expression to register
-For tiny core, STS instruction's memory access range limited to 0x40..0xbf
-*/
-if (!tiny_valid_direct_memory_access_range(dest,mode))
-{
-  rtx destx = XEXP(dest,0);
-  operands[0] = dest = replace_equiv_address (dest,copy_to_mode_reg (GET_MODE(destx),destx));
-  emit_move_insn(dest,src);
-  DONE;
-}
+// AVRTC-579
+// If the destination operand expression is out of range for STS instruction
+// copy destination operand expression to register.
+// For tiny core, STS instruction's memory access range limited to 0x40..0xbf.
 
+if (!tiny_valid_direct_memory_access_range (dest, mode))
+  {
+rtx destx = XEXP (dest, 0);
+operands[0] = dest = replace_equiv_address (dest, copy_to_mode_reg (GET_MODE (destx), destx));
+emit_move_insn (dest, src);
+DONE;
+  }
   })
 
 ;;
@@ -683,12 +682,12 @@ (define_insn "mov_insn"
   [(set (match_operand:ALL1 0 "nonimmediate_operand" "=r,d,Qm   ,r ,q,r,*r")
 (match_operand:ALL1 1 "nox_general_operand"   "r Y00,n Ynn,r Y00,Qm,r,q,i"))]
   "(register_operand (operands[0], mode)
-   || reg_or_0_operand (operands[1], mode)) &&
-   /* skip if operands are out of lds/sts memory access range(0x40..0xbf)
-   though access range is checked during define_expand, it is required
-   here to avoid merging rtls during combine pass */
-   tiny_valid_direct_memory_access_range(operands[0],QImode) &&
-   tiny_valid_direct_memory_access_range(operands[1],QImode)"
+|| reg_or_0_operand (operands[1], mode))
+   /* Skip if operands are out of lds/sts memory access range(0x40..0xbf)
+  though access range is checked during define_expand, it is required
+  here to avoid merging RTXes during combine pass.  */
+   && tiny_valid_direct_memory_access_range (operands[0], QImode)
+   && tiny_valid_direct_memory_access_range (operands[1], QImode)"
   {
 return output_movqi (insn, operands, NULL);
   }
@@ -782,12 +781,12 @@ (define_insn "*mov"
   [(set (match_operand:ALL2 0 "nonimmediate_operand" "=r,r  ,r,m,d,*r,q,r")
 (match_operand:ALL2 1 "nox_general_operand"   "r,Y00,m,r Y00,i,i ,r,q"))]
   "(register_operand (operands[0], mode)
-   || reg_or_0_operand (operands[1], mode)) &&
-   /* skip if operands are out of lds/sts memory access range(0x40..0xbf)
-   though access range is checked during define_expand, it is required
-   here to avoid merging rtls during combine pass */
-   tiny_valid_direct_memory_access_range(operands[0],HImode) &&
-   tiny_valid_direct_memory_access_range(operands[1],HImode)"
+|| reg_or_0_operand (operands[1], mode))
+   /* Skip if operands are out of lds/sts memory access range(0x40..0xbf)
+  though access range is checked during define_expand, it is required
+  here to avoid merging RTXes during combi

Re: [patch,avr,committed]: Fix coding rules.

2014-10-23 Thread Denis Chertykov
2014-10-23 16:33 GMT+04:00 Georg-Johann Lay :
> This no-op change fixed typos and restored coding rules as obvious like:
> spaces around operators, space before opening parentheses, wrapping long
> lines, indentation rules, trailing blanks, etc...
>
> http://gcc.gnu.org/r216592
>
>
> Johann
>
> gcc/
> * config/avr/avr.c: Fix GNU coding rules and typos.
> * config/avr/avr.h: Dito.
> * config/avr/avr-c.c: Dito.
> * config/avr/avr.md: Dito.

Thank you.

Denis.