diff options
author | SimplyTheOther <simplytheother@gmail.com> | 2020-07-04 20:48:44 +0800 |
---|---|---|
committer | Philip Herron <philip.herron@embecosm.com> | 2020-11-28 21:13:17 +0000 |
commit | 2c9687c2df6296368830b8172315d3ab970054d4 (patch) | |
tree | ab1e8f28b7c1f837fc87b761ee3146461e44db8c /gcc | |
parent | 27029ad4df8faa7ee43fe0e55a867d0ec14e7da1 (diff) | |
download | gcc-2c9687c2df6296368830b8172315d3ab970054d4.zip gcc-2c9687c2df6296368830b8172315d3ab970054d4.tar.gz gcc-2c9687c2df6296368830b8172315d3ab970054d4.tar.bz2 |
Added MMIX target hook (or provisional one at least)
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/config/mmix/mmix.h | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/gcc/config/mmix/mmix.h b/gcc/config/mmix/mmix.h index ac0be10..2757176 100644 --- a/gcc/config/mmix/mmix.h +++ b/gcc/config/mmix/mmix.h @@ -133,6 +133,32 @@ struct GTY(()) machine_function } \ while (0) +#define TARGET_RUST_CPU_INFO() \ + do { \ + rust_add_target_info("target_arch", "mmix"); \ + /*ignoring libfuncs as options say to get rid of it*/ \ + if (TARGET_ABI_GNU) \ + rust_add_target_info("target_feature", "abi-gnu"); \ + else \ + rust_add_target_info("target_feature", "abi-mmixware"); \ + if (TARGET_FCMP_EPSILON) \ + rust_add_target_info("target_feature", "epsilon"); \ + if (TARGET_ZERO_EXTEND) \ + rust_add_target_info("target_feature", "zero-extend"); \ + if (TARGET_KNUTH_DIVISION) \ + rust_add_target_info("target_feature", "knuthdiv"); \ + if (TARGET_TOPLEVEL_SYMBOLS) \ + rust_add_target_info("target_feature", "toplevel-symbols"); \ + if (TARGET_BRANCH_PREDICT) \ + rust_add_target_info("target_feature", "branch-predict"); \ + if (TARGET_BASE_ADDRESSES) \ + rust_add_target_info("target_feature", "base-addresses"); \ + if (!(USE_RETURN_INSN)) \ + rust_add_target_info("target_feature", "single-exit"); \ + /*TODO: find way of getting no-set-program-start and elf info?*/ \ + /*TODO: find way of defining set-program-start, set-data-start usefully?*/ \ + } while (0) + #define TARGET_DEFAULT \ (MASK_BRANCH_PREDICT | MASK_BASE_ADDRESSES | MASK_USE_RETURN_INSN) |