blob: de0c606594c1f23dd3146c9eae3f256db3b34402 [file] [log] [blame]
Peter Collingbournefb532b92016-02-24 20:46:36 +00001// RUN: %clang -target x86_64-unknown-linux -fwhole-program-vtables -### %s 2>&1 | FileCheck --check-prefix=NO-LTO %s
Peter Collingbournecb1c5fc2017-09-13 21:49:17 +00002// RUN: %clang_cl --target=x86_64-pc-win32 -fwhole-program-vtables -### -- %s 2>&1 | FileCheck --check-prefix=NO-LTO %s
Peter Collingbournefb532b92016-02-24 20:46:36 +00003// NO-LTO: invalid argument '-fwhole-program-vtables' only allowed with '-flto'
Peter Collingbournea2fa8e42017-09-13 18:36:07 +00004
5// RUN: %clang -target x86_64-unknown-linux -fwhole-program-vtables -flto -### %s 2>&1 | FileCheck --check-prefix=LTO %s
Peter Collingbournecb1c5fc2017-09-13 21:49:17 +00006// RUN: %clang_cl --target=x86_64-pc-win32 -fwhole-program-vtables -flto -### -- %s 2>&1 | FileCheck --check-prefix=LTO %s
Peter Collingbournea2fa8e42017-09-13 18:36:07 +00007// LTO: "-fwhole-program-vtables"
8
9// RUN: %clang -target x86_64-unknown-linux -fwhole-program-vtables -fno-whole-program-vtables -flto -### %s 2>&1 | FileCheck --check-prefix=LTO-DISABLE %s
Peter Collingbournecb1c5fc2017-09-13 21:49:17 +000010// RUN: %clang_cl --target=x86_64-pc-win32 -fwhole-program-vtables -fno-whole-program-vtables -flto -### -- %s 2>&1 | FileCheck --check-prefix=LTO-DISABLE %s
Peter Collingbournea2fa8e42017-09-13 18:36:07 +000011// LTO-DISABLE-NOT: "-fwhole-program-vtables"