bug 657418 comment 12 points out that the (#4 top-crash fixing) patch in bug 657418 effectively disables the eval cache for the shell (where most principals are NULL). This can be fixed by a simple tweak to EvalCacheLookup logic so that you still get a hit (just without crashing).
Created attachment 546640 [details] [diff] [review]
make shell go fast again
Confirmed 20ms speedup (over de-optimized trunk) in shell.