ARMv8.5 MTE: Add MTE compatible version of strlen.

Reading outside the range of the string is only allowed within 16 byte
aligned granules when MTE is enabled.

This implementation is based on string/aarch64/strlen.S

Merged the page cross code into the main path and optimized it.
Modified the zeroones mask to ignore the bytes that are loaded but are
not part of the string. Made a special case for when there is 8 bytes
or less to check before the alignment boundary.
3 files changed