Revert "Reland "[LoongArch] Support -march=native and -mtune=""
authorSteven Wu <stevenwu@apple.com>
Mon, 31 Jul 2023 22:49:08 +0000 (15:49 -0700)
committerTobias Hieta <tobias@hieta.se>
Wed, 9 Aug 2023 06:57:44 +0000 (08:57 +0200)
commitd92613ec779fd9137d8e9140e15aaf6e35a9481d
treee75bea7bffce33aef34edbb4420dd329305a889b
parentd93ba81b55909eecce360818020a539500bee28b
Revert "Reland "[LoongArch] Support -march=native and -mtune=""

This reverts commit c56514f21b2cf08eaa7ac3a57ba4ce403a9c8956. This
commit adds global state that is shared between clang driver and clang
cc1, which is not correct when clang is used with `-fno-integrated-cc1`
option (no integrated cc1). The -march and -mtune option needs to be
properly passed through cc1 command-line and stored in TargetInfo.

(cherry picked from commit 42c9354a928d4d9459504527085fccc91b46aed3)
12 files changed:
clang/lib/Basic/Targets/LoongArch.cpp
clang/lib/Basic/Targets/LoongArch.h
clang/lib/Driver/ToolChains/Arch/LoongArch.cpp
clang/lib/Driver/ToolChains/Clang.cpp
clang/test/Driver/loongarch-mtune-error.c [deleted file]
clang/test/Driver/loongarch-mtune.c [deleted file]
clang/test/Preprocessor/init-loongarch.c
llvm/include/llvm/TargetParser/LoongArchTargetParser.h
llvm/lib/Target/LoongArch/LoongArch.td
llvm/lib/TargetParser/LoongArchTargetParser.cpp
llvm/test/CodeGen/LoongArch/cpus-invalid.ll [deleted file]
llvm/test/CodeGen/LoongArch/cpus.ll [deleted file]