Fixed compiler warnings

This commit is contained in:
Sears Russell 2008-03-08 07:36:47 +00:00
parent 567c2b51b9
commit e8490c8b8a
3 changed files with 11 additions and 9 deletions

View file

@ -5,6 +5,7 @@
#include "stasis/transactional.h"
#include "stasis/page/compression/nop.h"
#include "stasis/page/compression/multicolumn-impl.h"
#include "stasis/page/compression/staticMulticolumn.h"
#include "stasis/page/compression/for-impl.h"
@ -62,7 +63,7 @@ namespace rose {
typename PAGELAYOUT::FMT::TUP t;
typename PAGELAYOUT::FMT::TUP s;
long INSERTS;
long INSERTS = 0;
int file_mode = 0;
char * file = 0;
if(argc == 2) {
@ -119,7 +120,7 @@ namespace rose {
gettimeofday(&cannonical_start_tv,0);
double cannonical_start = tv_to_double(cannonical_start_tv);
while(-1 != (read_len = getline(&line, &line_len, input))) {
while(-1 != (int)(read_len = getline(&line, &line_len, input))) {
int line_tok_count;
{
char * saveptr;

View file

@ -53,7 +53,8 @@ class treeIterator {
p_ = 0;
} else {
pageid_t * pid_tmp;
lsmTreeIterator_value(-1,lsmIterator_,(byte**)&pid_tmp);
pageid_t ** hack = &pid_tmp;
lsmTreeIterator_value(-1,lsmIterator_,(byte**)hack);
pageid_ = *pid_tmp;
p_ = loadPage(-1,pageid_);
currentPage_ = (PAGELAYOUT*)p_->impl;
@ -132,8 +133,8 @@ class treeIterator {
pageid_t *pid_tmp;
slot_ = 0;
lsmTreeIterator_value(-1,lsmIterator_,(byte**)&pid_tmp);
pageid_t **hack = &pid_tmp;
lsmTreeIterator_value(-1,lsmIterator_,(byte**)hack);
pageid_ = *pid_tmp;
p_ = loadPage(-1,pageid_);

View file

@ -241,7 +241,7 @@ namespace rose {
/ (1024.0 * 1024.0 * total_elapsed);
printf("worker %d merge # %-6d: comp ratio: %-9.3f stalled %6.1f sec backpressure %6.1f "
"worked %6.1f sec inserts %-12ld (%9.3f mb/s) %6ld pages (need %6ld)\n", a->worker_id, merge_count, ratio,
"worked %6.1f sec inserts %-12ld (%9.3f mb/s) %6lld pages (need %6lld)\n", a->worker_id, merge_count, ratio,
wait_elapsed, push_elapsed, work_elapsed,(unsigned long)insertedTuples, throughput, mergedPages, !a->out_tree_size ? -1 : (FUDGE * *a->out_tree_size / a->r_i));
@ -609,10 +609,10 @@ namespace rose {
pthread_mutex_unlock(h->mut);
if(first) {
printf("flush waited %lf sec\n", stop-start);
printf("flush waited %f sec\n", stop-start);
first = 0;
} else {
printf("flush waited %lf sec (worked %lf)\n",
printf("flush waited %f sec (worked %f)\n",
stop-start, start-last_start);
}
last_start = stop;
@ -655,7 +655,7 @@ namespace rose {
handleBytes > inputSizeThresh ||
#endif
handleBytes > memSizeThresh) { // XXX ok?
printf("Handle mbytes %ld (%ld) Input size: %ld input size thresh: %ld mbytes mem size thresh: %ld\n",
printf("Handle mbytes %ld (%ld) Input size: %lld input size thresh: %ld mbytes mem size thresh: %ld\n",
handleBytes / (1024*1024), h->scratch_handle->size(), *h->input_size, inputSizeThresh / (1024*1024), memSizeThresh / (1024*1024));
TlsmTableFlush<PAGELAYOUT>(h);
}