This is the mail archive of the 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]
Other format: [Raw text]

Re: [PATCH] MicroBlaze support - 2 of 6 - backend

On Thu, 4 Feb 2010, Michael Eager wrote:

> New files under config/microblaze can be found at

> +#ifndef __MICROBLAZE_PROTOS__
> +#define __MICROBLAZE_PROTOS__

Using names in the implementation namespace in host header files is a bad 
idea; use GCC_MICROBLAZE_PROTOS_H instead.

> Index: microblaze/microblaze.c
> +#include "c-pragma.h"

C-family headers should not be included in $target.c files.  If you are 
defining hooks for the C-family front ends, do so in separate $target-c.c 
files to avoid breaking building non-C-family front ends; otherwise, you 
shouldn't need such an include.

> +/* Define preprocessor symbols for MicroBlaze.  
> +   Symbols which do not start with __ are deprecated.  */

If you really need the deprecated names, at least do not define them if 

> +#define TARGET_XLGP_OPT		(target_flags & MASK_XLGPOPT)

The option machinery automatically defines such macros.  If you prefer the 
XLGP_OPT spelling, just change the .opt file to say Mask(XLGP_OPT), and 
you then get this macro automatically defined for you.

Joseph S. Myers

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