Developer forums (C::B DEVELOPMENT STRICTLY!) > CodeCompletion redesign

Clang CC

<< < (48/48)

yvesdm3000:
CurrentState.m_CurrentEditorModificationTime  initialization should now be fixed

Yves

BlueHazzard:
How is the update algorithm of the cc? If i open the codeblocks project file one of my processors is at 100%  and the console outputs

--- Code: ---Reindex on tokenindexdb 0x3831db0 project=codeblocks_sf/src/CodeBlocks_wx30-unix.cbp /codeblocks_sf/src/include/configurationpanel.h
ClTranslationUnit::Parse id=127
[Thread 0x7fffb6732700 (LWP 20185) exited]
ClTranslationUnit::UpdateTokenDatabase 127 finished: 74779 tokens processed

--- End code ---

could this be a recursive loop?
Does the parser indexes all files all the time, or does it stop after all project files are parsed?

thank you for your work!

greetings

yvesdm3000:

--- Quote from: BlueHazzard on April 14, 2017, 10:25:08 pm ---How is the update algorithm of the cc? If i open the codeblocks project file one of my processors is at 100%  and the console outputs

--- Code: ---Reindex on tokenindexdb 0x3831db0 project=codeblocks_sf/src/CodeBlocks_wx30-unix.cbp /codeblocks_sf/src/include/configurationpanel.h
ClTranslationUnit::Parse id=127
[Thread 0x7fffb6732700 (LWP 20185) exited]
ClTranslationUnit::UpdateTokenDatabase 127 finished: 74779 tokens processed

--- End code ---

could this be a recursive loop?
Does the parser indexes all files all the time, or does it stop after all project files are parsed?

thank you for your work!

greetings

--- End quote ---

The indexer checks if the timestamp of a file is more recent than the timestamp in the database. If it does, it reindexes and updates the timestamp in the database. Someday I want to extend this with the filesize just in case a file has been reverted (a checksum is probably overkill) .

I actually fixed an issue on this in commit d0c4f433b0b1e619f7fd14794c05d84379db7c1b on 21 of march for an issue where it continuously tried to reindex the same file. I don't know if your build has this fix yet?

Yves

BlueHazzard:

--- Code: ---#0 0xa6ed440 __cxa_throw() ( output\share\codeblocks\plugins\clanglib.dll:??)
#1 0xa6ec266 operator new(unsigned int) () ( output\share\codeblocks\plugins\clanglib.dll:??)
#2 0xa7bae18 typeinfo for std::time_put<wchar_t, std::ostreambuf_iterator<wchar_t, std::char_traits<wchar_t> > >() ( output\share\codeblocks\plugins\clanglib.dll:??)
#3 0xa6f0200 std::bad_alloc::what() const() ( output\share\codeblocks\plugins\clanglib.dll:??)
#4 0xa7784c9 std::allocator_traits<std::allocator<ClAbstractToken> >::max_size(__a=...) (mingw32/4.9.2/include/c++/bits/alloc_traits.h:422)
#5 0xa7784a8 std::allocator_traits<std::allocator<ClAbstractToken> >::allocate(__a=..., __n=131072) (mingw32/4.9.2/include/c++/bits/alloc_traits.h:357)
#6 0xa762a99 std::_Vector_base<ClAbstractToken, std::allocator<ClAbstractToken> >::_M_allocate(this=0x55a1d0bc, __n=131072) ( mingw32/4.9.2/include/c++/bits/stl_vector.h:170)
#7 0xa786642 std::vector<ClAbstractToken, std::allocator<ClAbstractToken> >::_M_emplace_back_aux<ClAbstractToken const&>(this=0x55a1d0bc) ( mingw32/4.9.2/include/c++/bits/vector.tcc:412)
#8 0xa786a06 std::vector<ClAbstractToken, std::allocator<ClAbstractToken> >::push_back(this=0x55a1d0bc, __x=...) ( mingw32/4.9.2/include/c++/bits/stl_vector.h:923)
#9 0xa723c8c ClTreeMap<ClAbstractToken>::Insert(this=0x55a1d0b8, key=..., value=...) ( cclang-plugin/src/ClangLib/src/treemap.h:37)
#10 0xa6e3c77 ClTokenDatabase::InsertToken(this=0xb00fdc8, token=...) ( cclang-plugin\src\ClangLib\src\tokendatabase.cpp:960)
#11 0xa6e9bf0 ClImportClangToken(cursor=..., scopeCursor=..., typ=ClTokenType_FuncDecl, client_data=0xb00fcc8) ( cclang-plugin\src\ClangLib\src\translationunit.cpp:886)
#12 0xa6ea1ea ClAST_Visitor(cursor=..., parent=..., client_data=0xb00fcc8) ( cclang-plugin\src\ClangLib\src\translationunit.cpp:983)
#13 0xf212b76 libclang!clang_disposeTranslationUnit() ( output\libclang.dll:??)
#14 0x42f42028 ?? () (??:??)
#15 0xf215041 libclang!clang_isTranslationUnit() ( output\libclang.dll:??)
#16 0x8 ?? () (??:??)
#17 ?? ?? () (??:??)

--- End code ---

a other crash back trace. It happened after some time idle running

Navigation

[0] Message Index

[*] Previous page

Go to full version