__thread fix by fincs.

This commit is contained in:
yellows8 2017-11-25 12:02:25 -05:00
parent d7e611f9f4
commit cca73c47fa
2 changed files with 4 additions and 4 deletions

View File

@ -32,7 +32,7 @@ INCLUDES := include
#--------------------------------------------------------------------------------- #---------------------------------------------------------------------------------
# options for code generation # options for code generation
#--------------------------------------------------------------------------------- #---------------------------------------------------------------------------------
ARCH := -march=armv8-a -mtp=soft -fPIC ARCH := -march=armv8-a -mtp=soft -fPIC -ftls-model=local-exec
CFLAGS := -g -Wall -Werror \ CFLAGS := -g -Wall -Werror \
-ffunction-sections \ -ffunction-sections \

View File

@ -110,8 +110,8 @@ static fsdev_fsdevice fsdev_fsdevices[32];
/*! @endcond */ /*! @endcond */
static char __cwd[PATH_MAX+1] = "/"; static char __cwd[PATH_MAX+1] = "/";
static /*__thread*/ char __fixedpath[PATH_MAX+1]; static __thread char __fixedpath[PATH_MAX+1];
//static /*__thread*/ uint16_t __utf16path[PATH_MAX+1]; //static __thread uint16_t __utf16path[PATH_MAX+1];
static fsdev_fsdevice *fsdevFindDevice(const char *name) static fsdev_fsdevice *fsdevFindDevice(const char *name)
{ {
@ -658,7 +658,7 @@ fsdev_write_safe(struct _reent *r,
/* Copy to internal buffer and write in chunks. /* Copy to internal buffer and write in chunks.
* You cannot write from read-only memory. * You cannot write from read-only memory.
*/ */
static /*__thread*/ char tmp_buffer[8192]; static __thread char tmp_buffer[8192];
while(len > 0) while(len > 0)
{ {
size_t toWrite = len; size_t toWrite = len;