1*67e74705SXin Li // RUN: touch %t.o 2*67e74705SXin Li // 3*67e74705SXin Li // RUN: %clang -target x86_64-unknown-linux -### %t.o -flto 2>&1 \ 4*67e74705SXin Li // RUN: -Wl,-plugin-opt=foo -O3 \ 5*67e74705SXin Li // RUN: | FileCheck %s --check-prefix=CHECK-X86-64-BASIC 6*67e74705SXin Li // CHECK-X86-64-BASIC: "-plugin" "{{.*}}/LLVMgold.so" 7*67e74705SXin Li // CHECK-X86-64-BASIC: "-plugin-opt=O3" 8*67e74705SXin Li // CHECK-X86-64-BASIC: "-plugin-opt=foo" 9*67e74705SXin Li // 10*67e74705SXin Li // RUN: %clang -target x86_64-unknown-linux -### %t.o -flto 2>&1 \ 11*67e74705SXin Li // RUN: -march=corei7 -Wl,-plugin-opt=foo -Ofast \ 12*67e74705SXin Li // RUN: | FileCheck %s --check-prefix=CHECK-X86-64-COREI7 13*67e74705SXin Li // CHECK-X86-64-COREI7: "-plugin" "{{.*}}/LLVMgold.so" 14*67e74705SXin Li // CHECK-X86-64-COREI7: "-plugin-opt=mcpu=corei7" 15*67e74705SXin Li // CHECK-X86-64-COREI7: "-plugin-opt=O3" 16*67e74705SXin Li // CHECK-X86-64-COREI7: "-plugin-opt=foo" 17*67e74705SXin Li // 18*67e74705SXin Li // RUN: %clang -target arm-unknown-linux -### %t.o -flto 2>&1 \ 19*67e74705SXin Li // RUN: -march=armv7a -Wl,-plugin-opt=foo -O0 \ 20*67e74705SXin Li // RUN: | FileCheck %s --check-prefix=CHECK-ARM-V7A 21*67e74705SXin Li // CHECK-ARM-V7A: "-plugin" "{{.*}}/LLVMgold.so" 22*67e74705SXin Li // CHECK-ARM-V7A: "-plugin-opt=mcpu=cortex-a8" 23*67e74705SXin Li // CHECK-ARM-V7A: "-plugin-opt=O0" 24*67e74705SXin Li // CHECK-ARM-V7A: "-plugin-opt=foo" 25*67e74705SXin Li // 26*67e74705SXin Li // RUN: %clang -target i686-linux-android -### %t.o -flto 2>&1 \ 27*67e74705SXin Li // RUN: | FileCheck %s --check-prefix=CHECK-X86-ANDROID 28*67e74705SXin Li // CHECK-X86-ANDROID: "-plugin" "{{.*}}/LLVMgold.so" 29