Replacing -O2 with -O3. ./benchmarks/jerry/loop_arithmetics_1kk.js: 2.97 -> 2.79.
This commit is contained in:
+1
-1
@@ -164,7 +164,7 @@ CFLAGS_WERROR ?= -Werror
|
|||||||
CFLAGS_WFATAL_ERRORS ?= -Wfatal-errors
|
CFLAGS_WFATAL_ERRORS ?= -Wfatal-errors
|
||||||
|
|
||||||
# Optimizations
|
# Optimizations
|
||||||
CFLAGS_OPTIMIZE ?= -O2 -flto
|
CFLAGS_OPTIMIZE ?= -O3 -flto
|
||||||
CFLAGS_NO_OPTIMIZE ?= -O0
|
CFLAGS_NO_OPTIMIZE ?= -O0
|
||||||
LDFLAGS_OPTIMIZE ?=
|
LDFLAGS_OPTIMIZE ?=
|
||||||
LDFLAGS_NO_OPTIMIZE ?=
|
LDFLAGS_NO_OPTIMIZE ?=
|
||||||
|
|||||||
@@ -37,6 +37,19 @@ extern void *memset(void *s, int c, size_t n);
|
|||||||
*/
|
*/
|
||||||
extern void *memmove(void *s1, const void*s2, size_t n);
|
extern void *memmove(void *s1, const void*s2, size_t n);
|
||||||
|
|
||||||
|
#ifdef __GNUC__
|
||||||
|
/*
|
||||||
|
* Making GCC not to replace:
|
||||||
|
* - __memcpy -> call to memcpy;
|
||||||
|
* - __memset -> call to memset;
|
||||||
|
* - __memmove -> call to memmove.
|
||||||
|
*/
|
||||||
|
CALL_PRAGMA(GCC diagnostic push)
|
||||||
|
CALL_PRAGMA(GCC diagnostic ignored "-Wpragmas")
|
||||||
|
CALL_PRAGMA(GCC push_options)
|
||||||
|
CALL_PRAGMA(GCC optimize ("-fno-tree-loop-distribute-patterns"))
|
||||||
|
#endif /* __GNUC__ */
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* memcpy alias to __memcpy (for compiler usage)
|
* memcpy alias to __memcpy (for compiler usage)
|
||||||
*/
|
*/
|
||||||
@@ -66,6 +79,12 @@ void* memmove(void *s1, /**< destination*/
|
|||||||
{
|
{
|
||||||
return __memmove(s1, s2, n);
|
return __memmove(s1, s2, n);
|
||||||
} /* memmove */
|
} /* memmove */
|
||||||
|
|
||||||
|
#ifdef __GNUC__
|
||||||
|
CALL_PRAGMA(GCC pop_options)
|
||||||
|
CALL_PRAGMA(GCC diagnostic pop)
|
||||||
|
#endif /* __GNUC__ */
|
||||||
|
|
||||||
#endif /* LIBC_MUSL */
|
#endif /* LIBC_MUSL */
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user