or, alternativly one could write size_t strlen(const char *s) {return __builtin_strlen(s);} to use the gcc-builtin function. I think, both are faster than the bytewise search.