Skip site navigation (1) Skip section navigation (2)

Peripheral Links

Header And Logo

PostgreSQL
| The world's most advanced open source database.

Site Navigation

Search for
  Advanced Search

Re: TypeInfoCache



Daniel Migowski wrote:

   getString on text_col took 8.27384ms
   getCharacterStream on text_col took 14.26489ms
   Factor: 1.724095462324628
   getString on varchar_col took 9.57153ms
   getCharacterStream on varchar_col took 12.76733ms
   Factor: 1.3338860140437319

Conclusion: There is no real performance loss even in the worst case (which should never occur anyway), so please accept my patch. I wish you all a happy new year!

I'm confused. Don't your numbers show a 30%-70% slowdown when using getCharacterStream()?

Also some quick notes about microbenchmarks:

- 1000 iterations isn't really enough to get useful numbers, try 20,000+ for JIT effects or considerably more for GC effects - server vs. client JVM can have quite different behaviours, you should check both - put your inner benchmark loops in a separate method as some JIT has method-level granularity - benchmark the same code path in your warmup loop as you actually measure the numbers from. In your code, you're benchmarking a different code path to the one you run in your warmup loop.

-O



Home | Main Index | Thread Index

Privacy Policy | PostgreSQL Archives hosted by Command Prompt, Inc. | Designed by tinysofa
Copyright © 1996 – 2008 PostgreSQL Global Development Group