[docs] Fix build-docs.sh
[llvm-project.git] / clang / lib / Driver / ToolChains / ZOS.cpp
blobf921227076a5edfb6c92260fefa7ed41d1bb7889
1 //===--- ZOS.cpp - z/OS ToolChain Implementations ---------------*- C++ -*-===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
9 #include "ZOS.h"
10 #include "CommonArgs.h"
11 #include "clang/Driver/Compilation.h"
12 #include "clang/Driver/Options.h"
13 #include "llvm/Option/ArgList.h"
15 using namespace clang::driver;
16 using namespace clang::driver::toolchains;
17 using namespace llvm::opt;
18 using namespace clang;
20 ZOS::ZOS(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
21 : ToolChain(D, Triple, Args) {}
23 ZOS::~ZOS() {}
25 void ZOS::addClangTargetOptions(const ArgList &DriverArgs,
26 ArgStringList &CC1Args,
27 Action::OffloadKind DeviceOffloadKind) const {
28 // Pass "-faligned-alloc-unavailable" only when the user hasn't manually
29 // enabled or disabled aligned allocations.
30 if (!DriverArgs.hasArgNoClaim(options::OPT_faligned_allocation,
31 options::OPT_fno_aligned_allocation))
32 CC1Args.push_back("-faligned-alloc-unavailable");