How fast is perl hash select? -
i use perl hash store ip -> hostname pairs. have millions of it.
i cache gethostbyip syscall in hash %hostname{$ip}.
memory not issue. time is.
how fast perl hash search works in condition?
will work faster if use mysqldb or berkleydb instead?
assuming have sufficient ram hold of data, in-memory lookups always faster retrieving data external source (disk, database, etc.) because ram fast , i/o operations slow.
if can't hold in ram, becomes less predictable , may need benchmark determine what's faster particular combination of program , hardware.
Comments
Post a Comment