unable to execute command: Segmentation fault: 11

xcode编译后报错:
clang: error: unable to execute command: Segmentation fault: 11
clang: error: clang frontend command failed due to signal (use -v to see invocation)
看了网上的方法 把enable code改成了NO 重新编译还是没有变化
求教各位大佬!

declare i32 @getint() declare void @putint(i32) define i32 @main() { label_entry: %v1 = add i32 1399, 0 %op4 = call i32 @getint() br label %label5 label5: ; preds = %label_entry, %label26 %a = phi i32 [ 1, %label_entry ], [ %a_next, %label26 ] %b = phi i32 [ 1, %label_entry ], [ %b_next, %label26 ] %c = phi i32 [ %op4, %label_entry ], [ %c, %label26 ] %op7 = icmp slt i32 %a, 99999999 br i1 %op7, label %label8, label %label15 label8: ; preds = %label5 %op11 = add i32 %a, %v1 %op13 = srem i32 %op11, %c %op14 = icmp eq i32 %op13, 0 br i1 %op14, label %label18, label %label19 label15: ; preds = %label5 call void @putint(i32 %c) ret i32 %a label18: ; preds = %label8 %b_next1 = add i32 411, 0 br label %label26 label19: ; preds = %label8 %op22 = add i32 %a, %v1 %op24 = srem i32 %op22, %c %op25 = icmp eq i32 %op24, 1 br i1 %op25, label %label32, label %label33 label26: ; preds = %label18, %label40 %b_phi = phi i32 [ %b_next1, %label18 ], [ %b_val40, %label40 ] %op28 = add i32 %a, 1 %op30 = srem i32 %b_phi, 3 %a_next = add i32 %op28, %op30 %b_next = phi i32 [ %b_phi, %label18 ], [ %b_phi, %label40 ] br label %label5 label32: ; preds = %label19 %b_val32 = add i32 101, 0 br label %label40 label33: ; preds = %label19 %op36 = add i32 %a, %v1 %op38 = srem i32 %op36, %c %op39 = icmp eq i32 %op38, 3 br i1 %op39, label %label41, label %label42 label40: ; preds = %label32, %label42 %b_val40 = phi i32 [ %b_val32, %label32 ], [ %b_val42, %label42 ] br label %label26 label41: ; preds = %label33 %b_next3 = add i32 99, 0 br label %label42 label42: ; preds = %label33, %label41 %b_val42 = phi i32 [ %b_next3, %label41 ], [ %b, %label33 ] br label %label40 } sailor@sailor:~/Test/compiler-labs/tests/5-opt/warmup/ll_opt$ clang -O0 -w -no-pie opt-mem2reg-4.ll -o opt-mem2reg-4 -lsysy_io PLEASE submit a bug report to https://github.com/llvm/llvm-project/issues/ and include the crash backtrace, preprocessed source, and associated run script. Stack dump: 0. Program arguments: /usr/lib/llvm-14/bin/clang -cc1 -triple x86_64-pc-linux-gnu -emit-obj -mrelax-all --mrelax-relocations -disable-free -clear-ast-before-backend -disable-llvm-verifier -discard-value-names -main-file-name opt-mem2reg-4.ll -mrelocation-model pic -pic-level 2 -pic-is-pie -mframe-pointer=all -fmath-errno -ffp-contract=on -fno-rounding-math -mconstructor-aliases -funwind-tables=2 -target-cpu x86-64 -tune-cpu generic -mllvm -treat-scalable-fixed-error-as-warning -debugger-tuning=gdb -fcoverage-compilation-dir=/home/sailor/Test/compiler-labs/tests/5-opt/warmup/ll_opt -resource-dir /usr/lib/llvm-14/lib/clang/14.0.0 -O0 -w -fdebug-compilation-dir=/home/sailor/Test/compiler-labs/tests/5-opt/warmup/ll_opt -ferror-limit 19 -fgnuc-version=4.2.1 -fcolor-diagnostics -faddrsig -D__GCC_HAVE_DWARF2_CFI_ASM=1 -o /tmp/opt-mem2reg-4-f0d56f.o -x ir opt-mem2reg-4.ll 1. Code generation 2. Running pass 'Function Pass Manager' on module 'opt-mem2reg-4.ll'. 3. Running pass 'X86 DAG->DAG Instruction Selection' on function '@main' clang: error: unable to execute command: Segmentation fault (core dumped) clang: error: clang frontend command failed due to signal (use -v to see invocation) Ubuntu clang version 14.0.0-1ubuntu1.1 Target: x86_64-pc-linux-gnu Thread model: posix InstalledDir: /usr/bin clang: note: diagnostic msg: Error generating preprocessed source(s) - no preprocessable inputs. 怎么定位错误的地方?如何查看原因?
最新发布
07-02
评论 3
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值