Home | History | Annotate | Download | only in InstCombine
      1 ; RUN: opt -instcombine -S < %s | FileCheck %s
      2 
      3 ; This shouldn't fold, because sin(inf) is invalid.
      4 ; CHECK: @foo
      5 ; CHECK:   %t = call double @sin(double 0x7FF0000000000000)
      6 define double @foo() {
      7   %t = call double @sin(double 0x7FF0000000000000)
      8   ret double %t
      9 }
     10 
     11 ; This should fold.
     12 ; CHECK: @bar
     13 ; CHECK:   ret double 0.0
     14 define double @bar() {
     15   %t = call double @sin(double 0.0)
     16   ret double %t
     17 }
     18 
     19 declare double @sin(double)
     20