i386: Add support for HYGON c86-4g series processors
Adds support for HYGON c86-4g series processors with appropriate cost models and tuning.
This commit introduces support for HYGON c86-4g series processors (c86-4g-m4, c86-4g-m6, and c86-4g-m7) in GCC. Without this support, using -march=native on HYGON machines would result in suboptimal code generation. The patch enables the use of -m{arch,tune}=c86-4g and -m{4,6,7} options, providing appropriate cost models and tuning parameters based on the hardware characteristics of these processors. New machine description files are included to model the pipeline for each processor variant.
In Details
This change adds HYGON vendor ID detection by extending the cpuinfo.h and i386-common.cc files, enabling tuning for c86-4g-m{4,6,7} processors. This enables target-specific optimization based on pipeline descriptions in c86-4g.md and c86-4g-m7.md.
For Context
When compiling code for x86 processors, the compiler needs to know the specific features and performance characteristics of the target CPU to generate the most efficient code. This involves identifying the CPU vendor (e.g., Intel, AMD, HYGON) and model and using this information to select appropriate instructions, schedule code for optimal pipeline utilization, and apply other optimizations. The -march and -mtune compiler options allow users to specify the target architecture and tune the code for a particular CPU.