mIRC Home    About    Download    Register    News    Help

Print Thread
#216377 11/11/09 09:33 PM
Joined: Jan 2007
Posts: 1,156
D
DJ_Sol Offline OP
Hoopy frood
OP Offline
Hoopy frood
D
Joined: Jan 2007
Posts: 1,156
Hello. I am wondering if mirc frees up the memory a hash table took when you /hfree a table.

Joined: Nov 2006
Posts: 1,559
H
Hoopy frood
Offline
Hoopy frood
H
Joined: Nov 2006
Posts: 1,559
It does, as it does for deleting items.
Watch mIRC mem usage - e.g. in the taskmanager - while this is runnning:
Code:
alias htest {
  hmake -s htest
  .timer 1 5 htestadd
}

alias -l htestadd {
  echo -sgc info * adding 100k items...
  var %n = 1
  while (%n <= 100000) { hadd htest %n $str(%n,75) | inc %n }
  echo -sgc info * ...done
  ; or hfree here instantly
  .timer 1 5 htestdel
}

alias -l htestdel {
  echo -sgc info * deleting the items...
  var %n = 100000
  while (%n) { hdel htest %n | dec %n }
  echo -sgc info * ...done
  .timer 1 5 hfree -s htest
}



Link Copied to Clipboard