comp.lang.ada
 help / color / mirror / Atom feed
From: "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de>
Subject: Re: Ada vs SQLite3 benchmark
Date: Thu, 18 Sep 2014 09:27:21 +0200
Date: 2014-09-18T09:27:21+02:00	[thread overview]
Message-ID: <122qvkxwx9207$.x2ietmtp83wg$.dlg@40tude.net> (raw)
In-Reply-To: lvdrqi$s6c$1@dont-email.me

On Thu, 18 Sep 2014 07:50:09 +0200, Georg Bauhaus wrote:

> On 17.09.14 18:51, Dmitry A. Kazakov wrote:
>> http://ada-programming.blogspot.de/2014/09
>>
>> The implementation of B-tree is based on Ada.Direct_IO with a transaction
>> layer, e.g. for safety against system failure.
> 
> What will the comparison look like if you let SQLite3 open the file
> ":memory:", thus an in-memory data base? Which will require to then
> occasionally .dump its contents into another, persistent SQLite3 database.
> 
> http://www.sqlite.org/inmemorydb.html

In would make no sense, IMO.

Let us consider the use case when everything fits into the memory. Why not
to use plain containers then?

Even if some sort of persistency is needed in this scenario, a persistency
layer can be added to a plain Ada container at *zero* performance cost.
E.g.

http://www.dmitry-kazakov.de/ada/components.htm#persistent_objects

I can tell without any benchmarks that Ada's standard containers or any
other would easily beat memory-mapped SQLite.

P.S. I had serious problems with the Kyoto Cabinet in the past. KC is a
single-file B-tree implementation written in C. It is not fail-safe, but
that was irrelevant to me. KC did what you described by OS means, it opened
the file as memory mapped. I was unaware of that until the DB grew 2GB,
then ... I am a bit allergic to memory-mapped files since.

-- 
Regards,
Dmitry A. Kazakov
http://www.dmitry-kazakov.de


  reply	other threads:[~2014-09-18  7:27 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-17 16:51 Ada vs SQLite3 benchmark Dmitry A. Kazakov
2014-09-17 23:26 ` gdotone
2014-09-18  0:16 ` Jeffrey Carter
2014-09-18  7:31   ` Dmitry A. Kazakov
2014-09-18  5:50 ` Georg Bauhaus
2014-09-18  7:27   ` Dmitry A. Kazakov [this message]
2014-09-18  7:56     ` Georg Bauhaus
2014-09-18  8:05       ` Dmitry A. Kazakov
2014-09-18  8:08       ` briot.emmanuel
2014-09-18 20:08         ` Dmitry A. Kazakov
2014-09-18  8:17 ` Marius Amado-Alves
2014-09-18 13:41 ` Jacob Sparre Andersen
2014-09-18 19:42   ` Dmitry A. Kazakov
2014-09-18 17:09 ` Pascal Obry
2014-09-22 15:43   ` Gour
2014-09-22 16:08     ` Pascal Obry
2014-09-22 17:00       ` Gour
2014-09-22 16:29     ` Dmitry A. Kazakov
2014-09-22 17:02       ` Gour
2014-09-22 19:09         ` Dmitry A. Kazakov
2014-09-22 20:19           ` Gour
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox