Add controls for enabling M, F, and D RISC-V extensions.

Three predicates affect each extension:

- supports_m determines whether the target CPU supports the instruction set.
- enable_m determines if the instructions should be used, assuming they're
  available.
- use_m is the predicate used to actually use the instructions.
This commit is contained in:
Jakob Stoklund Olesen
2016-08-30 15:10:38 -07:00
parent f18041b56c
commit c1971db091
4 changed files with 22 additions and 2 deletions

View File

@@ -20,8 +20,16 @@ opt_level = EnumSetting(
is_64bit = BoolSetting("Enable 64-bit code generation")
enable_float = BoolSetting(
"""Enable the use of floating-point instructions""",
default=True)
enable_simd = BoolSetting(
"""Enable the use of SIMD instructions.""",
default=True)
enable_atomics = BoolSetting(
"""Enable the use of atomic instructions""",
default=True)
group.close(globals())