On 08/11/2018 17:52, Steve Ellcey wrote:
> This is a resubmission of patch 1 to support the Aarch64 SIMD ABI [1] in
> GCC, it does not have any functional changes from the last submit.
> 
> The significant difference between the standard ARM ABI and the SIMD ABI
> is that in the normal ABI a callee saves only the lower 64 bits of registers
> V8-V15, in the SIMD ABI the callee must save all 128 bits of registers
> V8-V23.
...
> --- a/gcc/config/aarch64/aarch64.c
> +++ b/gcc/config/aarch64/aarch64.c
> @@ -1088,6 +1088,15 @@ static const struct processor *selected_tune;
>  /* The current tuning set.  */
>  struct tune_params aarch64_tune_params = generic_tunings;
>  
> +/* Table of machine attributes.  */
> +static const struct attribute_spec aarch64_attribute_table[] =
> +{
> +  /* { name, min_len, max_len, decl_req, type_req, fn_type_req,
> +       affects_type_identity, handler, exclude } */
> +  { "aarch64_vector_pcs", 0, 0, false, true,  true,  false, NULL, NULL },

i just noticed that "affects_type_identity" is set to false,
so gcc accepts

  __attribute__((aarch64_vector_pcs)) void f(void);
  void (*g)(void) = f;

without a warning (treats function types with different
pcs as compatible)

i think we don't want to allow calls through the wrong
pointer type, such assignment should be an error.

Reply via email to