jtamate added a comment.
In D12511#258193 <https://phabricator.kde.org/D12511#258193>, @mwolff wrote: > Actually, no. Ignore what I said. The pictures you are showing are pretty meaningless. Did you run perf with `--call-graph dwarf`? Better look at the flamegraph and search for the function you are interested in (Kate::TextBuffer::notifyAboutRangeChange) or use the Caller/Callee view to get an aggregated view of your change. That's not the impression I got running kwrite in live and under a slow machine (valgrind), before I had to wait for the paste to finish, and after the patch not. But kwrite is still slow undoing the paste. I did run perf record -g, the same test with the patch applied after pasting the text 25 times and undoing with this result: F5833430: kwrite_perf_after_25.png <https://phabricator.kde.org/F5833430>. The same test (pasting 25 times and undoing) with --call-graph dwarf with this result: F5833432: kwrite_perf_after_25_dwarf.png <https://phabricator.kde.org/F5833432>, and F5833445: kwrite_perf_after_25_dwarf_caller.png <https://phabricator.kde.org/F5833445>. REPOSITORY R241 KIO REVISION DETAIL https://phabricator.kde.org/D12511 To: jtamate, #kate, cullmann, mwolff Cc: mwolff, cullmann, #frameworks, michaelh, kevinapavew, ngraham, bruns, demsking, sars, dhaumann