stage1 初步实现
This commit is contained in:
@@ -79,9 +79,17 @@
|
||||
* ================================================================
|
||||
*/
|
||||
|
||||
/* 调试映射:每函数 IR 节点 → 首条指令 ip(调试器显示当前 IR 节点用) */
|
||||
typedef struct {
|
||||
spl_ir_func_ref_t fid;
|
||||
VEC(usize) node_first_ip; /* 索引 = IR 节点 ref,值 = 该节点首指令绝对 ip */
|
||||
} spl_ir2vm_fdbg_t;
|
||||
typedef VEC(spl_ir2vm_fdbg_t) spl_ir2vm_fdbg_vec_t;
|
||||
|
||||
typedef struct {
|
||||
const spl_ir_t *ir;
|
||||
const spl_type_t *type;
|
||||
spl_ir2vm_fdbg_vec_t fdbg; /* ir2vm_run 后填充;splc0 -g 读取生成 debug 段 */
|
||||
} spl_ir2vm_t;
|
||||
|
||||
void spl_ir2vm_init(spl_ir2vm_t *ctx, const spl_ir_t *ir, const spl_type_t *type);
|
||||
|
||||
Reference in New Issue
Block a user