clang  14.0.0git
ZOS.cpp
Go to the documentation of this file.
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 //===----------------------------------------------------------------------===//
8 
9 #include "ZOS.h"
10 #include "CommonArgs.h"
12 #include "clang/Driver/Options.h"
13 #include "llvm/Option/ArgList.h"
14 
15 using namespace clang::driver;
16 using namespace clang::driver::toolchains;
17 using namespace llvm::opt;
18 using namespace clang;
19 
20 ZOS::ZOS(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
21  : ToolChain(D, Triple, Args) {}
22 
24 
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");
33 }
clang::driver::toolchains
Definition: AIX.h:55
clang::driver::toolchains::ZOS::~ZOS
~ZOS() override
Definition: ZOS.cpp:23
Options.h
llvm::opt
Definition: DiagnosticOptions.h:19
clang::driver::toolchains::ZOS::ZOS
ZOS(const Driver &D, const llvm::Triple &Triple, const llvm::opt::ArgList &Args)
Definition: ZOS.cpp:20
Compilation.h
clang::driver::ToolChain
ToolChain - Access to tools for a single platform.
Definition: ToolChain.h:91
CommonArgs.h
clang
Definition: CalledOnceCheck.h:17
clang::driver::Driver
Driver - Encapsulate logic for constructing compilation processes from a set of gcc-driver-like comma...
Definition: Driver.h:59
clang::driver::Action::OffloadKind
OffloadKind
Definition: Action.h:85
clang::driver
Definition: Action.h:31
ZOS.h
clang::driver::toolchains::ZOS::addClangTargetOptions
void addClangTargetOptions(const llvm::opt::ArgList &DriverArgs, llvm::opt::ArgStringList &CC1Args, Action::OffloadKind DeviceOffloadingKind) const override
Add options that need to be passed to cc1 for this target.
Definition: ZOS.cpp:25