Skip to content
Commit a3b74581 authored by Michael Jones's avatar Michael Jones
Browse files

[libc] add unsafe mode to strlen

The only safe way to implement strlen involves reading the string one
char at a time. It is faster to read in larger blocks, but this leads to
reading beyond the string boundary, which is undefined behavior. This
patch adds an implementation and flag to use this fast but unsafe
version of strlen.

Reviewed By: sivachandra

Differential Revision: https://reviews.llvm.org/D129808
parent 6c214094
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment