1 // NOTE: Assertions have been autogenerated by utils/update_cc_test_checks.py
2 // REQUIRES: powerpc-registered-target
3 // RUN: %clang_cc1 -triple powerpc64-unknown-linux-gnu \
4 // RUN: -emit-llvm %s -o - -target-cpu pwr7 | FileCheck %s
5 // RUN: %clang_cc1 -triple powerpc64le-unknown-linux-gnu \
6 // RUN: -emit-llvm %s -o - -target-cpu pwr8 | FileCheck %s
8 // The argument expression must not be emitted multiple times
10 // CHECK-LABEL: @test_fric(
12 // CHECK-NEXT: [[D:%.*]] = alloca double, align 8
13 // CHECK-NEXT: [[TMP:%.*]] = alloca double, align 8
14 // CHECK-NEXT: [[TMP0:%.*]] = load double, ptr [[D]], align 8
15 // CHECK-NEXT: store double [[TMP0]], ptr [[TMP]], align 8
16 // CHECK-NEXT: [[TMP1:%.*]] = load double, ptr [[TMP]], align 8
17 // CHECK-NEXT: [[TMP2:%.*]] = call double @llvm.rint.f64(double [[TMP1]])
18 // CHECK-NEXT: ret void
21 __fric(({double d
; d
;}));