[ns] Help regarding absurd memory usage
fhg07@c3sl.ufpr.br
fhg07 at c3sl.ufpr.br
Tue Mar 24 17:00:27 PDT 2009
I am simulating a protocol which I developed, and I wanted the simulation
to end only when all my nodes are dead. Well, that is not really that fast
to happen, and before I reach that point my memory ends and I get a
bac_alloc error message.
And here is the thing: I do alloc lots of packets with allocpkt, and I
also always manage to free them with Packet::free(Packet *), but even when
I free them, the memory usage don't even change ! And I am not
overreacting when I say this, I made some experiments, and the average
memory used when freeing all packet was exactly the same of when I did the
same simulation withou freeing them.
What do I need to do when I intend to have huge simulations, with like
15000 packets flying in the air? Using Packet::free didn't solve my
problem. I even tried editing this function and inserting "free(pkt);" in
its end, but it was in vain.
Can someone please help me?
Thanks,
--
Fernando Henrique Gielow - UFPR - NR2
Computer Science undergraduate student.
More information about the Ns-users
mailing list