This adds the attributes associated with prefetch to the bultins.
Just call aarch64_get_attributes with FLAG_PREFETCH_MEMORY to get the attributes.
Built and tested for aarch64-linux-gnu.
gcc/ChangeLog:
* config/aarch64/aarch64-builtins.cc (aarch64_init_prefetch_builtin):
Updete call to aarch64_general_add_builtin in AARCH64_INIT_PREFETCH_BUILTIN.
Add new variable prefetch_attrs.
Signed-off-by: Andrew Pinski <quic_apinski@quicinc.com>
{
#define AARCH64_INIT_PREFETCH_BUILTIN(INDEX, N) \
aarch64_builtin_decls[INDEX] = \
- aarch64_general_add_builtin ("__builtin_aarch64_" N, ftype, INDEX)
+ aarch64_general_add_builtin ("__builtin_aarch64_" N, ftype, INDEX, \
+ prefetch_attrs)
tree ftype;
tree cv_argtype;
+ tree prefetch_attrs = aarch64_get_attributes (FLAG_PREFETCH_MEMORY, DImode);
cv_argtype = build_qualified_type (void_type_node, TYPE_QUAL_CONST
| TYPE_QUAL_VOLATILE);
cv_argtype = build_pointer_type (cv_argtype);