Merge "Remove flags from ClangLibToolingUnknownCflags" am: 0b6bcd4014

am: aceb86e345

Change-Id: I3aa46f505f091d3e80d0baac7745b2bebe1861bc
This commit is contained in:
Logan Chien 2018-10-17 03:13:54 -07:00 committed by android-build-merger
commit 99f21f683c
2 changed files with 1 additions and 17 deletions

View file

@ -92,12 +92,7 @@ var ClangUnknownLldflags = sorted([]string{
"-Wl,-m,aarch64_elf64_le_vec", "-Wl,-m,aarch64_elf64_le_vec",
}) })
var ClangLibToolingUnknownCflags = []string{ var ClangLibToolingUnknownCflags []string = nil
// Remove -flto and other flto dependent flags.
"-flto*",
"-fsanitize*",
"-fwhole-program-vtables",
}
func init() { func init() {
pctx.StaticVariable("ClangExtraCflags", strings.Join([]string{ pctx.StaticVariable("ClangExtraCflags", strings.Join([]string{

View file

@ -73,17 +73,6 @@ func (sabimod *sabi) flags(ctx ModuleContext, flags Flags) Flags {
flags.ToolingCFlags = filterOutWithPrefix(flags.CFlags, config.ClangLibToolingUnknownCflags) flags.ToolingCFlags = filterOutWithPrefix(flags.CFlags, config.ClangLibToolingUnknownCflags)
flags.ToolingCppFlags = filterOutWithPrefix(flags.CppFlags, config.ClangLibToolingUnknownCflags) flags.ToolingCppFlags = filterOutWithPrefix(flags.CppFlags, config.ClangLibToolingUnknownCflags)
// RSClang does not support recent mcpu option likes exynos-m2.
// So we need overriding mcpu option when we want to use it.
mappedArch := map[string]string{
"exynos-m2": "cortex-a53",
"cortex-a55": "cortex-a53",
"cortex-a75": "cortex-a57",
}
if arch, ok := mappedArch[ctx.Arch().CpuVariant]; ok {
flags.ToolingCFlags = append(flags.ToolingCFlags, "-mcpu="+arch)
}
return flags return flags
} }