[midend-llvmprint]更新脚本,支持-eir执行IR测试

This commit is contained in:
Lixuanwang
2025-08-07 23:45:26 +08:00
parent ba21bb3203
commit c507b98199
3 changed files with 455 additions and 310 deletions

View File

@@ -145,7 +145,7 @@ int main(int argc, char **argv) {
// a) 如果指定停止在 IR 阶段,则打印最终 IR 并退出
if (argStopAfter == "ir" || argStopAfter == "ird") {
// 打印最终 IR
cout << "=== Final IR ===\n";
if (DEBUG) cerr << "=== Final IR ===\n";
if (!argOutputFilename.empty()) {
// 输出到指定文件
ofstream fout(argOutputFilename);