in reply to How much memory am I using?
my $size = `ps -p $$ -h -o size`;
This reports the size of the process in K.