Bank Allocation on program end

Blitz3D Forums/Blitz3D Programming/Bank Allocation on program end

RifRaf(Posted 2009) [#1]
Just as title suggests..

Im wondering how B3D handles its allocated bank memory from createbank() when you end the program if you dont clear them manually first.


Odd question, but if you know please share.

Thanks


Gabriel(Posted 2009) [#2]
When you say "clear" do you mean set the contents to zero or free the bank? When your program ends, all memory used by the entire process will be returned to the OS, regardless of what you do or don't do. I would not imagine that Blitz would be zero'ing that memory though. I can't see any reason for it, and it's not the way most languages work*. If for some reason you wanted it zero'ed, I think you would have to do it.

* Having said that, most languages don't zero newly allocated memory and Blitz does. Still, I can't see any reason it would zero it when it's deallocated.


RifRaf(Posted 2009) [#3]
ok thats good enough , thanks Gabriel.