lang: remove references to old mie api

This commit is contained in:
2026-03-16 15:07:57 +00:00
parent c44e976979
commit 016ee11f75
15 changed files with 170 additions and 104 deletions

View File

@@ -3,9 +3,6 @@
#include <assert.h>
#include <mie/ir/block.h>
#include <mie/ir/func.h>
#include <mie/ir/phi.h>
#include <mie/ir/value.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
@@ -44,8 +41,6 @@ static enum ivy_status state_init(
debug_printf("codegen: start of cond group\n");
struct cond_group_codegen_state *group
= (struct cond_group_codegen_state *)state;
struct mie_func *func = mie_builder_get_current_func(gen->c_builder);
group->s_end = mie_func_create_block(func, "if.end");
return IVY_OK;
}
@@ -53,6 +48,7 @@ static enum ivy_status get_eval_type(
struct ivy_codegen *gen, struct cond_group_codegen_state *state,
struct mie_type **out)
{
#if 0
struct mie_type *type = NULL;
fx_queue_entry *entry = fx_queue_first(&state->s_edges);
@@ -76,8 +72,11 @@ static enum ivy_status get_eval_type(
*out = type;
return IVY_OK;
#endif
return IVY_ERR_NOT_SUPPORTED;
}
#if 0
static enum ivy_status emit_phi_instr(
struct ivy_codegen *gen, struct cond_group_codegen_state *state,
struct mie_type *type, struct mie_value **result)
@@ -110,6 +109,7 @@ static enum ivy_status emit_phi_instr(
return IVY_OK;
}
#endif
static enum ivy_status state_fini(
struct ivy_codegen *gen, struct code_generator_state *state,
@@ -118,6 +118,7 @@ static enum ivy_status state_fini(
debug_printf("codegen: end of cond group\n");
struct cond_group_codegen_state *group
= (struct cond_group_codegen_state *)state;
#if 0
struct mie_func *func = mie_builder_get_current_func(gen->c_builder);
struct mie_block *block = mie_builder_get_current_block(gen->c_builder);
@@ -148,6 +149,8 @@ static enum ivy_status state_fini(
}
return IVY_OK;
#endif
return IVY_ERR_NOT_SUPPORTED;
}
static struct code_generator_result value_received(
@@ -156,12 +159,15 @@ static struct code_generator_result value_received(
{
struct cond_group_codegen_state *cond
= (struct cond_group_codegen_state *)state;
#if 0
assert(value->v_type == CODE_GENERATOR_VALUE_PHI_EDGE);
struct mie_phi_edge *edge = code_generator_value_get_phi_edge(value);
fx_queue_push_back(&cond->s_edges, &edge->e_entry);
return CODEGEN_RESULT_OK(0);
#endif
return CODEGEN_RESULT_ERR(IVY_ERR_NOT_SUPPORTED);
}
struct code_generator cond_group_generator = {