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

Patch to Add the ability to Disable Call Tips

(1/1)

Game_Ender:
This patch, posted here on sourceforge.  Here is the description:

Call tips activate whenever you press the '(' key in
front of a function. This patch add another option to
the CodeCompletion menu just like "Disable
CodeCompletion" but for calltips. Current instabilities
in the codecompletetion program can cause it the
threads to dead lock when it tries to generate the call
tips. This also add the config file property
"use_call_tips".

This currently patches the:
settings.xrc - Adds "Disable Call Tips" check box
ccoptionsdlg.cpp - Checks Config and sets the check
box properly and config file properly.
codecompletion.cpp - Checks the value of
"use_call_tips" in the config file before making call tip.
makefile.am - updated to include the proper files.

I would also like to say I get number thread dead locks during codecomplete.  The current one happens during a namespace alias codecompleletion attempt.

EDIT- After some digging it appears the CC code doesn't ignores the max threads options and seems to fire off a thread every time it is asked to parse a file.  There is also a suspicous looking timer in there.  I haven't really done threading much, but I know you should never, ever, ever, count on some kind of timing interval to protect you in a threaded environment.

mandrav:
Thanks for the patch. I hope you submitted it at the patch tracker...


--- Quote ---EDIT- After some digging it appears the CC code doesn't ignores the max threads options and seems to fire off a thread every time it is asked to parse a file.  There is also a suspicous looking timer in there.  I haven't really done threading much, but I know you should never, ever, ever, count on some kind of timing interval to protect you in a threaded environment.
--- End quote ---

I don't have the code in front of me, but the timer is #ifdef'd and used while Rick was profiling his changes in CC.
The reason threads are not counted is because they 're added in a thread pool. This pool only runs X threads concurrently (X == number of CPUs (hyperthreading counts for two ;)))

Navigation

[0] Message Index

Go to full version