diff options
-rw-r--r-- | doc/ScintillaHistory.html | 4 | ||||
-rw-r--r-- | gtk/makefile | 2 | ||||
-rw-r--r-- | src/Editor.cxx | 2 | ||||
-rw-r--r-- | win32/makefile | 2 | ||||
-rw-r--r-- | win32/scintilla.mak | 2 |
5 files changed, 8 insertions, 4 deletions
diff --git a/doc/ScintillaHistory.html b/doc/ScintillaHistory.html index 1c919b7c2..a1a442137 100644 --- a/doc/ScintillaHistory.html +++ b/doc/ScintillaHistory.html @@ -610,6 +610,10 @@ <a href="https://sourceforge.net/p/scintilla/bugs/2363/">Bug #2363</a>. </li> <li> + Change release compilation optimization option to favour speed over space. + -O2 for MSVC and -O3 for gcc and clang. + </li> + <li> On Win32, avoid blurry display with DirectWrite in GDI scaling mode. <a href="https://sourceforge.net/p/scintilla/bugs/2344/">Bug #2344</a>. </li> diff --git a/gtk/makefile b/gtk/makefile index a641f18e4..8643ae317 100644 --- a/gtk/makefile +++ b/gtk/makefile @@ -84,7 +84,7 @@ DEFINES += -DNO_CXX11_REGEX endif DEFINES += -D$(if $(DEBUG),DEBUG,NDEBUG) -BASE_FLAGS += $(if $(DEBUG),-g,-Os) +BASE_FLAGS += $(if $(DEBUG),-g,-O3) CXX_BASE_FLAGS =--std=c++17 $(BASE_FLAGS) CXX_ALL_FLAGS =$(DEFINES) $(INCLUDES) $(CXX_BASE_FLAGS) $(CONFIG_FLAGS) diff --git a/src/Editor.cxx b/src/Editor.cxx index 1fb6d960d..72a8a4bd8 100644 --- a/src/Editor.cxx +++ b/src/Editor.cxx @@ -5872,7 +5872,7 @@ void Editor::StyleSetMessage(Message iMessage, uptr_t wParam, sptr_t lParam) { if (!(classified & UTF8MaskInvalid)) { // valid UTF-8 int len = classified & UTF8MaskWidth; - while (len--) + for (int i=0; i<len && i<4; i++) *rep++ = *utf8++; } *rep = 0; diff --git a/win32/makefile b/win32/makefile index e0f363653..c1829a45e 100644 --- a/win32/makefile +++ b/win32/makefile @@ -57,7 +57,7 @@ DEFINES += -DNO_CXX11_REGEX endif DEFINES += -D$(if $(DEBUG),DEBUG,NDEBUG) -BASE_FLAGS += $(if $(DEBUG),-g,-Os) +BASE_FLAGS += $(if $(DEBUG),-g,-O3) ifndef DEBUG STRIPFLAG=$(STRIPOPTION) diff --git a/win32/scintilla.mak b/win32/scintilla.mak index 62b90385e..f4eb67dcc 100644 --- a/win32/scintilla.mak +++ b/win32/scintilla.mak @@ -38,7 +38,7 @@ SUBSYSTEM=-SUBSYSTEM:WINDOWS,10.00 CRTFLAGS=-D_CRT_SECURE_CPP_OVERLOAD_STANDARD_NAMES=1 -D_CRT_SECURE_NO_DEPRECATE=1 -D_SCL_SECURE_NO_WARNINGS=1 $(ADD_DEFINE) CXXFLAGS=-Zi -TP -MP -W4 -EHsc -std:c++17 $(CRTFLAGS) CXXDEBUG=-Od -MTd -DDEBUG -CXXNDEBUG=-O1 -MT -DNDEBUG -GL +CXXNDEBUG=-O2 -MT -DNDEBUG -GL NAME=-Fo LDFLAGS=-OPT:REF -LTCG -IGNORE:4197 -DEBUG $(SUBSYSTEM) $(CETCOMPAT) LDDEBUG= |