while (<>) { $hash{$_} = 1; } open(FD, "/proc/$$/status"); while () { print if /^Vm[RD]/; }