mie: op: add data structure for op successors
This commit is contained in:
@@ -19,12 +19,8 @@ struct mie_op_definition;
|
|||||||
|
|
||||||
enum mie_op_flags {
|
enum mie_op_flags {
|
||||||
MIE_OP_F_OP_RESOLVED = 0x01u,
|
MIE_OP_F_OP_RESOLVED = 0x01u,
|
||||||
MIE_OP_F_ARGS_RESOLVED = 0x02u,
|
MIE_OP_F_ARG_RESOLVED = 0x02u,
|
||||||
};
|
MIE_OP_F_SUCCESSOR_RESOLVED = 0x04u,
|
||||||
|
|
||||||
struct mie_op_successor {
|
|
||||||
struct mie_block *s_block;
|
|
||||||
MIE_VECTOR_DECLARE(struct mie_register *, s_params);
|
|
||||||
};
|
};
|
||||||
|
|
||||||
struct mie_op_attribute {
|
struct mie_op_attribute {
|
||||||
@@ -33,19 +29,33 @@ struct mie_op_attribute {
|
|||||||
};
|
};
|
||||||
|
|
||||||
struct mie_op_arg {
|
struct mie_op_arg {
|
||||||
|
enum mie_op_flags arg_flags;
|
||||||
struct mie_file_span arg_span;
|
struct mie_file_span arg_span;
|
||||||
union {
|
union {
|
||||||
/* only valid if the parent op's F_ARGS_RESOLVED flag is set */
|
/* only valid if F_ARG_RESOLVED is set in arg_flags */
|
||||||
struct mie_register *arg_value;
|
struct mie_register *arg_value;
|
||||||
/* only valid if the parent op's F_ARGS_RESOLVED flag is NOT set */
|
/* only valid if F_ARG_RESOLVED is NOT set in arg_flags */
|
||||||
struct mie_register_ref arg_unresolved;
|
struct mie_register_ref arg_unresolved;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
struct mie_op_successor {
|
||||||
|
enum mie_op_flags s_flags;
|
||||||
|
|
||||||
|
union {
|
||||||
|
/* only valid if F_SUCCESSOR_RESOLVED is set in s_flags; */
|
||||||
|
struct mie_block *s_block;
|
||||||
|
/* only valid if F_SUCCESSOR_RESOLVED is NOT set in s_flags; */
|
||||||
|
char *s_block_name;
|
||||||
|
};
|
||||||
|
|
||||||
|
MIE_VECTOR_DECLARE(struct mie_op_arg, s_args);
|
||||||
|
};
|
||||||
|
|
||||||
struct mie_op {
|
struct mie_op {
|
||||||
enum mie_op_flags op_flags;
|
enum mie_op_flags op_flags;
|
||||||
|
|
||||||
/* these pointers are only valid if the F_RESOLVED flag is set */
|
/* these pointers are only valid if the F_OP_RESOLVED flag is set */
|
||||||
const struct mie_dialect *op_dialect;
|
const struct mie_dialect *op_dialect;
|
||||||
const struct mie_op_definition *op_info;
|
const struct mie_op_definition *op_info;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user