gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] r5337 - in GNUnet/src/applications: sqstore_mysql sqstore_s


From: gnunet
Subject: [GNUnet-SVN] r5337 - in GNUnet/src/applications: sqstore_mysql sqstore_sqlite
Date: Sun, 22 Jul 2007 01:52:01 -0600 (MDT)

Author: grothoff
Date: 2007-07-22 01:52:00 -0600 (Sun, 22 Jul 2007)
New Revision: 5337

Modified:
   GNUnet/src/applications/sqstore_mysql/mysql.c
   GNUnet/src/applications/sqstore_mysql/mysqltest2.c
   GNUnet/src/applications/sqstore_mysql/mysqltest3.c
   GNUnet/src/applications/sqstore_sqlite/sqlite.c
   GNUnet/src/applications/sqstore_sqlite/sqlitetest2.c
   GNUnet/src/applications/sqstore_sqlite/sqlitetest3.c
Log:
fixes

Modified: GNUnet/src/applications/sqstore_mysql/mysql.c
===================================================================
--- GNUnet/src/applications/sqstore_mysql/mysql.c       2007-07-22 07:20:56 UTC 
(rev 5336)
+++ GNUnet/src/applications/sqstore_mysql/mysql.c       2007-07-22 07:52:00 UTC 
(rev 5337)
@@ -940,7 +940,6 @@
                   datum,
                   closure,
                   vkey);
-      FREE(datum);
       if (ret == SYSERR) 
        break;        
       if (ret == NO) {
@@ -950,6 +949,7 @@
        content_size -= ntohl(datum->size);
        MUTEX_UNLOCK (lock);
       }
+      FREE(datum);
     }
   }
   mysql_thread_end ();

Modified: GNUnet/src/applications/sqstore_mysql/mysqltest2.c
===================================================================
--- GNUnet/src/applications/sqstore_mysql/mysqltest2.c  2007-07-22 07:20:56 UTC 
(rev 5336)
+++ GNUnet/src/applications/sqstore_mysql/mysqltest2.c  2007-07-22 07:52:00 UTC 
(rev 5337)
@@ -226,7 +226,8 @@
 #if REPORT_ID
                "\n"
 #endif
-               "Useful %llu, API %llu, disk %llu (%.2f%%) / %lluk ops / %llu 
ops/s\n", stored_bytes / 1024,     /* used size in k */
+               "Useful %llu, API %llu, disk %llu (%.2f%%) / %lluk ops / %llu 
ops/s\n", 
+              stored_bytes / 1024,     /* used size in k */
                api->getSize () / 1024,  /* API-reported size in k */
                size / 1024,     /* disk size in kb */
                (100.0 * size / stored_bytes) - 100,     /* overhead */

Modified: GNUnet/src/applications/sqstore_mysql/mysqltest3.c
===================================================================
--- GNUnet/src/applications/sqstore_mysql/mysqltest3.c  2007-07-22 07:20:56 UTC 
(rev 5336)
+++ GNUnet/src/applications/sqstore_mysql/mysqltest3.c  2007-07-22 07:52:00 UTC 
(rev 5337)
@@ -40,7 +40,7 @@
  */
 #define MAX_SIZE 1024LL * 1024 * 128
 
-#define ITERATIONS 1
+#define ITERATIONS 10
 
 /**
  * Number of put operations equivalent to 1/10th of MAX_SIZE

Modified: GNUnet/src/applications/sqstore_sqlite/sqlite.c
===================================================================
--- GNUnet/src/applications/sqstore_sqlite/sqlite.c     2007-07-22 07:20:56 UTC 
(rev 5336)
+++ GNUnet/src/applications/sqstore_sqlite/sqlite.c     2007-07-22 07:52:00 UTC 
(rev 5337)
@@ -359,8 +359,8 @@
   if (stats)
     stats->set (stat_size, ret);
   MUTEX_UNLOCK (db->DATABASE_Lock_);
-  return (unsigned long long) (ret * 1.06);
-  /* benchmarking shows 2-12% overhead */
+  return (unsigned long long) (ret * 1.13);
+  /* benchmarking shows 13% overhead */
 }
 
 static int delete_by_rowid(sqliteHandle * handle,

Modified: GNUnet/src/applications/sqstore_sqlite/sqlitetest2.c
===================================================================
--- GNUnet/src/applications/sqstore_sqlite/sqlitetest2.c        2007-07-22 
07:20:56 UTC (rev 5336)
+++ GNUnet/src/applications/sqstore_sqlite/sqlitetest2.c        2007-07-22 
07:52:00 UTC (rev 5337)
@@ -113,7 +113,7 @@
  * permission to the respective directory in order
  * to obtain all of the performance information.
  */
-#define DB_NAME "/var/lib/mysql"
+#define DB_NAME "/tmp/gnunet-sqlite-sqstore-test/data/fs/"
 
 static unsigned long long stored_bytes;
 

Modified: GNUnet/src/applications/sqstore_sqlite/sqlitetest3.c
===================================================================
--- GNUnet/src/applications/sqstore_sqlite/sqlitetest3.c        2007-07-22 
07:20:56 UTC (rev 5336)
+++ GNUnet/src/applications/sqstore_sqlite/sqlitetest3.c        2007-07-22 
07:52:00 UTC (rev 5337)
@@ -40,7 +40,7 @@
  */
 #define MAX_SIZE 1024LL * 1024 * 128
 
-#define ITERATIONS 1
+#define ITERATIONS 10
 
 /**
  * Number of put operations equivalent to 1/10th of MAX_SIZE





reply via email to

[Prev in Thread] Current Thread [Next in Thread]