CodeModel Assertion after about 5500 declarations in one file

Hamish Rodda rodda at kde.org
Mon Sep 22 23:10:33 UTC 2008


Hi,

On Sunday 21 September 2008 01:09:33 David Nolden wrote:
> Yes, the reason is probably this:
> The item-repositories have a bucket-size limit of about 64 kb. Everything
> put into the repositories must fit into a bucket. However one item for a
> file with 5000 Declarations would have the size 5000 * 12 = 66000, so this
> is for sure the reason.
>
> This could with some work be worked around in the item-reposotory, by
> creating special bigger buckets for items that are larger then bucket-size,
> but that wouldn't change much about the bad performance while
> inserting/removing items. So I recommend just splitting that file up into
> multiple.
>
> Btw. this limit shouldn't be a problem for most languages, since the
> code-model only contains declarations that are put into the symbol-table,
> and I don't think I've ever seen a file with more then 5000
> function-declarations. :-)

Sure, but there is no reason why pretty much any language we plan to support 
couldn't have this problem with a large enough file, and then we will just get 
bug reports.  Do we really want to be putting workarounds into the language 
supports themselves?

Cheers,
Hamish.




More information about the KDevelop-devel mailing list