Add flag -fauto-profile as alias to -fprofile-sample-use.
Summary: GCC uses -fauto-profile to enable sample-based PGO. This patch adds it to Clang as an alias for -fprofile-sample-use. Differential Revision: http://llvm-reviews.chandlerc.com/D2353 llvm-svn: 196589
This commit is contained in:
parent
43d8e6cb3b
commit
67fe87fc5e
|
@ -369,6 +369,8 @@ def fno_autolink : Flag <["-"], "fno-autolink">, Group<f_Group>,
|
|||
def fprofile_sample_use_EQ : Joined<["-"], "fprofile-sample-use=">,
|
||||
Group<f_Group>, Flags<[DriverOption, CC1Option]>,
|
||||
HelpText<"Enable sample-based profile guided optimizations">;
|
||||
def fauto_profile_EQ : Joined<["-"], "fauto-profile=">,
|
||||
Alias<fprofile_sample_use_EQ>;
|
||||
|
||||
def fblocks : Flag<["-"], "fblocks">, Group<f_Group>, Flags<[CC1Option]>,
|
||||
HelpText<"Enable the 'blocks' language feature">;
|
||||
|
|
|
@ -54,6 +54,9 @@
|
|||
// RUN: %clang -### -S -fprofile-sample-use=%S/Inputs/file.prof %s 2>&1 | FileCheck -check-prefix=CHECK-SAMPLE-PROFILE %s
|
||||
// CHECK-SAMPLE-PROFILE: "-fprofile-sample-use={{.*}}/file.prof"
|
||||
|
||||
// RUN: %clang -### -S -fauto-profile=%S/Inputs/file.prof %s 2>&1 | FileCheck -check-prefix=CHECK-AUTO-PROFILE %s
|
||||
// CHECK-AUTO-PROFILE: "-fprofile-sample-use={{.*}}/file.prof"
|
||||
|
||||
// RUN: %clang -### -S -fvectorize %s 2>&1 | FileCheck -check-prefix=CHECK-VECTORIZE %s
|
||||
// RUN: %clang -### -S -fno-vectorize -fvectorize %s 2>&1 | FileCheck -check-prefix=CHECK-VECTORIZE %s
|
||||
// RUN: %clang -### -S -fno-vectorize %s 2>&1 | FileCheck -check-prefix=CHECK-NO-VECTORIZE %s
|
||||
|
|
Loading…
Reference in New Issue