llvm.org GIT mirror llvm / release_60 test / Transforms / Reassociate / 2002-05-15-AgressiveSubMove.ll
release_60

Tree @release_60 (Download .tar.gz)

2002-05-15-AgressiveSubMove.ll @release_60raw · history · blame

; RUN: opt < %s -reassociate -S | FileCheck %s

define i32 @test1(i32 %A) {
; CHECK-LABEL: test1
; CHECK: ret i32 0
  %X = add i32 %A, 1
  %Y = add i32 %A, 1
  %r = sub i32 %X, %Y
  ret i32 %r
}