in reply to Long running tasks, perl and garbage collection

Two things to know about Perl memory management:

I don't know if that helps.

By the way, you are wrong about the RSS increasing from the deallocation.

... print "\nbefore deallocating the huge hash\n" . qx {ps -o rss $$}; undef %x; print "\nafter deallocating the huge hash\n" . qx {ps -o rss $$}; ...
Initial size: RSS 1684 after allocating a huge hash: RSS 9088 before deallocating the huge hash RSS 12532 after deallocating the huge hash RSS 12020 after the huge hash goes out of scope RSS 12020

The increase you saw was probably used to hold the results of keys %x.