On Feb 29, 2008, at 1:53 AM, Abdelrazak Younes wrote:
Bennett Helm wrote:
On Feb 28, 2008, at 7:55 PM, Pavel Sanda wrote:
you really mean --enable-optimization=-Os ? why not O2 ?
With LyX-1.3, I did some systematic tests. O3 was not noticeably
faster
than O2 or Os, and we thought at the time that we might as well
keep the
size down. So we decided on Os. I haven't tested LyX-1.6, but
old habits
are hard to break....
no problem, i can commit it this way. ... it may be unrelated but
i remember
some complaints about speed issues which were mac specific.
OK -- I just tried it again, just to be sure. Compiling with -O3
gives me pretty much the same results as -Os. (The speed problems
on Mac are -- and for the most part have been -- with typing
speed. Putting LyX in fullscreen mode, I get the same typing lag
in each case. That is, I type a sentence, and I finish typing the
sentence when the same character appears on the screen, and then I
have to wait about the same number of seconds before the full
sentence appears.)
Could you please post the console output obtained with '-dbg
painting'? In principle only those lines that are changed are
repainted so you should not notice any slowdown in fullscreen mode.
I suspect spurious resize events that trigger full screen redraw.
Fullscreen doesn't seem any slower than simply maximizing the window,
so there's nothing special about fullscreen mode. It's just that
redrawing in general is slow, and the slowness becomes much more
apparent with large window sizes. At any rate, here are results from -
dbg painting:
In normal mode (i.e., not fullscreen), when I type within a line, I
get something like this showing up for each character I type:
BufferView.cpp(1781):
y1: 77 y2: 135 pit: 3 singlepar: 1
BufferView.cpp(2009): *** START DRAWING ***
TextMetrics.cpp(2019): main text redraw pit=3 row=1 row_selection=0
full_repaint=0 row_has_changed=1
BufferView.cpp(2056):
*** END DRAWING ***
BufferView.cpp(2073): Found new anchor pit = 0 anchor ypos = 34
*******************
Again in normal mode, when my typing wraps to a new line, I get this:
BufferView.cpp(1825): metrics: anchor pit = 0 anchor ypos = 34
BufferView.cpp(1859): Metrics: anchor pit = 0 anchor ypos = 34 y1 =
0 y2 = 154 pit1 = -1 pit2 = 4
BufferView.cpp(2009): *** START DRAWING ***
TextMetrics.cpp(2019): main text redraw pit=0 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=1 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=2 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=3 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=3 row=1 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=3 row=2 row_selection=0
full_repaint=1 row_has_changed=1
BufferView.cpp(2056):
*** END DRAWING ***
BufferView.cpp(2073): Found new anchor pit = 0 anchor ypos = 34
*******************
Still in normal mode when the line wraps in a way that scrolls lines
on the screen, I get this:
BufferView.cpp(1825): metrics: anchor pit = 15 anchor ypos = -8
BufferView.cpp(1859): Metrics: anchor pit = 15 anchor ypos = -8 y1 =
-22 y2 = 834 pit1 = 14 pit2 = 40
BufferView.cpp(2009): *** START DRAWING ***
TextMetrics.cpp(2019): main text redraw pit=15 row=1 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=15 row=2 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=16 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=17 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=18 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=18 row=1 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=18 row=2 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=19 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=20 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=21 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=21 row=1 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=21 row=2 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=22 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=23 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=24 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=24 row=1 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=24 row=2 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=25 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=26 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=27 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=27 row=1 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=27 row=2 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=28 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=29 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=30 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=30 row=1 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=30 row=2 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=31 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=32 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=33 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=33 row=1 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=33 row=2 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=34 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=35 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=36 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=36 row=1 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=36 row=2 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=37 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=38 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=39 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=39 row=1 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=39 row=2 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=39 row=3 row_selection=0
full_repaint=1 row_has_changed=1
BufferView.cpp(2056):
*** END DRAWING ***
BufferView.cpp(2073): Found new anchor pit = 15 anchor ypos = -8
********************
In fullscreen mode, things are much the same, except when the line
wrap scrolls the screen, I get more output:
BufferView.cpp(2009): *** START DRAWING ***
TextMetrics.cpp(2019): main text redraw pit=12 row=2 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=13 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=14 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=15 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=15 row=1 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=15 row=2 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=16 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=17 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=18 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=18 row=1 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=18 row=2 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=19 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=20 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=21 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=21 row=1 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=21 row=2 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=21 row=3 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=22 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=23 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=24 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=24 row=1 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=24 row=2 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=25 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=26 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=27 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=27 row=1 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=27 row=2 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=28 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=29 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=30 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=30 row=1 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=30 row=2 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=31 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=32 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=33 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=33 row=1 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=33 row=2 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=34 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=35 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=36 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=36 row=1 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=36 row=2 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=37 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=38 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=39 row=0 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=39 row=1 row_selection=0
full_repaint=1 row_has_changed=1
TextMetrics.cpp(2019): main text redraw pit=39 row=2 row_selection=0
full_repaint=1 row_has_changed=1
BufferView.cpp(2056):
*** END DRAWING ***
Bennett