MSP430Attributes.h 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. #pragma once
  2. #ifdef __GNUC__
  3. #pragma GCC diagnostic push
  4. #pragma GCC diagnostic ignored "-Wunused-parameter"
  5. #endif
  6. //===-- MSP430Attributes.h - MSP430 Attributes ------------------*- C++ -*-===//
  7. //
  8. // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
  9. // See https://llvm.org/LICENSE.txt for license information.
  10. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
  11. //
  12. //===-----------------------------------------------------------------------===//
  13. ///
  14. /// \file
  15. /// This file contains enumerations for MSP430 ELF build attributes as
  16. /// defined in the MSP430 ELF psABI specification.
  17. ///
  18. /// MSP430 ELF psABI specification
  19. ///
  20. /// https://www.ti.com/lit/pdf/slaa534
  21. ///
  22. //===----------------------------------------------------------------------===//
  23. #ifndef LLVM_SUPPORT_MSP430ATTRIBUTES_H
  24. #define LLVM_SUPPORT_MSP430ATTRIBUTES_H
  25. #include "llvm/Support/ELFAttributes.h"
  26. namespace llvm {
  27. namespace MSP430Attrs {
  28. const TagNameMap &getMSP430AttributeTags();
  29. enum AttrType : unsigned {
  30. // Attribute types in ELF/.MSP430.attributes.
  31. TagISA = 4,
  32. TagCodeModel = 6,
  33. TagDataModel = 8,
  34. TagEnumSize = 10
  35. };
  36. enum ISA { ISAMSP430 = 1, ISAMSP430X = 2 };
  37. enum CodeModel { CMSmall = 1, CMLarge = 2 };
  38. enum DataModel { DMSmall = 1, DMLarge = 2, DMRestricted = 3 };
  39. enum EnumSize { ESSmall = 1, ESInteger = 2, ESDontCare = 3 };
  40. } // namespace MSP430Attrs
  41. } // namespace llvm
  42. #endif
  43. #ifdef __GNUC__
  44. #pragma GCC diagnostic pop
  45. #endif