• Re: KidStack size

    From =?UTF-8?Q?Gorazd_Petrovi=C4=8D?=@21:1/5 to Peter Gargos on Thu Jul 6 01:27:53 2023
    Peter hi,

    I know it has been a very long since, but maybe you still remember.
    I have the same Kidstack limit problem: while I am calling function recursively, it throws error at practically the same number of calls 663 and with almost the same MEMORY_STACKKID value 674.

    Do you maybe rememer how you solved your problem?

    Best regards, Gorazd

    On Wednesday, October 10, 2007 at 11:20:35 AM UTC+2, Peter Gargos wrote:
    Hi all,
    I have my own quick sort routine with recursive calls.
    Sorting 1000 or higher items cause "Kid stack size limit exceeded".
    Routine crash afther 665 self calls, MEMORY_STACKKID show 675. SetKidStackSize has no any effect. I you set StackSize to 16MB
    ( default is 8kB ),
    before crash KidStackFree func report 16769116 bytes free !!.
    Where is problem ? ( VO28+SP1 )
    Thanks,
    Peter Gargos
    Softcomp Technology

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Jamal@21:1/5 to All on Fri Jul 7 01:06:06 2023
    Try the following in your program's Start method:

    SetMaxRegisteredKids( 100000 ) // default 16000
    SetMaxRegisteredAxitMethods( 100000 )

    Do the above solve your problem?

    Jamal


    On 7/6/2023 4:27 AM, Gorazd Petrovič wrote:
    Peter hi,

    I know it has been a very long since, but maybe you still remember.
    I have the same Kidstack limit problem: while I am calling function recursively, it throws error at practically the same number of calls 663 and with almost the same MEMORY_STACKKID value 674.

    Do you maybe rememer how you solved your problem?

    Best regards, Gorazd

    On Wednesday, October 10, 2007 at 11:20:35 AM UTC+2, Peter Gargos wrote:
    Hi all,
    I have my own quick sort routine with recursive calls.
    Sorting 1000 or higher items cause "Kid stack size limit exceeded".
    Routine crash afther 665 self calls, MEMORY_STACKKID show 675.
    SetKidStackSize has no any effect. I you set StackSize to 16MB
    ( default is 8kB ),
    before crash KidStackFree func report 16769116 bytes free !!.
    Where is problem ? ( VO28+SP1 )
    Thanks,
    Peter Gargos
    Softcomp Technology

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From =?UTF-8?Q?Gorazd_Petrovi=C4=8D?=@21:1/5 to Jamal on Fri Jul 7 01:02:54 2023
    Hi Jamal,
    Unfortunately this does not help. When error occurs the following resources are reported:
    MEMORY_REGISTERAXIT = 67 (out of max 100000 set by SetMaxRegisteredAxitMethods) MEMORY_REGISTEREDKID = 165 (out of max 100000 set by SetMaxRegisteredKids) MEMORY_STACK_FREE = 742044, MEMORY_STACK_SIZE 921600
    MEMORY_STACKKID = 676 (practically the same number as in Peter Gargos case)
    The level of recursion is 663 (again practically the same number as in Peter Gargos case).
    The error says "Kid Stack Size limit exceeded". This reads as a limit in Kid Stack Size which is obviously 676, but I do not know where to rise that limit. In help there is a function SetKidStackSpace() which could be used, but does not work (compiler
    throws error "bad function call").
    It seems that I need a function like something SetMaxKidStackSize() :-)
    Or is there maybe some registry setting available?

    Gorazd



    On Friday, July 7, 2023 at 7:06:08 AM UTC+2, Jamal wrote:
    Try the following in your program's Start method:

    SetMaxRegisteredKids( 100000 ) // default 16000
    SetMaxRegisteredAxitMethods( 100000 )

    Do the above solve your problem?

    Jamal
    On 7/6/2023 4:27 AM, Gorazd Petrovič wrote:
    Peter hi,

    I know it has been a very long since, but maybe you still remember.
    I have the same Kidstack limit problem: while I am calling function recursively, it throws error at practically the same number of calls 663 and with almost the same MEMORY_STACKKID value 674.

    Do you maybe rememer how you solved your problem?

    Best regards, Gorazd

    On Wednesday, October 10, 2007 at 11:20:35 AM UTC+2, Peter Gargos wrote:
    Hi all,
    I have my own quick sort routine with recursive calls.
    Sorting 1000 or higher items cause "Kid stack size limit exceeded".
    Routine crash afther 665 self calls, MEMORY_STACKKID show 675.
    SetKidStackSize has no any effect. I you set StackSize to 16MB
    ( default is 8kB ),
    before crash KidStackFree func report 16769116 bytes free !!.
    Where is problem ? ( VO28+SP1 )
    Thanks,
    Peter Gargos
    Softcomp Technology

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Jamal@21:1/5 to All on Fri Jul 7 15:18:49 2023
    Can post the code that replicates the issue or you can head to https://xsharp.eu and post your question to the forum where you may get
    an answer from Robert.





    On 7/7/2023 4:02 AM, Gorazd Petrovič wrote:

    Hi Jamal,
    Unfortunately this does not help. When error occurs the following resources are reported:
    MEMORY_REGISTERAXIT = 67 (out of max 100000 set by SetMaxRegisteredAxitMethods)
    MEMORY_REGISTEREDKID = 165 (out of max 100000 set by SetMaxRegisteredKids) MEMORY_STACK_FREE = 742044, MEMORY_STACK_SIZE 921600
    MEMORY_STACKKID = 676 (practically the same number as in Peter Gargos case) The level of recursion is 663 (again practically the same number as in Peter Gargos case).
    The error says "Kid Stack Size limit exceeded". This reads as a limit in Kid Stack Size which is obviously 676, but I do not know where to rise that limit. In help there is a function SetKidStackSpace() which could be used, but does not work (compiler
    throws error "bad function call").
    It seems that I need a function like something SetMaxKidStackSize() :-)
    Or is there maybe some registry setting available?

    Gorazd



    On Friday, July 7, 2023 at 7:06:08 AM UTC+2, Jamal wrote:
    Try the following in your program's Start method:

    SetMaxRegisteredKids( 100000 ) // default 16000
    SetMaxRegisteredAxitMethods( 100000 )

    Do the above solve your problem?

    Jamal
    On 7/6/2023 4:27 AM, Gorazd Petrovič wrote:
    Peter hi,

    I know it has been a very long since, but maybe you still remember.
    I have the same Kidstack limit problem: while I am calling function recursively, it throws error at practically the same number of calls 663 and with almost the same MEMORY_STACKKID value 674.

    Do you maybe rememer how you solved your problem?

    Best regards, Gorazd

    On Wednesday, October 10, 2007 at 11:20:35 AM UTC+2, Peter Gargos wrote: >>>> Hi all,
    I have my own quick sort routine with recursive calls.
    Sorting 1000 or higher items cause "Kid stack size limit exceeded".
    Routine crash afther 665 self calls, MEMORY_STACKKID show 675.
    SetKidStackSize has no any effect. I you set StackSize to 16MB
    ( default is 8kB ),
    before crash KidStackFree func report 16769116 bytes free !!.
    Where is problem ? ( VO28+SP1 )
    Thanks,
    Peter Gargos
    Softcomp Technology

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From =?UTF-8?Q?Gorazd_Petrovi=C4=8D?=@21:1/5 to Jamal on Sat Jul 8 11:33:53 2023
    Hi Jamal,
    thanks for your help. I guess I will first try with the basic recursion function and then slowly adding more functionalties. This way I hope I will be able to find what the problem is.

    On Friday, July 7, 2023 at 9:18:50 PM UTC+2, Jamal wrote:
    Can post the code that replicates the issue or you can head to https://xsharp.eu and post your question to the forum where you may get
    an answer from Robert.
    On 7/7/2023 4:02 AM, Gorazd Petrovič wrote:

    Hi Jamal,
    Unfortunately this does not help. When error occurs the following resources are reported:
    MEMORY_REGISTERAXIT = 67 (out of max 100000 set by SetMaxRegisteredAxitMethods)
    MEMORY_REGISTEREDKID = 165 (out of max 100000 set by SetMaxRegisteredKids) MEMORY_STACK_FREE = 742044, MEMORY_STACK_SIZE 921600
    MEMORY_STACKKID = 676 (practically the same number as in Peter Gargos case)
    The level of recursion is 663 (again practically the same number as in Peter Gargos case).
    The error says "Kid Stack Size limit exceeded". This reads as a limit in Kid Stack Size which is obviously 676, but I do not know where to rise that limit. In help there is a function SetKidStackSpace() which could be used, but does not work (
    compiler throws error "bad function call").
    It seems that I need a function like something SetMaxKidStackSize() :-)
    Or is there maybe some registry setting available?

    Gorazd



    On Friday, July 7, 2023 at 7:06:08 AM UTC+2, Jamal wrote:
    Try the following in your program's Start method:

    SetMaxRegisteredKids( 100000 ) // default 16000
    SetMaxRegisteredAxitMethods( 100000 )

    Do the above solve your problem?

    Jamal
    On 7/6/2023 4:27 AM, Gorazd Petrovič wrote:
    Peter hi,

    I know it has been a very long since, but maybe you still remember.
    I have the same Kidstack limit problem: while I am calling function recursively, it throws error at practically the same number of calls 663 and with almost the same MEMORY_STACKKID value 674.

    Do you maybe rememer how you solved your problem?

    Best regards, Gorazd

    On Wednesday, October 10, 2007 at 11:20:35 AM UTC+2, Peter Gargos wrote:
    Hi all,
    I have my own quick sort routine with recursive calls.
    Sorting 1000 or higher items cause "Kid stack size limit exceeded". >>>> Routine crash afther 665 self calls, MEMORY_STACKKID show 675.
    SetKidStackSize has no any effect. I you set StackSize to 16MB
    ( default is 8kB ),
    before crash KidStackFree func report 16769116 bytes free !!.
    Where is problem ? ( VO28+SP1 )
    Thanks,
    Peter Gargos
    Softcomp Technology

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Pete@21:1/5 to All on Tue Jul 18 11:30:03 2023
    Dne sobota 8. července 2023 v 20:33:55 UTC+2 uživatel Gorazd Petrovič napsal:
    Hi Jamal,
    thanks for your help. I guess I will first try with the basic recursion function and then slowly adding more functionalties. This way I hope I will be able to find what the problem is.
    On Friday, July 7, 2023 at 9:18:50 PM UTC+2, Jamal wrote:
    Can post the code that replicates the issue or you can head to https://xsharp.eu and post your question to the forum where you may get
    an answer from Robert.
    On 7/7/2023 4:02 AM, Gorazd Petrovič wrote:

    Hi Jamal,
    Unfortunately this does not help. When error occurs the following resources are reported:
    MEMORY_REGISTERAXIT = 67 (out of max 100000 set by SetMaxRegisteredAxitMethods)
    MEMORY_REGISTEREDKID = 165 (out of max 100000 set by SetMaxRegisteredKids)
    MEMORY_STACK_FREE = 742044, MEMORY_STACK_SIZE 921600
    MEMORY_STACKKID = 676 (practically the same number as in Peter Gargos case)
    The level of recursion is 663 (again practically the same number as in Peter Gargos case).
    The error says "Kid Stack Size limit exceeded". This reads as a limit in Kid Stack Size which is obviously 676, but I do not know where to rise that limit. In help there is a function SetKidStackSpace() which could be used, but does not work (
    compiler throws error "bad function call").
    It seems that I need a function like something SetMaxKidStackSize() :-) Or is there maybe some registry setting available?

    Gorazd



    On Friday, July 7, 2023 at 7:06:08 AM UTC+2, Jamal wrote:
    Try the following in your program's Start method:

    SetMaxRegisteredKids( 100000 ) // default 16000
    SetMaxRegisteredAxitMethods( 100000 )

    Do the above solve your problem?

    Jamal
    On 7/6/2023 4:27 AM, Gorazd Petrovič wrote:
    Peter hi,

    I know it has been a very long since, but maybe you still remember. >>> I have the same Kidstack limit problem: while I am calling function recursively, it throws error at practically the same number of calls 663 and with almost the same MEMORY_STACKKID value 674.

    Do you maybe rememer how you solved your problem?

    Best regards, Gorazd

    On Wednesday, October 10, 2007 at 11:20:35 AM UTC+2, Peter Gargos wrote:
    Hi all,
    I have my own quick sort routine with recursive calls.
    Sorting 1000 or higher items cause "Kid stack size limit exceeded". >>>> Routine crash afther 665 self calls, MEMORY_STACKKID show 675.
    SetKidStackSize has no any effect. I you set StackSize to 16MB
    ( default is 8kB ),
    before crash KidStackFree func report 16769116 bytes free !!.
    Where is problem ? ( VO28+SP1 )
    Thanks,
    Peter Gargos
    Softcomp Technology

    Hi Boys afther 16 years,
    I forgot QuickSort Routine and replace with Selection Sort. Slightly slower, but in my case ( several thousand items )
    there is no problem.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From =?UTF-8?Q?Gorazd_Petrovi=C4=8D?=@21:1/5 to Pete on Wed Jul 19 01:19:01 2023
    I did a simple test and opened a new topic: https://groups.google.com/g/comp.lang.clipper.visual-objects/c/rPza_0Oex2M/m/gV5e6CemAgAJ.

    So, having problem with "Kid Stack Size Limit Exceeded" I did a simple test. I wrote a function Recursion_test() which I called recursively. The function gets called 664 times and then throws error "Kid Stack Size Limit Exceeded".
    Given the fact that there are no additional objects instanciated and no additional variables initialized I expected the error would be corrected by assigning proper value to SetKidStackSize(), but this was not the case. It seems there is another
    limitation set in CAVO which I do not know how to remove.

    This is the function:
    FUNCTION Recursion_test(nLevel)
    Default(@nLevel,1)
    nLevel:=nLevel+1
    Recursion_test(nLevel)
    RETURN

    And these are values when error occurs:
    Memory(MEMORY_STACKKID) 678, SetKidStackSize(0) is set to 8192 Memory(MEMORY_REGISTERKID) 65, SetMaxRegisteredKids(0) is set to 10000 Memory(MEMORY_REGISTERAXIT) 222, SetMaxRegisteredAxitMethods(0) is set to 64000 MEMORY_STACK_SIZE 1069056, MEMORY_STACK_FREE 1035688
    MEMORY_REGISTEREXIT_COUNT 3

    As you can see none of the parameters is over the limit.

    On Tuesday, July 18, 2023 at 8:30:05 PM UTC+2, Pete wrote:
    Dne sobota 8. července 2023 v 20:33:55 UTC+2 uživatel Gorazd Petrovič napsal:
    Hi Jamal,
    thanks for your help. I guess I will first try with the basic recursion function and then slowly adding more functionalties. This way I hope I will be able to find what the problem is.
    On Friday, July 7, 2023 at 9:18:50 PM UTC+2, Jamal wrote:
    Can post the code that replicates the issue or you can head to https://xsharp.eu and post your question to the forum where you may get an answer from Robert.
    On 7/7/2023 4:02 AM, Gorazd Petrovič wrote:

    Hi Jamal,
    Unfortunately this does not help. When error occurs the following resources are reported:
    MEMORY_REGISTERAXIT = 67 (out of max 100000 set by SetMaxRegisteredAxitMethods)
    MEMORY_REGISTEREDKID = 165 (out of max 100000 set by SetMaxRegisteredKids)
    MEMORY_STACK_FREE = 742044, MEMORY_STACK_SIZE 921600
    MEMORY_STACKKID = 676 (practically the same number as in Peter Gargos case)
    The level of recursion is 663 (again practically the same number as in Peter Gargos case).
    The error says "Kid Stack Size limit exceeded". This reads as a limit in Kid Stack Size which is obviously 676, but I do not know where to rise that limit. In help there is a function SetKidStackSpace() which could be used, but does not work (
    compiler throws error "bad function call").
    It seems that I need a function like something SetMaxKidStackSize() :-)
    Or is there maybe some registry setting available?

    Gorazd



    On Friday, July 7, 2023 at 7:06:08 AM UTC+2, Jamal wrote:
    Try the following in your program's Start method:

    SetMaxRegisteredKids( 100000 ) // default 16000
    SetMaxRegisteredAxitMethods( 100000 )

    Do the above solve your problem?

    Jamal
    On 7/6/2023 4:27 AM, Gorazd Petrovič wrote:
    Peter hi,

    I know it has been a very long since, but maybe you still remember. >>> I have the same Kidstack limit problem: while I am calling function recursively, it throws error at practically the same number of calls 663 and with almost the same MEMORY_STACKKID value 674.

    Do you maybe rememer how you solved your problem?

    Best regards, Gorazd

    On Wednesday, October 10, 2007 at 11:20:35 AM UTC+2, Peter Gargos wrote:
    Hi all,
    I have my own quick sort routine with recursive calls.
    Sorting 1000 or higher items cause "Kid stack size limit exceeded". >>>> Routine crash afther 665 self calls, MEMORY_STACKKID show 675.
    SetKidStackSize has no any effect. I you set StackSize to 16MB
    ( default is 8kB ),
    before crash KidStackFree func report 16769116 bytes free !!.
    Where is problem ? ( VO28+SP1 )
    Thanks,
    Peter Gargos
    Softcomp Technology
    Hi Boys afther 16 years,
    I forgot QuickSort Routine and replace with Selection Sort. Slightly slower, but in my case ( several thousand items )
    there is no problem.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)