Hi, This patch adds SVE support for simd clone generation when using 'omp declare simd'. The design is based on what was discussed in PR 96342, but I did not look at YangYang's patch as I wasn't sure of whether that code's copyright had been assigned to FSF. This patch also is not in accordance with the examples in the BETA VFABIA64 document that can be found in the vfabia64 subdir of https://github.com/ARM-software/abi-aa/ If we agree to this approach I will propose changes to the ABI. It differs in that we take the ommission of 'simdlen' to be the only way to create a SVE simd clone using 'omp declare simd', and that the current target defined on the command-line has no bearing in what simd clones are generated. This SVE simd clone is always VLA. The document describes a way to specify SVE simdclones of VLS by using the simdlen clause, but that would require another way to toggle between SVE and Advanced SIMD and since there is no clause to do that for 'omp declare simd' I would have to assume this would be controllable by the command-line target options (march/mcpu). By generating all possible Advanced SIMD simdlens and a VLA simdlen for SVE when ommitting simdlen we would be adhering to the same practice x86_64 does. Targethook changes This patch proposes two targethook changes: 1) Add mode parameter to TARGET_SIMD_CLONE_USABLE We require the mode parameter to distinguish between calls to a simd clone from a Advanced SIMD mode and a SVE mode. 2) Add new TARGET_SIMD_CLONE_ADJUST_RET_OR_PARAM We require this to be able to modify the types used in SVE simd clones, as we need to add the SVE type attribute so that the correct PCS can be applied. Other notable changes: - We discourage the use of an 'inbranch' simdclone for when the caller is not in a branch, such that it picks a 'notinbranch' variant if available over an inbranch one. (we could probably rely on ordering but that's quite error prone and the ordering I'm looking at is by definition target specific). - I currently put the VLA mangling in the target agnostic mangling function, if other targets with VLA want to use a different mangling in the future we may want to change this into a targethook. I'll create a ChangeLog when I turn this into a PATCH if we agree on this direction.