X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=ir%2Fbe%2Fbearch.h;h=a3b2a252fcc9b79e4b27d77f3a9913a96c9670a8;hb=93e10ae9191c0247b78772c2611b753decedb917;hp=59bcacc11a36a79f1d6d8fb83b22dcdef93ad8ae;hpb=d79818212e10cc5b2667d90d34c7fc6b9ede13ce;p=libfirm diff --git a/ir/be/bearch.h b/ir/be/bearch.h index 59bcacc11..a3b2a252f 100644 --- a/ir/be/bearch.h +++ b/ir/be/bearch.h @@ -327,7 +327,7 @@ arch_get_irn_reg_class(const arch_env_t *env, const ir_node *irn, int pos); /** * Get the register allocated at a certain output operand of a node. - * @param env The arch nvironment. + * @param env The arch environment. * @param irn The node. * @return The register allocated for this operand */ @@ -384,6 +384,16 @@ struct _arch_irn_handler_t { */ struct _arch_code_generator_if_t { + + /** + * Initialize the code generator. + * @param file The file to dump to. + * @param irg The function to generate code for. + * @param env The architecture environment. + * @return A newly created code generator. + */ + void *(*init)(FILE *file, ir_graph *irg, const arch_env_t *env); + /** * Called, when the graph is being normalized. */ @@ -444,7 +454,7 @@ struct _arch_isa_if_t { /** * Initialize the isa interface. */ - void *(*init)(FILE *file_handle); + void *(*init)(void); /** * Free the isa instance. @@ -473,12 +483,11 @@ struct _arch_isa_if_t { const arch_irn_handler_t *(*get_irn_handler)(const void *self); /** - * Produce a new code generator. + * Get the code generator interface. * @param self The this pointer. - * @param irg The graph for which code shall be generated. - * @return A code generator. + * @return Some code generator interface. */ - arch_code_generator_t *(*make_code_generator)(void *self, ir_graph *irg); + const arch_code_generator_if_t *(*get_code_generator)(void *self); /** * Get the list scheduler to use. @@ -522,7 +531,7 @@ struct _arch_env_t { * @param isa The isa which shall be put into the environment. * @return The environment. */ -extern arch_env_t *arch_env_init(arch_env_t *env, const arch_isa_if_t *isa, FILE *file_handle); +extern arch_env_t *arch_env_init(arch_env_t *env, const arch_isa_if_t *isa); /** * Add a node handler to the environment.