Please use GitHub pull requests for new patches. Phabricator shutdown timeline
Changeset View
Changeset View
Standalone View
Standalone View
clang/lib/Driver/ToolChains/Arch/ARM.cpp
//===--- ARM.cpp - ARM (not AArch64) Helpers for Tools ----------*- C++ -*-===// | //===--- ARM.cpp - ARM (not AArch64) Helpers for Tools ----------*- C++ -*-===// | ||||
Lint: Lint: clang-format suggested style edits found: | |||||
// | // | ||||
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. | // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. | ||||
// See https://llvm.org/LICENSE.txt for license information. | // See https://llvm.org/LICENSE.txt for license information. | ||||
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception | // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception | ||||
// | // | ||||
//===----------------------------------------------------------------------===// | //===----------------------------------------------------------------------===// | ||||
#include "ARM.h" | #include "ARM.h" | ||||
▲ Show 20 Lines • Show All 525 Lines • ▼ Show 20 Lines | if (!ForAS) { | ||||
// Supported only on ARMv6T2 and ARMv7 and above. | // Supported only on ARMv6T2 and ARMv7 and above. | ||||
// Cannot be combined with -mno-movt or -mlong-calls | // Cannot be combined with -mno-movt or -mlong-calls | ||||
if (Arg *A = Args.getLastArg(options::OPT_mexecute_only, options::OPT_mno_execute_only)) { | if (Arg *A = Args.getLastArg(options::OPT_mexecute_only, options::OPT_mno_execute_only)) { | ||||
if (A->getOption().matches(options::OPT_mexecute_only)) { | if (A->getOption().matches(options::OPT_mexecute_only)) { | ||||
if (getARMSubArchVersionNumber(Triple) < 7 && | if (getARMSubArchVersionNumber(Triple) < 7 && | ||||
llvm::ARM::parseArch(Triple.getArchName()) != llvm::ARM::ArchKind::ARMV6T2) | llvm::ARM::parseArch(Triple.getArchName()) != llvm::ARM::ArchKind::ARMV6T2) | ||||
D.Diag(diag::err_target_unsupported_execute_only) << Triple.getArchName(); | D.Diag(diag::err_target_unsupported_execute_only) << Triple.getArchName(); | ||||
else if (Arg *B = Args.getLastArg(options::OPT_mno_movt)) | else if (Arg *B = Args.getLastArg(options::OPT_mno_movt)) | ||||
D.Diag(diag::err_opt_not_valid_with_opt) << A->getAsString(Args) << B->getAsString(Args); | D.Diag(diag::drv_err_opt_not_valid_with_opt) << A->getAsString(Args) << B->getAsString(Args); | ||||
Lint: Pre-merge checks clang-format: please reformat the code - D.Diag(diag::drv_err_opt_not_valid_with_opt) << A->getAsString(Args) << B->getAsString(Args); + D.Diag(diag::drv_err_opt_not_valid_with_opt) + << A->getAsString(Args) << B->getAsString(Args); Lint: Pre-merge checks: clang-format: please reformat the code
```
- D.Diag(diag… | |||||
// Long calls create constant pool entries and have not yet been fixed up | // Long calls create constant pool entries and have not yet been fixed up | ||||
// to play nicely with execute-only. Hence, they cannot be used in | // to play nicely with execute-only. Hence, they cannot be used in | ||||
// execute-only code for now | // execute-only code for now | ||||
else if (Arg *B = Args.getLastArg(options::OPT_mlong_calls, options::OPT_mno_long_calls)) { | else if (Arg *B = Args.getLastArg(options::OPT_mlong_calls, options::OPT_mno_long_calls)) { | ||||
if (B->getOption().matches(options::OPT_mlong_calls)) | if (B->getOption().matches(options::OPT_mlong_calls)) | ||||
D.Diag(diag::err_opt_not_valid_with_opt) << A->getAsString(Args) << B->getAsString(Args); | D.Diag(diag::drv_err_opt_not_valid_with_opt) << A->getAsString(Args) << B->getAsString(Args); | ||||
Lint: Pre-merge checks clang-format: please reformat the code - D.Diag(diag::drv_err_opt_not_valid_with_opt) << A->getAsString(Args) << B->getAsString(Args); + D.Diag(diag::drv_err_opt_not_valid_with_opt) + << A->getAsString(Args) << B->getAsString(Args); Lint: Pre-merge checks: clang-format: please reformat the code
```
- D.Diag(diag… | |||||
} | } | ||||
Features.push_back("+execute-only"); | Features.push_back("+execute-only"); | ||||
} | } | ||||
} | } | ||||
} | } | ||||
// Kernel code has more strict alignment requirements. | // Kernel code has more strict alignment requirements. | ||||
if (KernelOrKext) | if (KernelOrKext) | ||||
▲ Show 20 Lines • Show All 154 Lines • Show Last 20 Lines |
clang-format suggested style edits found: