"Yuta Mukai (Fujitsu)" <mukai.y...@fujitsu.com> writes: > Thank you for the reviews! I attached a patch that fixes the problems. > >>> On 31 Oct 2024, at 11:50, Richard Sandiford <richard.sandif...@arm.com> >>> wrote: >>> >>> "Yuta Mukai (Fujitsu)" <mukai.y...@fujitsu.com> writes: >>>> Hello, >>>> >>>> This patch adds initial support for FUJITSU-MONAKA CPU, which we are >>>> developing. >>>> This is the slides for the CPU: >>>> https://www.fujitsu.com/downloads/SUPER/topics/isc24/next-arm-based-processor-fujitsu-monaka-and-its-software-ecosystem.pdf >>>> >>>> Bootstrapped/regtested on aarch64-unknown-linux-gnu. >>>> >>>> We will post a patch for backporting to GCC 14 later. >>>> >>>> We would be grateful if someone could push this on our behalf, as we do >>>> not have write access. >>> >>> Thanks for the patch, it looks good. I just have a couple of minor >>> comments: >>> >>>> @@ -132,6 +132,7 @@ AARCH64_CORE("octeontx2f95mm", octeontx2f95mm, >>>> cortexa57, V8_2A, (CRYPTO, PROFI >>>> >>>> /* Fujitsu ('F') cores. */ >>>> AARCH64_CORE("a64fx", a64fx, a64fx, V8_2A, (F16, SVE), a64fx, 0x46, >>>> 0x001, -1) >>>> +AARCH64_CORE("fujitsu-monaka", fujitsu_monaka, cortexa57, V9_3A, (AES, >>>> CRYPTO, F16, F16FML, FP8, LS64, RCPC, RNG, SHA2, SHA3, SM4, SVE2_AES, >>>> SVE2_BITPERM, SVE2_SHA3, SVE2_SM4), fujitsu_monaka, 0x46, 0x003, -1) >>> >>> Usually this file omits listing a feature if it is already implied by the >>> architecture level. In this case, I think V9_3A should enable F16FML and >>> RCPC automatically, and so we could drop those features from the list. >>> >>> Also, we should be able to rely on transitive dependencies for the >>> SVE2 crypto extensions. So I think it should be enough to list: >>> >>> AARCH64_CORE("fujitsu-monaka", fujitsu_monaka, cortexa57, V9_3A, (F16, FP8, >>> LS64, RNG, SVE2_AES, SVE2_BITPERM, SVE2_SHA3, SVE2_SM4), fujitsu_monaka, >>> 0x46, 0x003, -1) >>> >>> which should have the same effect. >>> >>> Could you check whether that works? > > Thanks for the list. > CRYPTO was found not to be implied by SHA2, so I left only it there. > > Incidentally, the manual says that LS64 is automatically enabled for V9_2A, > but it is not. > Should the manual be corrected? > > https://gcc.gnu.org/onlinedocs/gcc/AArch64-Options.html#index-march >> ‘armv9.2-a’ Armv9.2-A ‘armv9.1-a’, ‘+ls64’
Oops, yes! Thanks for pointing that out. I'll push a patch separately. >>>> diff --git a/gcc/config/aarch64/tuning_models/fujitsu_monaka.h >>>> b/gcc/config/aarch64/tuning_models/fujitsu_monaka.h >>>> new file mode 100644 >>>> index 000000000..8d6f297b8 >>>> --- /dev/null >>>> +++ b/gcc/config/aarch64/tuning_models/fujitsu_monaka.h >>>> @@ -0,0 +1,65 @@ >>>> +/* Tuning model description for AArch64 architecture. >>> >>> It's probably worth changing "AArch64 architecture" to "FUJITSU-MONAKA". > > Fixed. > >>> >>> The patch looks good to me otherwise. >> >>Looks ok to me modulo those comments as well. >>The ChangeLog should be improved a little bit too. >> >>* config/aarch64/aarch64-cores.def (AARCH64_CORE): Add fujitsu-monaka >>* config/aarch64/aarch64-tune.md: Regenerate >>* config/aarch64/aarch64.cc: Include fujitsu-monaka tuning model >>* doc/invoke.texi: Document -mcpu=fujitsu-monaka >>* config/aarch64/tuning_models/fujitsu_monaka.h: New file. >> >>The sentences should end in full stop “.” > > Fixed. Thanks for the patch. I've pushed it to trunk. Richard