Re: MMAP Buffers

From: Radosław Smogura <rsmogura(at)softperience(dot)eu>
To: Joshua Berkus <josh(at)agliodbs(dot)com>
Cc: Andrew Dunstan <andrew(at)dunslane(dot)net>, Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com>, PG Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: MMAP Buffers
Date: 2011-04-15 17:36:44
Message-ID: 201104151936.44487.rsmogura@softperience.eu
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Joshua Berkus <josh(at)agliodbs(dot)com> Friday 15 April 2011 18:55:04
> Radoslaw,
>
> 10% improvement isn't very impressive from a switch to mmap. What workload
> did you test with? What I'd really like to see is testing with databases
> which are 50%, 90% and 200% the size of RAM ... that's where I'd expect
> the greatest gain from limiting copying.
I think 10% is quite good, as my stand-alone test of mmap vs. read shown that
speed up of copying 100MB data to mem may be from ~20ms to ~100ms (depends on
destination address). Of course deeper, system test simulating real usage will
say more. In any case after good deals with writes, I will speed up reads. I
think to bypass smgr/md much more and to expose shared id's (1,2,3...) for
each file segment.

Going to topic...

In attachment I sent test-scripts which I used to fill data, nothing complex
(left from 2nd level caches).

Query I've used to measure was SELECT count(substr(content, 1, 1)) FROM
testcase1 WHERE multi_id > 50000;

Timings ware taken from psql.

I didn't made load (I have about 2GB of free sapce at /home, and 4GB RAM) and
stress (I'm not quite ready to try concurrent updates of same page - may fail,
notice is and place to fix is in code) tests yet.

> > Netbeans is possibly not very well suited to working on postgres code.
> > AFAIK emacs and/or vi(m) are used by almost all the major developers.
>
> Guys, can we *please* focus on the patch for now, rather than the
> formatting, which is fixable with sed?
Netbeans is quite good, of course it depends who likes what. Just try 7.0 RC
2.

Regards,
Radek

Attachment Content-Type Size
test-scritps_20110319_0026.tar.bz2 application/x-bzip-compressed-tar 2.4 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Heikki Linnakangas 2011-04-15 17:56:19 pgsql: setlocale() on Windows doesn't work correctly if the locale name
Previous Message Joshua D. Drake 2011-04-15 17:30:55 Re: Single client performance on trivial SELECTs