Threadsafe and Global Variable DLL

Questions about MultiCharts and user contributed studies.
arjfca
Posts: 1292
Joined: 23 Nov 2010
Has thanked: 725 times
Been thanked: 223 times

Threadsafe and Global Variable DLL

Postby arjfca » 19 Jul 2012

Hello

Question for an expert in software.

Threadsafe is suppose to accelerate the process of some DLL. Is it appropriate to use the Threadsafe option with the globalvariable dll?

https://www.multicharts.com/trading-sof ... ThreadSafe.

If so, How do I do it?

Martin

Dru
Posts: 107
Joined: 28 Aug 2007
Has thanked: 4 times
Been thanked: 171 times

Re: Threadsafe and Global Variable DLL

Postby Dru » 20 Jul 2012

Hello

Question for an expert in software.

Threadsafe is suppose to accelerate the process of some DLL. Is it appropriate to use the Threadsafe option with the globalvariable dll?

https://www.multicharts.com/trading-sof ... ThreadSafe.

If so, How do I do it?

Martin
Some functions from globalvariable.dll v2.2 can be marked as thread-safe, some ones is not.
For example:
1)

Code: Select all

GV_SetBoolean/GV_GetBoolean, GV_SetInteger/GV_GetInteger, GV_SetDouble/GV_GetDouble etc
can be marked threadsafe because it is threadsafe by implementation.
2)

Code: Select all

GV_SetNamedBool/GV_GetNamedBool etc
can NOT be marked threadsafe because it is NOT threadsafe by implementation.
In any case, you have to look at the implementation of the function you are interested in.

arjfca
Posts: 1292
Joined: 23 Nov 2010
Has thanked: 725 times
Been thanked: 223 times

Re: Threadsafe and Global Variable DLL

Postby arjfca » 20 Jul 2012

Hello

Question for an expert in software.

Threadsafe is suppose to accelerate the process of some DLL. Is it appropriate to use the Threadsafe option with the globalvariable dll?

https://www.multicharts.com/trading-sof ... ThreadSafe.

If so, How do I do it?

Martin
Some functions from globalvariable.dll v2.2 can be marked as thread-safe, some ones is not.
For example:
1)

Code: Select all

GV_SetBoolean/GV_GetBoolean, GV_SetInteger/GV_GetInteger, GV_SetDouble/GV_GetDouble etc
can be marked threadsafe because it is threadsafe by implementation.
2)

Code: Select all

GV_SetNamedBool/GV_GetNamedBool etc
can NOT be marked threadsafe because it is NOT threadsafe by implementation.
In any case, you have to look at the implementation of the function you are interested in.
I use GV_GetNamedString, CV_SetNamedString, so I suppose that I can't use it. If I use numbers instead Name to reference GV, should it be applicable?

I'm greener than a healty grass in that field.. Meaning, I'm loss...

Martin

Dru
Posts: 107
Joined: 28 Aug 2007
Has thanked: 4 times
Been thanked: 171 times

Re: Threadsafe and Global Variable DLL

Postby Dru » 23 Jul 2012

I use GV_GetNamedString, CV_SetNamedString, so I suppose that I can't use it. If I use numbers instead Name to reference GV, should it be applicable?
Yes. I want to note that the "numbers" faster than "names" and the access time is independent of the number of "numbers GV", as the time when access to the "names GV" is directly proportional to the it's amount. Implementation of "named" version is ineffective.

arjfca
Posts: 1292
Joined: 23 Nov 2010
Has thanked: 725 times
Been thanked: 223 times

Re: Threadsafe and Global Variable DLL

Postby arjfca » 23 Jul 2012

I use GV_GetNamedString, CV_SetNamedString, so I suppose that I can't use it. If I use numbers instead Name to reference GV, should it be applicable?
Yes. I want to note that the "numbers" faster than "names" and the access time is independent of the number of "numbers GV", as the time when access to the "names GV" is directly proportional to the it's amount. Implementation of "named" version is ineffective.
Thanks for the info. All my GV are "Names" one.

Strangely, looking in my MC function available, only the names one are there. I will look to re installing the GV and re-code

Martin


Return to “MultiCharts”