stage2 大量优化代码使其自举编译时间大幅缩短

This commit is contained in:
zzy committed 2026-09-20 09:33:20 +08:00
1 parent e02b0c633a
commit 846f441e3a
38 files changed
+2418 -835

No files matched your search

+5 -1
View File
@@ -23,6 +23,9 @@ typedef VEC(spl_callframe_t) spl_frame_vec_t;
typedef struct {
MAP(const char *, usize) stacks;
VEC(usize) self_samples;
VEC(uint64_t) self_ns; /* 每函数 time-slice 累加(纳秒) */
uint64_t last_ns;
uint64_t total_ns;
usize samples;
} spl_prof_t;
@@ -34,7 +37,8 @@ typedef struct spl_vm {
uintptr_t fp; // frame pointer
uintptr_t cp; // call pointer
uintptr_t ip; // instr pointer
uint64_t steps; // 已执行指令数(供性能分析参考)
uint64_t steps; // 已执行指令数(供性能分析参考)
uint64_t ncalls; // 已执行 CALL/CALLI 次数(供性能分析参考)
int exit_code;
int trace; /* non-zero to print each instruction */
int debug; /* non-zero to enable canary checks */