annotate mc-codegen.h @ 327:da2e3f2d127d

macro/codegen reorganization
author kono
date Mon, 21 Jun 2004 23:50:34 +0900
parents 183726ccd83d
children 7ecb023d29b8
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
144
56211702f298 creg/freg continue
kono
parents: 138
diff changeset
1 /* for mc-codegen.c */
61
8ffb8ca3fe34 separation of architecture dependent part.
kono
parents:
diff changeset
2
221
ceae585186d9 *** empty log message ***
kono
parents: 195
diff changeset
3 extern int use; /* generated value will be used in gexpr */
327
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
4 extern char *init_src;
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
5 extern int size_of_int;
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
6 extern int size_of_short;
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
7 extern int size_of_float;
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
8 extern int size_of_double;
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
9 extern int size_of_longlong;
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
10 extern int bit_of_byte;
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
11 extern int endian;
83
f3f75911d62c *** empty log message ***
kono
parents: 81
diff changeset
12
221
ceae585186d9 *** empty log message ***
kono
parents: 195
diff changeset
13 #define USE_CREG (-1)
320
183726ccd83d asm minor fix. ia32 table jmp fix.
kono
parents: 305
diff changeset
14 #define ASM_INPUT 1
183726ccd83d asm minor fix. ia32 table jmp fix.
kono
parents: 305
diff changeset
15 #define ASM_OUTPUT 2
183726ccd83d asm minor fix. ia32 table jmp fix.
kono
parents: 305
diff changeset
16 #define ASM_USED 3
183726ccd83d asm minor fix. ia32 table jmp fix.
kono
parents: 305
diff changeset
17 #define MAX_ASM_REG 30
61
8ffb8ca3fe34 separation of architecture dependent part.
kono
parents:
diff changeset
18
327
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
19 /* used by mc-parse */
104
c21aeb12b78b *** empty log message ***
kono
parents: 102
diff changeset
20
327
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
21 extern int rvalue(int e);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
22 extern int rvalue_t(int e,int t);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
23 extern int integral(int t);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
24
137
9fb09db54436 fix powerpc get_fregister_var's regs error.
kono
parents: 133
diff changeset
25
9fb09db54436 fix powerpc get_fregister_var's regs error.
kono
parents: 133
diff changeset
26 extern void arg_register(NMTBL *fnptr);
327
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
27 extern int arg_reorder(int arg,int new_arg);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
28 extern int assign_data(int e, int t, NMTBL *n,int offset);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
29 extern int assop(int e1,int e2,int op,int t,int no_float);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
30 extern int backdef(void);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
31 extern int cexpr(int e);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
32 extern void checkret(void);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
33 extern void closing();
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
34 extern void cmpdimm(int e, int csreg,int label,int cond);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
35 extern void codegen_init(); /* called only once */
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
36 extern void codegen_reinit(); /* called for each file */
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
37 extern void codegen_decl_init(); /* called before each declaration */
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
38 extern int cond(int t,int e1,int e2,int e3);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
39 extern int correct_type(int e,int t);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
40 extern int csvalue();
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
41 extern void def_label(int cslabel, int dlabel);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
42 extern void emit_init_vars(void);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
43 extern void fdecl_struct(int fntype);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
44 extern int function_type(int e1,int *dots);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
45 extern void lcheck(int e);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
46 extern void opening(char *filename);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
47 extern void parallel_rassign(int assigns);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
48 extern int strop(int e,int ind);
102
3cf2f8c120b9 *** empty log message ***
kono
parents: 99
diff changeset
49
61
8ffb8ca3fe34 separation of architecture dependent part.
kono
parents:
diff changeset
50 extern void def_label(int cslabel, int dlabel);
327
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
51 extern NMTBL * def(NMTBL *n);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
52 extern int search_struct_type(int type,char *name,int *dsp);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
53 extern int gexpr(int e1,int use0);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
54 extern void bexpr_u(int e1, char cond, int l1);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
55 extern void bexpr(int e1, char cond, int l1);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
56 extern void ret(void);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
57 extern void replace_return_struct(int func,int left);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
58 extern int assign_expr0(int e1,int e2,int t,int type0);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
59 extern int assign_expr(int e1,int e2,int t,int type);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
60 extern int binop(int op, int e1, int e2, int t1, int t2);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
61 extern int indop(int e);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
62 extern void fcheck(NMTBL *n);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
63
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
64 extern void init_free_lvar_list();
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
65 extern void free_lvar(int disp);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
66 extern int new_lvar(int size);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
67 extern int new_lvar0(int sz);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
68
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
69 extern void gen_code_enter(char *name);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
70 extern void gen_code_enter1(int args);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
71 extern void gen_code_leave(char *name);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
72 extern void gen_enter(char *name);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
73 extern void gen_enter1();
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
74 extern void gen_leave(int control, char *name);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
75 extern void gen_jmp(int l);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
76
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
77
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
78 extern int assign_expr0(int e1,int e2,int t,int type0) ;
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
79 extern int assign_expr(int e1,int e2,int t,int type) ;
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
80 extern void bexpr_u(int e1, char cond, int l1);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
81 extern int binop(int op, int e1, int e2, int t1, int t2);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
82 extern void fcheck(NMTBL *n);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
83 extern void replace_return_struct(int func,int left) ;
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
84 extern int gexpr(int e1,int use0);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
85 extern void bexpr_u(int e1, char cond, int l1);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
86 extern void bexpr(int e1, char cond, int l1);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
87 extern void ret(void);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
88 extern void def_label(int cslabel, int dlabel);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
89 extern NMTBL * def(NMTBL *n);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
90 extern int indop(int e);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
91 extern int search_struct_type(int type,char *name,int *dsp);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
92
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
93 /* used by mc-cod-* */
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
94
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
95 extern int assign_expr0(int e1,int e2,int t,int type0) ;
61
8ffb8ca3fe34 separation of architecture dependent part.
kono
parents:
diff changeset
96 extern void b_expr(int e1, char cond, int l1,int err);
327
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
97 extern int contains_p(int e,int (*p)(int));
61
8ffb8ca3fe34 separation of architecture dependent part.
kono
parents:
diff changeset
98 extern void fwddef(int l);
327
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
99 extern int fwdlabel(void);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
100 extern int g_expr(int e1);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
101 extern int g_expr0(int e1);
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
102 extern int g_expr_u(int e1);
98
07c2554e1cfa *** empty log message ***
kono
parents: 95
diff changeset
103 extern int is_code(NMTBL *fnptr);
07c2554e1cfa *** empty log message ***
kono
parents: 95
diff changeset
104 extern int is_function(NMTBL *fnptr);
327
da2e3f2d127d macro/codegen reorganization
kono
parents: 320
diff changeset
105 extern int scalar(int t);
61
8ffb8ca3fe34 separation of architecture dependent part.
kono
parents:
diff changeset
106
8ffb8ca3fe34 separation of architecture dependent part.
kono
parents:
diff changeset
107 /* end */