rs6000: Introduce -mdense-math option for Dense Math Facility
New -mdense-math option controls Dense Math Facility instructions on PowerPC.
The PowerPC backend now supports a new compiler option, -mdense-math, to control the emission of Dense Math Facility (DMF) instructions. When targeting ‘future’ CPUs, DMF is enabled by default unless explicitly disabled. Attempting to use -mdense-math on unsupported targets results in a hard error.
In Details
This commit introduces the OPTION_MASK_DMF and TARGET_DMF macros to the rs6000 backend, controlled by the new -mdense-math command-line option. This provides explicit control over the use of the Dense Math Facility, a set of special instructions available on newer PowerPC processors. The option is automatically enabled for the 'future' CPU type unless overridden, ensuring efficient use of these instructions when available.
- Dense Math Facility (DMF)
- A set of specialized instructions on certain PowerPC processors designed for efficient floating-point and vector arithmetic operations.
- rs6000
- The GCC backend for IBM POWER and PowerPC microarchitectures.
- TARGET_DMF
- A preprocessor macro used within the GCC rs6000 backend to indicate whether code generation for the Dense Math Facility is enabled.