2#ifndef _SCE_KERNEL_SYSMEM_SYSCLIB_H_
3#define _SCE_KERNEL_SYSMEM_SYSCLIB_H_
9#pragma region C standard library functions
17#define CTYPE_UPPER 0x01
18#define CTYPE_LOWER 0x02
19#define CTYPE_DIGIT 0x04
20#define CTYPE_SPACE 0x08
21#define CTYPE_PUNCT 0x10
22#define CTYPE_CONTROL 0x20
23#define CTYPE_HEXDIGIT 0x40
24#define CTYPE_UNK_0x80 0x80
36#define __isxx(ch, msk) ((look_ctype_table(ch) & (msk)) != 0)
37#define iscntrl(ch) __isxx(ch, CTYPE_CONTROL)
38#define isprint(ch) __isxx(ch, CTYPE_UNK_0x80 | CTYPE_PUNCT | CTYPE_DIGIT | CTYPE_LOWER | CTYPE_UPPER)
39#define isspace(ch) __isxx(ch, CTYPE_SPACE)
42#define ispunct(ch) __isxx(ch, CTYPE_PUNCT)
43#define isalnum(ch) __isxx(ch, CTYPE_DIGIT | CTYPE_LOWER | CTYPE_UPPER)
44#define isalpha(ch) __isxx(ch, CTYPE_LOWER | CTYPE_UPPER)
45#define isupper(ch) __isxx(ch, CTYPE_UPPER)
46#define islower(ch) __isxx(ch, CTYPE_LOWER)
47#define isdigit(ch) __isxx(ch, CTYPE_DIGIT)
48#define isxdigit(ch) __isxx(ch, CTYPE_HEXDIGIT | CTYPE_DIGIT)
52void *
memset(
void *dest,
int ch,
size_t count);
55int strcmp(
const char *lhs,
const char *rhs);
58int memcmp(
const void *lhs,
const void *rhs,
size_t count);
61char *
strstr(
const char *str,
const char *substr);
64char*
strchr(
const char* str,
int ch);
67void *
memcpy(
void *dest,
const void *src,
size_t count);
70void *
memchr(
const void* ptr,
int ch,
size_t count);
73void *
memmove(
void *dest,
const void *src,
size_t size);
76char *
strncpy(
char *dest,
const char *src,
size_t count);
82char *
strncat(
char *dest,
const char *src,
size_t count);
91int memcmp(
const void *lhs,
const void *rhs,
size_t count);
95int vsnprintf(
char *s,
size_t n,
const char *fmt, va_list arg);
98int snprintf(
char *buffer,
size_t bufsz,
const char *format, ...);
102unsigned long strtoul(
const char *str,
char **str_end,
int base);
105long long strtoll(
const char *str,
char **str_end,
int base);
108long strtol(
const char *str,
char **str_end,
int base);
111#pragma region C library extensions
113int strlcat(
char *dst,
const char *src,
size_t dstsize);
116size_t strlcpy(
char *dst,
const char *src,
size_t dstsize);
122#pragma region Checked C library functions
127void *
__strlcat_chk(
char *dst,
const char *src,
size_t dstsize,
size_t dstlen);
130char *
__strncat_chk(
char *dest,
const char *src,
size_t count,
size_t dstlen);
133void *
__memmove_chk(
void *dest,
const void *src,
size_t len,
size_t destlen);
142void *
__memcpy_chk(
void *dest,
const void *src,
size_t len,
size_t destlen);
182int __prnt(
void (*cb)(
void *argp,
int ch),
void *argp,
const char *fmt, va_list ap);
194#pragma region Stack canary
202#pragma region ARM AEABI functions
long long __aeabi_llsr(long long, int)
char * __strcpy_chk(char *dest, const char *src, size_t destlen)
char * strncpy(char *dest, const char *src, size_t count)
int vsnprintf(char *s, size_t n, const char *fmt, va_list arg)
int strlen(const char *s)
unsigned int __stack_chk_guard
int strcmp(const char *lhs, const char *rhs)
int __snprintf_chk(char *str, size_t maxlen, int flag, size_t strlen, const char *format,...)
char * __strncpy_chk(char *s1, const char *s2, size_t n, size_t s1len)
void * __memset_chk(void *dest, int c, size_t len, size_t destlen)
long long strtoll(const char *str, char **str_end, int base)
void * memset(void *dest, int ch, size_t count)
noreturn void __stack_chk_fail(void)
void * __memmove_chk(void *dest, const void *src, size_t len, size_t destlen)
long strtol(const char *str, char **str_end, int base)
long long __aeabi_llsl(long long, int)
char * strrchr(const char *str, int ch)
char * strncat(char *dest, const char *src, size_t count)
int __prnt(void(*cb)(void *argp, int ch), void *argp, const char *fmt, va_list ap)
Generic formatted output processing function.
void * __strlcat_chk(char *dst, const char *src, size_t dstsize, size_t dstlen)
size_t strlcpy(char *dst, const char *src, size_t dstsize)
long long __aeabi_lmul(long long, long long)
char * strstr(const char *str, const char *substr)
int strlcat(char *dst, const char *src, size_t dstsize)
char * __strcat_chk(char *dest, const char *src, size_t destlen)
unsigned long strtoul(const char *str, char **str_end, int base)
char * __strncat_chk(char *dest, const char *src, size_t count, size_t dstlen)
char * strchr(const char *str, int ch)
void * memchr(const void *ptr, int ch, size_t count)
unsigned look_ctype_table(int ch)
lldiv_t __aeabi_ldivmod(long long n, long long d)
int memcmp(const void *lhs, const void *rhs, size_t count)
int timingsafe_bcmp(const void *b1, const void *b2, size_t len)
char * __strlcpy_chk(char *s1, const char *s2, size_t n, size_t s1len)
int __aeabi_ulcmp(unsigned long long, unsigned long long)
unsigned __aeabi_uidiv(unsigned numerator, unsigned denominator)
long long __aeabi_lasr(long long, int)
int __aeabi_idiv(int numerator, int denominator)
void * __memcpy_chk(void *dest, const void *src, size_t len, size_t destlen)
void * memmove(void *dest, const void *src, size_t size)
void * memcpy(void *dest, const void *src, size_t count)
int __aeabi_lcmp(long long, long long)
int strnlen(const char *s, size_t maxlen)
ulldiv_t __aeabi_uldivmod(unsigned long long n, unsigned long long d)
udiv_return __aeabi_uidivmod(unsigned numerator, unsigned denominator)
idiv_return __aeabi_idivmod(int numerator, int denominator)
char * SceSysclibForDriver_FE39AEAC(char *dst, const char *src, size_t dstsize)
int snprintf(char *buffer, size_t bufsz, const char *format,...)