Cygwin: convert sys_wcstombs/sys_mbstowcs wrapper to inline functions

This should slightly speed up especially path conversions,
given there's one less function call rearranging all function
arguments in registers/stack (and less stack pressure).

For clarity, rename overloaded  sys_wcstombs to _sys_wcstombs
and sys_cp_mbstowcs to _sys_mbstowcs.

Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
This commit is contained in:
Corinna Vinschen
2020-07-10 10:29:33 +02:00
parent b3af1d5aa3
commit 462fcdb67f
4 changed files with 61 additions and 65 deletions

View File

@ -403,7 +403,7 @@ dev_console::get_console_cp ()
inline DWORD
dev_console::str_to_con (mbtowc_p f_mbtowc, PWCHAR d, const char *s, DWORD sz)
{
return sys_cp_mbstowcs (f_mbtowc, d, CONVERT_LIMIT, s, sz);
return _sys_mbstowcs (f_mbtowc, d, CONVERT_LIMIT, s, sz);
}
bool