[PATCH] ARM EABI alignment

Mark Mitchell mark@codesourcery.com
Fri Mar 19 08:14:00 GMT 2004


Paul Brook wrote:

>>The attached patch 
>>    
>>
>
>This time with the patch.
>  
>
Beyond Richard's comments, I have a couple. :-)

>   
>+  /* Override the default structure alignment if AAPCS is specified.  */
>+/*  if (TARGET_AAPCS)
>+    arm_structure_size_boundary = 8;*/
>+
>  
>
Why is this commented out? 

Either it should be uncommented (if it's the Right Thing), or removed.

>-      if (size == 8 || size == 32)
>+      if (size == 8 || size == 32
>+	  || (TARGET_AAPCS && size == 64))
> 	arm_structure_size_boundary = size;
>       else
>-	warning ("structure size boundary can only be set to 8 or 32");
>+	warning ("structure size boundary can only be set to 8, 32 or 64");
>     }
>  
>
That looks a bit confusing to me.  In the non-AAPCS case, if the user 
says "-mstructure-size-boundary=64" they'll get an error message saying 
that it can only be set to 8, 32, or 64.  I think we should issue the 
old message in the non-AAPCS case.

> 
>+
> const char *
>  
>
Extra blank line introduction?

>+
>+
>+unsigned int
>+arm_compute_initial_elimination_offset (unsigned int from, unsigned int to)
>  
>
This function should have a comment explaining what the arguments and 
return types are.

The rest looks good to me, modulo Richard's comments. 

I agree that -maapcs should probably become -mabi=aapcs, or some such.

Thanks!

-- 
Mark Mitchell
CodeSourcery, LLC
(916) 791-8304
mark@codesourcery.com



More information about the Gcc-patches mailing list