Began adding the code generation framework.
[fw/sdcc] / src / izt / gen.h
1 // izt specific gen functions.
2 #ifndef IZT_GEN_INCLUDE
3 #define IZT_GEN_INCLUDE
4
5 // Emit a line of code.
6 void iemit(const char *format, ...);
7
8 // Generic descripter for a function that can emit a type of iCode.
9 typedef struct {
10     int op;
11     void (*emit)(iCode *ic);
12 } EMITTER;
13
14 // Call the base izt handler to handle this iCode.
15 void izt_baseEmitter(iCode *ic);
16 // Initialise the base emitter table.
17 void izt_initBaseEmitters(hTab **into);
18 // Add a NULL terminated array of emitters into the given hash table.
19 void izt_addEmittersToHTab(hTab **into, EMITTER _base_emitters[]);
20 // Initialise the emitter tables.
21 void izt_initEmitters(void);
22
23 #endif
24