From: Sam Roberts Date: 2006-05-23T06:45:49+09:00 Subject: Re: Zed and Luis drop the bomb on Ruby's poor performance Quoting hutch@recursive.ca, on Tue, May 23, 2006 at 05:36:28AM +0900: > Don't forget that string comparison is pretty quick if the strings > differ in the first character. If you try comparing to the same > string and make the string a lot longer (say 2000 characters) you'll > get a situation where symbol comparisons are about three times faster > than string comparisons. But the strings in my app are short, about 20 chars. > Have you tried profiling your code? Yes, performance was dominated by string comparisons, I wrote the benchmark to see if changing to symbols would help. Sam