class Linux

Declaration

class Linux : public Generic_ELF { /* full declaration omitted */ };

Description

Generic_GCC - A tool chain using the 'gcc' command to perform all subcommands; this relies on gcc translating the majority of command line options.

Declared at: clang/lib/Driver/ToolChains/Linux.h:19

Inherits from: Generic_ELF

Member Variables

public std::vector<std::string> ExtraOpts

Inherited from Generic_GCC:

protected GCCInstallation
protected CudaInstallation
protected RocmInstallation

Inherited from ToolChain:

protected Multilibs
protected SelectedMultilib

Method Overview

Inherited from Generic_ELF:

Inherited from Generic_GCC:

Inherited from ToolChain:

Methods

void AddClangSystemIncludeArgs(
    const llvm::opt::ArgList& DriverArgs,
    llvm::opt::ArgStringList& CC1Args) const

Description

Add the clang cc1 arguments for system include paths. This routine is responsible for adding the necessary cc1 arguments to include headers from standard system header directories.

Declared at: clang/lib/Driver/ToolChains/Linux.h:31

Parameters

const llvm::opt::ArgList& DriverArgs
llvm::opt::ArgStringList& CC1Args

void AddCudaIncludeArgs(
    const llvm::opt::ArgList& DriverArgs,
    llvm::opt::ArgStringList& CC1Args) const

Description

Add arguments to use system-specific CUDA includes.

Declared at: clang/lib/Driver/ToolChains/Linux.h:36

Parameters

const llvm::opt::ArgList& DriverArgs
llvm::opt::ArgStringList& CC1Args

void AddHIPIncludeArgs(
    const llvm::opt::ArgList& DriverArgs,
    llvm::opt::ArgStringList& CC1Args) const

Description

Add arguments to use system-specific HIP includes.

Declared at: clang/lib/Driver/ToolChains/Linux.h:38

Parameters

const llvm::opt::ArgList& DriverArgs
llvm::opt::ArgStringList& CC1Args

void AddHIPRuntimeLibArgs(
    const llvm::opt::ArgList& Args,
    llvm::opt::ArgStringList& CmdArgs) const

Description

Add the system specific linker arguments to use for the given HIP runtime library type.

Declared at: clang/lib/Driver/ToolChains/Linux.h:40

Parameters

const llvm::opt::ArgList& Args
llvm::opt::ArgStringList& CmdArgs

void AddIAMCUIncludeArgs(
    const llvm::opt::ArgList& DriverArgs,
    llvm::opt::ArgStringList& CC1Args) const

Description

Add arguments to use MCU GCC toolchain includes.

Declared at: clang/lib/Driver/ToolChains/Linux.h:42

Parameters

const llvm::opt::ArgList& DriverArgs
llvm::opt::ArgStringList& CC1Args

clang::driver::ToolChain::CXXStdlibType
GetDefaultCXXStdlibType() const

Declared at: clang/lib/Driver/ToolChains/Linux.h:46

unsigned int GetDefaultDwarfVersion() const

Declared at: clang/lib/Driver/ToolChains/Linux.h:45

clang::driver::ToolChain::RuntimeLibType
GetDefaultRuntimeLibType() const

Description

GetDefaultRuntimeLibType - Get the default runtime library variant to use.

Declared at: clang/lib/Driver/ToolChains/Linux.h:44

bool HasNativeLLVMSupport() const

Description

HasNativeLTOLinker - Check whether the linker and related tools have native LLVM support.

Declared at: clang/lib/Driver/ToolChains/Linux.h:24

bool IsAArch64OutlineAtomicsDefault(
    const llvm::opt::ArgList& Args) const

Description

Test whether this toolchain supports outline atomics by default.

Declared at: clang/lib/Driver/ToolChains/Linux.h:48

Parameters

const llvm::opt::ArgList& Args

bool IsMathErrnoDefault() const

Description

IsMathErrnoDefault - Does this tool chain use -fmath-errno by default.

Declared at: clang/lib/Driver/ToolChains/Linux.h:50

Linux(const clang::driver::Driver& D,
      const llvm::Triple& Triple,
      const llvm::opt::ArgList& Args)

Declared at: clang/lib/Driver/ToolChains/Linux.h:21

Parameters

const clang::driver::Driver& D
const llvm::Triple& Triple
const llvm::opt::ArgList& Args

void addExtraOpts(
    llvm::opt::ArgStringList& CmdArgs) const

Declared at: clang/lib/Driver/ToolChains/Linux.h:58

Parameters

llvm::opt::ArgStringList& CmdArgs

void addLibStdCxxIncludePaths(
    const llvm::opt::ArgList& DriverArgs,
    llvm::opt::ArgStringList& CC1Args) const

Declared at: clang/lib/Driver/ToolChains/Linux.h:33

Parameters

const llvm::opt::ArgList& DriverArgs
llvm::opt::ArgStringList& CC1Args

void addProfileRTLibs(
    const llvm::opt::ArgList& Args,
    llvm::opt::ArgStringList& CmdArgs) const

Description

addProfileRTLibs - When -fprofile-instr-profile is specified, try to pass a suitable profile runtime library to the linker.

Declared at: clang/lib/Driver/ToolChains/Linux.h:52

Parameters

const llvm::opt::ArgList& Args
llvm::opt::ArgStringList& CmdArgs

clang::driver::Tool* buildAssembler() const

Declared at: clang/lib/Driver/ToolChains/Linux.h:67

clang::driver::Tool* buildLinker() const

Declared at: clang/lib/Driver/ToolChains/Linux.h:68

clang::driver::Tool* buildStaticLibTool() const

Declared at: clang/lib/Driver/ToolChains/Linux.h:69

std::string computeSysRoot() const

Description

Return the sysroot, possibly searching for a default sysroot using target-specific logic.

Declared at: clang/lib/Driver/ToolChains/Linux.h:54

llvm::DenormalMode getDefaultDenormalModeForType(
    const llvm::opt::ArgList& DriverArgs,
    const clang::driver::JobAction& JA,
    const llvm::fltSemantics* FPType =
        nullptr) const

Description

Returns the output denormal handling type in the default floating point environment for the given \p FPType if given. Otherwise, the default assumed mode for any floating point type.

Declared at: clang/lib/Driver/ToolChains/Linux.h:62

Parameters

const llvm::opt::ArgList& DriverArgs
const clang::driver::JobAction& JA
const llvm::fltSemantics* FPType = nullptr

std::string getDynamicLinker(
    const llvm::opt::ArgList& Args) const

Declared at: clang/lib/Driver/ToolChains/Linux.h:56

Parameters

const llvm::opt::ArgList& Args

std::string getMultiarchTriple(
    const clang::driver::Driver& D,
    const llvm::Triple& TargetTriple,
    llvm::StringRef SysRoot) const

Declared at: clang/lib/Driver/ToolChains/Linux.h:26

Parameters

const clang::driver::Driver& D
const llvm::Triple& TargetTriple
llvm::StringRef SysRoot

clang::SanitizerMask getSupportedSanitizers()
    const

Description

Return sanitizers which are available in this toolchain.

Declared at: clang/lib/Driver/ToolChains/Linux.h:51

bool isPIEDefault(
    const llvm::opt::ArgList& Args) const

Description

Test whether this toolchain defaults to PIE.

Declared at: clang/lib/Driver/ToolChains/Linux.h:49

Parameters

const llvm::opt::ArgList& Args