1
0
mirror of https://github.com/MariaDB/server.git synced 2025-11-30 05:23:50 +03:00

All the makefiles should honor {{{PROF_FLAGS}}}. Make db-benchmark-test statically linkable by removing the conflict with {{{toku_fill_dbt}}}. Although gprof still doesn't work with dynamically linked libraries, we can statically link it and get useful info. Closes #515.

git-svn-id: file:///svn/tokudb@2755 c7de825b-a66e-492c-adef-691d508d4ae1
This commit is contained in:
Bradley C. Kuszmaul
2008-03-12 08:30:49 +00:00
parent 7c4eabe86f
commit 4ea09248a3
5 changed files with 8 additions and 7 deletions

View File

@@ -121,7 +121,7 @@ void long_long_to_array (unsigned char *a, unsigned long long l) {
a[i] = (l>>(56-8*i))&0xff;
}
DBT *toku_fill_dbt(DBT *dbt, const void *data, int size) {
DBT *fill_dbt(DBT *dbt, const void *data, int size) {
memset(dbt, 0, sizeof *dbt);
dbt->size = size;
dbt->data = (void *) data;
@@ -135,7 +135,7 @@ void insert (long long v) {
long_long_to_array(kc, v);
memset(vc, 0, sizeof vc);
long_long_to_array(vc, v);
int r = db->put(db, tid, toku_fill_dbt(&kt, kc, keysize), toku_fill_dbt(&vt, vc, valsize), DB_YESOVERWRITE);
int r = db->put(db, tid, fill_dbt(&kt, kc, keysize), fill_dbt(&vt, vc, valsize), DB_YESOVERWRITE);
CKERR(r);
if (do_transactions) {
if (n_insertions_since_txn_began>=items_per_transaction) {
@@ -154,7 +154,7 @@ void serial_insert_from (long long from) {
int r = dbenv->txn_begin(dbenv, 0, &tid, 0); assert(r==0);
{
DBT k,v;
r=db->put(db, tid, toku_fill_dbt(&k, "a", 1), toku_fill_dbt(&v, "b", 1), DB_YESOVERWRITE);
r=db->put(db, tid, fill_dbt(&k, "a", 1), fill_dbt(&v, "b", 1), DB_YESOVERWRITE);
CKERR(r);
}