Page 3 of 3

Posted: Wed May 28, 2008 1:09 am
by Fred
srod wrote:Can I ask why PB passes an extra parameter when calling compiled user lib functions?
PB could need to reuse this parameter value, after the function call. Before VC8, the parameter value was never changed by the called function (as it was pushed on the stack which is not in the function scope), so we could use a trick to get it back if needed. With VC8, this trick didn't work anymore (the function can modify the user-parameter stack), so we have to duplicate the push, to be able to get it back if needed.

Posted: Wed May 28, 2008 1:18 am
by Mistrel
Is there an inconsistency somewhere that prevents us from calling an exported function that returns a string from within the same library? I'm assuming that the ASM output is different between a Procedure and ProcedureDLL.

Would it be possible to keep the ASM the same so that we can call these functions again with TailBite?

Posted: Wed May 28, 2008 2:52 am
by Mistrel
Removed by Mistrel. (I fixed the problem)

Posted: Wed May 28, 2008 8:46 am
by srod
Fred wrote:
srod wrote:Can I ask why PB passes an extra parameter when calling compiled user lib functions?
PB could need to reuse this parameter value, after the function call. Before VC8, the parameter value was never changed by the called function (as it was pushed on the stack which is not in the function scope), so we could use a trick to get it back if needed. With VC8, this trick didn't work anymore (the function can modify the user-parameter stack), so we have to duplicate the push, to be able to get it back if needed.
I see. Must admit that I have no experience with VC and so can't imagine why functions would modify the parameter stack? Still, mine is not to wonder why! :) Thanks.

Posted: Wed May 28, 2008 9:49 am
by Fred
Mistrel wrote:Is there an inconsistency somewhere that prevents us from calling an exported function that returns a string from within the same library? I'm assuming that the ASM output is different between a Procedure and ProcedureDLL.

Would it be possible to keep the ASM the same so that we can call these functions again with TailBite?
Actually, there could be a solution on the compiler side. TailBaite creates pblibraries with the 'ASM' flags (in the .desc), right ?

Posted: Wed May 28, 2008 9:55 am
by srod
Fred wrote:
Mistrel wrote:Is there an inconsistency somewhere that prevents us from calling an exported function that returns a string from within the same library? I'm assuming that the ASM output is different between a Procedure and ProcedureDLL.

Would it be possible to keep the ASM the same so that we can call these functions again with TailBite?
Actually, there could be a solution on the compiler side. TailBaite creates pblibraries with the 'ASM' flags (in the .desc), right ?
Yes, that is correct.

Now, if you're saying that you may be able to adjust the compiler then I'm glad I halted my ammendments to coffIT! Foresight or what? :)

Re: Calling exported string functions - PB 4.2 beta 2

Posted: Fri Mar 18, 2011 12:02 am
by Droopy
Hello, an asm guru can look @ this to fix this bug ?

Re: Calling exported string functions - PB 4.2 beta 2

Posted: Mon Jul 25, 2011 2:10 pm
by Progi1984
Some news Droopy ?