Reentrancy problems in Krita code

Dmitry Kazakov dimula73 at gmail.com
Tue Jun 1 20:40:44 CEST 2010


Hi, All!

I've just commited a new update scheduler for projection updates. It works
like an alternative to KisProjection, but with a framework for optimization
of the update queue. It is intended to run updates in several threads, but
it faced with some problems with reentrancy of our code.

There are at least three places, where concurrency causes a crash:

1) KoColorSpaceRegistry::grabColorSpace

http://pastebin.com/c1FqGLS9
http://pastebin.com/HYfPEE9E

2)  <some unknown place for me>
http://pastebin.com/rbqLRwJS

3) KisMementoManager::removeMemento
I'll try to work this crash out.

How to reproduce:
1) First you have to disable workaround that limits the number of concurrent
threads by 1: comment out the line in kis_updater_context.cpp:35 that
hardcodes the number of threads.
2) Then run image/tests/KisUpdateSchedulerTest several times (on multicore
PC, of course)

And you'll see these crashes... :(



-- 
Dmitry Kazakov
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.kde.org/pipermail/kimageshop/attachments/20100601/319e32c6/attachment.htm 


More information about the kimageshop mailing list