TCE.cpp 1.2 KB

12345678910111213141516171819202122232425262728293031323334
  1. //===--- TCE.cpp - Implement TCE target feature support -------------------===//
  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. // This file implements TCE TargetInfo objects.
  10. //
  11. //===----------------------------------------------------------------------===//
  12. #include "TCE.h"
  13. #include "Targets.h"
  14. #include "clang/Basic/MacroBuilder.h"
  15. using namespace clang;
  16. using namespace clang::targets;
  17. void TCETargetInfo::getTargetDefines(const LangOptions &Opts,
  18. MacroBuilder &Builder) const {
  19. DefineStd(Builder, "tce", Opts);
  20. Builder.defineMacro("__TCE__");
  21. Builder.defineMacro("__TCE_V1__");
  22. }
  23. void TCELETargetInfo::getTargetDefines(const LangOptions &Opts,
  24. MacroBuilder &Builder) const {
  25. DefineStd(Builder, "tcele", Opts);
  26. Builder.defineMacro("__TCE__");
  27. Builder.defineMacro("__TCE_V1__");
  28. Builder.defineMacro("__TCELE__");
  29. Builder.defineMacro("__TCELE_V1__");
  30. }