RS6000: Added -mcpu=future and built-in gating infrastructure.
The RS6000 architecture now supports the `-mcpu=future` option for enabling experimental processor features, along with gating infrastructure for built-in func…
The RS6000 backend now supports the -mcpu=future option to enable experimental processor features that may be present in future Power processors. A new target predicate, future, gates built-in functions based on this option. This allows developers to experiment with and evaluate new features. The -mcpu=future option also sets the .machine attribute.
In Details
This commit introduces support for a -mcpu=future option in the RS6000 (PowerPC) backend. This option, intended for development and evaluation, enables experimental processor features. The changes include modifications to config.gcc, rs6000-builtin.cc, rs6000-c.cc, rs6000-cpus.def, rs6000-gen-builtins.cc, and rs6000-opts.h. The primary goal is to provide a mechanism for gating built-in functions based on the -mcpu=future option, using a new TARGET_FUTURE macro.
For Context
Processors evolve over time, with new features being added in each generation. Compilers need to be able to support these new features, even before they are finalized in a production processor. This commit adds a mechanism to GCC for the RS6000 architecture (also known as PowerPC) to enable experimental, pre-release features. The -mcpu=future option allows developers to test code with these features, while the compiler uses a special 'gate' to control which built-in functions are available based on the selected CPU.