VEToolchain.h 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. //===--- VE.h - VE 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. #ifndef LLVM_CLANG_LIB_DRIVER_TOOLCHAINS_VE_H
  9. #define LLVM_CLANG_LIB_DRIVER_TOOLCHAINS_VE_H
  10. #include "Linux.h"
  11. #include "clang/Driver/ToolChain.h"
  12. namespace clang {
  13. namespace driver {
  14. namespace toolchains {
  15. class LLVM_LIBRARY_VISIBILITY VEToolChain : public Linux {
  16. public:
  17. VEToolChain(const Driver &D, const llvm::Triple &Triple,
  18. const llvm::opt::ArgList &Args);
  19. protected:
  20. Tool *buildAssembler() const override;
  21. Tool *buildLinker() const override;
  22. public:
  23. bool IsIntegratedAssemblerDefault() const override { return true; }
  24. bool isPICDefault() const override;
  25. bool isPIEDefault(const llvm::opt::ArgList &Args) const override;
  26. bool isPICDefaultForced() const override;
  27. bool SupportsProfiling() const override;
  28. bool hasBlocksRuntime() const override;
  29. void
  30. AddClangSystemIncludeArgs(const llvm::opt::ArgList &DriverArgs,
  31. llvm::opt::ArgStringList &CC1Args) const override;
  32. void
  33. addClangTargetOptions(const llvm::opt::ArgList &DriverArgs,
  34. llvm::opt::ArgStringList &CC1Args,
  35. Action::OffloadKind DeviceOffloadKind) const override;
  36. void AddClangCXXStdlibIncludeArgs(
  37. const llvm::opt::ArgList &DriverArgs,
  38. llvm::opt::ArgStringList &CC1Args) const override;
  39. void AddCXXStdlibLibArgs(const llvm::opt::ArgList &Args,
  40. llvm::opt::ArgStringList &CmdArgs) const override;
  41. llvm::ExceptionHandling
  42. GetExceptionModel(const llvm::opt::ArgList &Args) const override;
  43. CXXStdlibType
  44. GetCXXStdlibType(const llvm::opt::ArgList &Args) const override {
  45. return ToolChain::CST_Libcxx;
  46. }
  47. RuntimeLibType GetDefaultRuntimeLibType() const override {
  48. return ToolChain::RLT_CompilerRT;
  49. }
  50. const char *getDefaultLinker() const override { return "nld"; }
  51. };
  52. } // end namespace toolchains
  53. } // end namespace driver
  54. } // end namespace clang
  55. #endif // LLVM_CLANG_LIB_DRIVER_TOOLCHAINS_VE_H