riscv-opts.h 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. /* Definition of RISC-V target for GNU compiler.
  2. Copyright (C) 2016-2018 Free Software Foundation, Inc.
  3. Contributed by Andrew Waterman (andrew@sifive.com).
  4. This file is part of GCC.
  5. GCC is free software; you can redistribute it and/or modify
  6. it under the terms of the GNU General Public License as published by
  7. the Free Software Foundation; either version 3, or (at your option)
  8. any later version.
  9. GCC is distributed in the hope that it will be useful,
  10. but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. GNU General Public License for more details.
  13. You should have received a copy of the GNU General Public License
  14. along with GCC; see the file COPYING3. If not see
  15. <http://www.gnu.org/licenses/>. */
  16. #ifndef GCC_RISCV_OPTS_H
  17. #define GCC_RISCV_OPTS_H
  18. enum riscv_abi_type {
  19. ABI_ILP32,
  20. ABI_ILP32E,
  21. ABI_ILP32F,
  22. ABI_ILP32D,
  23. ABI_LP64,
  24. ABI_LP64F,
  25. ABI_LP64D
  26. };
  27. extern enum riscv_abi_type riscv_abi;
  28. enum riscv_code_model {
  29. CM_MEDLOW,
  30. CM_MEDANY,
  31. CM_PIC
  32. };
  33. extern enum riscv_code_model riscv_cmodel;
  34. /* Keep this list in sync with define_attr "tune" in riscv.md. */
  35. enum riscv_microarchitecture_type {
  36. generic,
  37. sifive_7
  38. };
  39. extern enum riscv_microarchitecture_type riscv_microarchitecture;
  40. enum riscv_align_data {
  41. riscv_align_data_type_xlen,
  42. riscv_align_data_type_natural
  43. };
  44. #endif /* ! GCC_RISCV_OPTS_H */