J
John Ky
[Note: parts of this message were removed to make it a legal post.]
Hi all,
I've got some code, which when run uses a lot of memory (aprox 600 MB for a
particular given input). I am trying to figure out why it is using so much.
When I replace the following code:
head.play_back do |root|
block.call(root)
end
With this:
head.play_back(&block)
And make other similar changes. The program behaves exactly the same way,
but now uses 200MB less. Can someone explain to me why this is the case?
I use blocks everywhere and I'm worried, they're leaking in my code.
joky@linux08:~/wa/bvc-pure-cs/comet/src/swig_client_api/ruby $ ruby -v
ruby 1.8.7 (2008-06-20 patchlevel 22) [i686-linux]
Thanks
-John
Hi all,
I've got some code, which when run uses a lot of memory (aprox 600 MB for a
particular given input). I am trying to figure out why it is using so much.
When I replace the following code:
head.play_back do |root|
block.call(root)
end
With this:
head.play_back(&block)
And make other similar changes. The program behaves exactly the same way,
but now uses 200MB less. Can someone explain to me why this is the case?
I use blocks everywhere and I'm worried, they're leaking in my code.
joky@linux08:~/wa/bvc-pure-cs/comet/src/swig_client_api/ruby $ ruby -v
ruby 1.8.7 (2008-06-20 patchlevel 22) [i686-linux]
Thanks
-John