Would you be willing to post code? It can be very difficult (read: impossible) to diagnose problems like this without the actual program. I can assure you it is quite possible to overflow 1GB even with a few agents, especially if you're building networks. One place to look first is to ensure that you are not creating new network links between agents that already have links; you would probably want to modify link strength instead of creating multiple links.