[llvm-branch-commits] [llvm-branch] r88720 - in /llvm/branches/Apple/Leela: lib/CodeGen/VirtRegRewriter.cpp test/CodeGen/ARM/2009-11-13-ScavengerAssert.ll

Evan Cheng evan.cheng at apple.com
Fri Nov 13 15:24:08 PST 2009


Author: evancheng
Date: Fri Nov 13 17:24:08 2009
New Revision: 88720

URL: http://llvm.org/viewvc/llvm-project?rev=88720&view=rev
Log:
Merge 88719.

Added:
    llvm/branches/Apple/Leela/test/CodeGen/ARM/2009-11-13-ScavengerAssert.ll
Modified:
    llvm/branches/Apple/Leela/lib/CodeGen/VirtRegRewriter.cpp

Modified: llvm/branches/Apple/Leela/lib/CodeGen/VirtRegRewriter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/Apple/Leela/lib/CodeGen/VirtRegRewriter.cpp?rev=88720&r1=88719&r2=88720&view=diff

==============================================================================
--- llvm/branches/Apple/Leela/lib/CodeGen/VirtRegRewriter.cpp (original)
+++ llvm/branches/Apple/Leela/lib/CodeGen/VirtRegRewriter.cpp Fri Nov 13 17:24:08 2009
@@ -583,6 +583,10 @@
       RegKills.reset(*SR);
       KillOps[*SR] = NULL;
     }
+    for (const unsigned *SR = TRI->getSuperRegisters(Reg); *SR; ++SR) {
+      RegKills.reset(*SR);
+      KillOps[*SR] = NULL;
+    }
   }
 }
 

Added: llvm/branches/Apple/Leela/test/CodeGen/ARM/2009-11-13-ScavengerAssert.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/Apple/Leela/test/CodeGen/ARM/2009-11-13-ScavengerAssert.ll?rev=88720&view=auto

==============================================================================
--- llvm/branches/Apple/Leela/test/CodeGen/ARM/2009-11-13-ScavengerAssert.ll (added)
+++ llvm/branches/Apple/Leela/test/CodeGen/ARM/2009-11-13-ScavengerAssert.ll Fri Nov 13 17:24:08 2009
@@ -0,0 +1,42 @@
+; RUN: llc -mtriple=armv7-eabi -mcpu=cortex-a8 < %s
+; PR5411
+
+%bar = type { %quad, float, float, [3 x %quux*], [3 x %bar*], [2 x %bar*], [3 x i8], i8 }
+%baz = type { %bar*, i32 }
+%foo = type { i8, %quuz, %quad, float, [64 x %quux], [128 x %bar], i32, %baz, %baz }
+%quad = type { [4 x float] }
+%quux = type { %quad, %quad }
+%quuz = type { [4 x %quux*], [4 x float], i32 }
+
+define arm_aapcs_vfpcc %bar* @aaa(%foo* nocapture %this, %quux* %a, %quux* %b, %quux* %c, i8 zeroext %forced) {
+entry:
+  br i1 undef, label %bb85, label %bb
+
+bb:                                               ; preds = %entry
+  %0 = getelementptr inbounds %bar* null, i32 0, i32 0, i32 0, i32 2 ; <float*> [#uses=2]
+  %1 = load float* undef, align 4                 ; <float> [#uses=1]
+  %2 = fsub float 0.000000e+00, undef             ; <float> [#uses=2]
+  %3 = fmul float 0.000000e+00, undef             ; <float> [#uses=1]
+  %4 = load float* %0, align 4                    ; <float> [#uses=3]
+  %5 = fmul float %4, %2                          ; <float> [#uses=1]
+  %6 = fsub float %3, %5                          ; <float> [#uses=1]
+  %7 = fmul float %4, undef                       ; <float> [#uses=1]
+  %8 = fsub float %7, undef                       ; <float> [#uses=1]
+  %9 = fmul float undef, %2                       ; <float> [#uses=1]
+  %10 = fmul float 0.000000e+00, undef            ; <float> [#uses=1]
+  %11 = fsub float %9, %10                        ; <float> [#uses=1]
+  %12 = fmul float undef, %6                      ; <float> [#uses=1]
+  %13 = fmul float 0.000000e+00, %8               ; <float> [#uses=1]
+  %14 = fadd float %12, %13                       ; <float> [#uses=1]
+  %15 = fmul float %1, %11                        ; <float> [#uses=1]
+  %16 = fadd float %14, %15                       ; <float> [#uses=1]
+  %17 = select i1 undef, float undef, float %16   ; <float> [#uses=1]
+  %18 = fdiv float %17, 0.000000e+00              ; <float> [#uses=1]
+  store float %18, float* undef, align 4
+  %19 = fmul float %4, undef                      ; <float> [#uses=1]
+  store float %19, float* %0, align 4
+  ret %bar* null
+
+bb85:                                             ; preds = %entry
+  ret %bar* null
+}





More information about the llvm-branch-commits mailing list