This is the mail archive of the gcc@gcc.gnu.org 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: relevant files for target backends


Thank you very much. That was exactly the information I was looking for.
I will think about a contribution to the GCC Internals.

Thanks again,
Markus Franke

Rask Ingemann Lambertsen wrote:
> On Tue, Jan 16, 2007 at 11:24:56AM +0100, Markus Franke wrote:
> 
> 
>>I am wondering where to define the prototypes for functions in
>><machine>.c Shall the prototypes be defined in <machine>-protos.h or in
>><machine>.h or in <machine>.c. As far as I understand the prototypes
>>should be defined in <machine>-protos.h, right? But if I do so several
>>errors/warnings arise because of undeclared prototypes.
> 
> 
>    All functions and variables not declared static in <machine>.c should
> have a prototype in <machine>-protos.h. Also, does this patch help?
> 
> Index: gcc/var-tracking.c
> ===================================================================
> --- gcc/var-tracking.c	(revision 120287)
> +++ gcc/var-tracking.c	(working copy)
> @@ -106,6 +106,7 @@
>  #include "expr.h"
>  #include "timevar.h"
>  #include "tree-pass.h"
> +#include "tm_p.h"
>  
>  /* Type of micro operation.  */
>  enum micro_operation_type
> 
> 
>>But there are also a lot of macros defined in <machine>.h. What kind of
>>macros should be defined in <machine>.h and which macros should be
>>defined in <machine>.c?
> 
> 
>    Those listed as macros in the documentation should go into <machine>.h
> while those listed as target hooks should go into <machine>.c.
> 
> 
>>I try to write good and standardised code in order to contribute my
>>development. I would appreciate any help. By the way, I already had a
>>look in the GCC Internals manual but I am still a bit confused.
> 
> 
>    I would like to encurage you to submit a patch for the GCC Internals
> manual to make it clearer.
>    

-- 
Nichts ist so praktisch wie eine gute Theorie!


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