User forums > Using Code::Blocks
Too slow cursor moving (Linux)
xintrea:
--- Quote from: dmoore on October 24, 2007, 06:05:51 pm ---this is a known wxWidgets issue that affects some but not all linux installs.
see
http://forums.codeblocks.org/index.php/topic,6538.0.html
http://forums.codeblocks.org/index.php/topic,2869.0.html
--- End quote ---
In this themes i dont find guaranteed solving my problem. This problem exists from septmber 2006, and i had hoped that this bug is fixing...
After read foregoing threads, i try check, how frequency calling methods Editor::TextWidth() and wxScintilla::TextWidth()? I add printf() command in this methods. And i see, that methods dont calling if move cursor or select text with keyboard or mouse. This methods calling once in first open window, once if inserting text (ctrl+v), once if add new line (push Enter), and this is all. Trouble is not in this function.
Tomorrow try profile codeblocks.
dmoore:
--- Quote ---In this themes i dont find guaranteed solving my problem. This problem exists from septmber 2006, and i had hoped that this bug is fixing...
--- End quote ---
unfortunately, most people don't have the pleasure of experiencing this bug, just a "lucky" few :) so there have been few opportunities to do the needed profiling. if you can do some profiling that will definitely help (especially if you have experience with profiling in linux).
--- Quote ---After read foregoing threads, i try check, how frequency calling methods Editor::TextWidth() and wxScintilla::TextWidth()? I add printf() command in this methods. And i see, that methods dont calling if move cursor or select text with keyboard or mouse. This methods calling once in first open window, once if inserting text (ctrl+v), once if add new line (push Enter), and this is all. Trouble is not in this function.
--- End quote ---
yes, I think that avenue has been explored without succcess.
xintrea:
My report about profile codeblocks.
Before, i running make clean, next running configure with flags
--- Quote ---./configure CXXFLAGS=-pg CFLAGS=-pg
--- End quote ---
Next running make and make install (as root).
After this manipulation, i type command codeblocks in my work directory, check data and time of compilation in "About" window, to be sure that codeblocks contain changes for profile. About one minut i simulated violent activies in the editor - move cursor, copy, paste, etc.. Then closed codeblocks.
In work directory i see new file - gmon.out. Reduced output of command gprof codeblocks gmon.out
--- Code: ---Each sample counts as 0.01 seconds.
% cumulative self self total
time seconds seconds calls Ts/call Ts/call name
33.33 0.03 0.03 wxWindowBase::IsShown() const
27.78 0.06 0.03 CodeBlocksApp::GetEventHashTable() const
11.11 0.07 0.01 wxWindowBase::GetBestVirtualSize() const
5.56 0.07 0.01 wxWindowBase::GetValidator()
5.56 0.08 0.01 wxMenuItemList::CreateNode(wxNodeBase*, wxNodeBase*, void*, wxListKey const&)
5.56 0.08 0.01 wxWindowBase::AcceptsFocusFromKeyboard() const
5.56 0.09 0.01 CodeBlocksApp::GetEventTable() const
5.56 0.09 0.01 wxMenuItemList::Find(wxListKey const&) const
0.00 0.09 0.00 46629 0.00 0.00 data_start
0.00 0.09 0.00 1486 0.00 0.00 wxFrameBase::GetMenuBar() const
0.00 0.09 0.00 313 0.00 0.00 MainFrame::DoUpdateStatusBar()
0.00 0.09 0.00 313 0.00 0.00 wxFrameBase::GetStatusBar() const
0.00 0.09 0.00 310 0.00 0.00 EditorBase::GetFilename() const
0.00 0.09 0.00 303 0.00 0.00 MainFrame::OnEditorUpdateUI(CodeBlocksEvent&)
0.00 0.09 0.00 100 0.00 0.00 EditorBase::GetModified() const
0.00 0.09 0.00 95 0.00 0.00 EditorBase::IsReadOnly() const
0.00 0.09 0.00 95 0.00 0.00 EditorBase::HasSelection() const
0.00 0.09 0.00 95 0.00 0.00 EditorBase::CanRedo() const
0.00 0.09 0.00 95 0.00 0.00 EditorBase::CanUndo() const
0.00 0.09 0.00 95 0.00 0.00 EditorBase::CanPaste() const
0.00 0.09 0.00 18 0.00 0.00 MainFrame::DoUpdateLayout()
0.00 0.09 0.00 16 0.00 0.00 MainFrame::DoUpdateAppTitle()
0.00 0.09 0.00 15 0.00 0.00 MainFrame::AddPluginInMenus(wxMenu*, cbPlugin*, void (wxObject::*)(wxEvent&), int, bool)
0.00 0.09 0.00 10 0.00 0.00 MainFrame::DoAddPlugin(cbPlugin*)
0.00 0.09 0.00 10 0.00 0.00 MainFrame::OnPluginLoaded(CodeBlocksEvent&)
0.00 0.09 0.00 10 0.00 0.00 MainFrame::AddPluginInSettingsMenu(cbPlugin*)
0.00 0.09 0.00 10 0.00 0.00 MainFrame::AddPluginInHelpPluginsMenu(cbPlugin*)
0.00 0.09 0.00 9 0.00 0.00 MainFrame::OnEditorActivated(CodeBlocksEvent&)
0.00 0.09 0.00 9 0.00 0.00 MainFrame::OnRequestDockWindow(CodeBlocksDockEvent&)
0.00 0.09 0.00 8 0.00 0.00 MainFrame::DoAddPluginToolbar(cbPlugin*)
0.00 0.09 0.00 5 0.00 0.00 CodeBlocksEvent::~CodeBlocksEvent()
0.00 0.09 0.00 4 0.00 0.00 MainFrame::DoFixToolbarsLayout()
0.00 0.09 0.00 3 0.00 0.00 LayoutViewsMap::operator[](wxString const&)
0.00 0.09 0.00 3 0.00 0.00 MainFrame::ShowHideStartPage(bool)
0.00 0.09 0.00 3 0.00 0.00 MainFrame::DoUpdateEditorStyle(wxFlatNotebook*, wxString const&, long)
0.00 0.09 0.00 2 0.00 0.00 CodeBlocksApp::ParseCmdLine(MainFrame*)
0.00 0.09 0.00 2 0.00 0.00 MainFrame::SaveViewLayout(wxString const&, wxString const&, bool)
0.00 0.09 0.00 2 0.00 0.00 MainFrame::OnEditorModified(CodeBlocksEvent&)
0.00 0.09 0.00 2 0.00 0.00 MainFrame::AddPluginInPluginsMenu(cbPlugin*)
0.00 0.09 0.00 2 0.00 0.00 MainFrame::TerminateRecentFilesHistory()
0.00 0.09 0.00 2 0.00 0.00 MainFrame::DoCheckCurrentLayoutForChanges(bool)
0.00 0.09 0.00 2 0.00 0.00 std::_Rb_tree<wxString, wxString, std::_Identity<wxString>, std::less<wxString>, std::allocator<wxString> >::lower_bound(wxString const&)
0.00 0.09 0.00 2 0.00 0.00 std::_Rb_tree<wxString, wxString, std::_Identity<wxString>, std::less<wxString>, std::allocator<wxString> >::upper_bound(wxString const&)
0.00 0.09 0.00 2 0.00 0.00 std::_Rb_tree<wxString, wxString, std::_Identity<wxString>, std::less<wxString>, std::allocator<wxString> >::erase(std::_Rb_tree_iterator<wxString>, std::_Rb_tree_iterator<wxString>)
0.00 0.09 0.00 2 0.00 0.00 std::_Rb_tree<wxString, wxString, std::_Identity<wxString>, std::less<wxString>, std::allocator<wxString> >::_M_erase(std::_Rb_tree_node<wxString>*)
0.00 0.09 0.00 1 0.00 0.00 global constructors keyed to _ZN10appglobals9AppVendorE
--- End code ---
Full output in attach of this message.
What can says, looking at this data?
[attachment deleted by admin]
MortenMacFly:
--- Quote from: xintrea on October 25, 2007, 12:57:46 pm ---What can says, looking at this data?
--- End quote ---
It says everything is fine. We have an event based UI application here.
With regards, Morten.
xintrea:
--- Quote from: eranif on October 24, 2007, 10:50:09 pm ---I do suggest that the OP should try and install another wx based editor on its machine and compare the editing speed.
--- End quote ---
If click left button on project in codeblocks, and select "Notes" tab, open multiline textarea. In this textarea editing work excellent. Cursor running is fast, select text with key or mouse carried without delays.
Editing work slow only in code editor.
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version