Talk:Find limit of recursion: Difference between revisions
Content added Content deleted
mNo edit summary |
m (Add a header to the first section.) |
||
Line 1: | Line 1: | ||
== It depends == |
|||
I suspect that the recursion limit depends often on the compiler (for compiled languages), operating system (stack assigned to a process could be tuned, I suppose, and may change from O.S. to O.S.), implementation of an "interpreter" (when more than one exists) and/or on how the recursive function/method/whatever is written. E.g. C version passes an argument to keep track of the depth, Sather uses a class attribute ... Different ways change the limit (it's not the case of the C version in my tests since clearly gcc optimizes using a register to pass the only argument) ... |
I suspect that the recursion limit depends often on the compiler (for compiled languages), operating system (stack assigned to a process could be tuned, I suppose, and may change from O.S. to O.S.), implementation of an "interpreter" (when more than one exists) and/or on how the recursive function/method/whatever is written. E.g. C version passes an argument to keep track of the depth, Sather uses a class attribute ... Different ways change the limit (it's not the case of the C version in my tests since clearly gcc optimizes using a register to pass the only argument) ... |
||