llvm.org GIT mirror llvm / 7d35249
Fix PR4528. This scavenger assertion is too strict. The two-address value is killed by another operand. There is probably a better fix. Either 1) scavenger can look at other operands, or 2) livevariables can be smarter about kill markers. Patches welcome. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@78072 91177308-0d34-0410-b5e6-96231b3b80d8 Evan Cheng 10 years ago
2 changed file(s) with 27 addition(s) and 1 deletion(s). Raw diff Collapse all Expand all
266266 unsigned UseIdx;
267267 if (MI->isRegTiedToUseOperand(Idx, &UseIdx) &&
268268 !MI->getOperand(UseIdx).isUndef()) {
269 assert(isUsed(Reg) && "Using an undefined register!");
269 assert(!MI->getOperand(UseIdx).isKill() &&
270 "Using an undefined register!");
270271 continue;
271272 }
272273
0 ; RUN: llvm-as < %s | llc -mtriple=armv6-elf
1 ; PR4528
2
3 define arm_aapcscc i32 @file_read_actor(i32 %desc, i32 %page, i32 %offset, i32 %size) nounwind optsize {
4 entry:
5 br i1 undef, label %fault_in_pages_writeable.exit, label %bb5.i
6
7 bb5.i: ; preds = %entry
8 %asmtmp.i = tail call i32 asm sideeffect "1:\09strbt\09$1,[$2]\0A2:\0A\09.section .fixup,\22ax\22\0A\09.align\092\0A3:\09mov\09$0, $3\0A\09b\092b\0A\09.previous\0A\09.section __ex_table,\22a\22\0A\09.align\093\0A\09.long\091b, 3b\0A\09.previous", "=r,r,r,i,0,~{cc}"(i8 0, i32 undef, i32 -14, i32 0) nounwind ; [#uses=1]
9 br label %fault_in_pages_writeable.exit
10
11 fault_in_pages_writeable.exit: ; preds = %bb5.i, %entry
12 %0 = phi i32 [ 0, %entry ], [ %asmtmp.i, %bb5.i ] ; [#uses=1]
13 %1 = icmp eq i32 %0, 0 ; [#uses=1]
14 br i1 %1, label %bb2, label %bb3
15
16 bb2: ; preds = %fault_in_pages_writeable.exit
17 unreachable
18
19 bb3: ; preds = %fault_in_pages_writeable.exit
20 %2 = tail call arm_aapcscc i32 @__copy_to_user(i8* undef, i8* undef, i32 undef) nounwind ; [#uses=0]
21 unreachable
22 }
23
24 declare arm_aapcscc i32 @__copy_to_user(i8*, i8*, i32)