Add debug log for aligned cache write

pull/46/head
Tatsuhiro Tsujikawa 2013-02-02 21:28:52 +09:00
parent 13975f66a2
commit 85cd65a664
1 changed files with 2 additions and 0 deletions

View File

@ -105,6 +105,8 @@ void AbstractSingleDiskAdaptor::writeCache(const WrDiskCacheEntry* entry)
}
if(buflen == 0 && ((*i)->goff & 0xfff) == 0 && ((*i)->len & 0xfff) == 0) {
// Already aligned. Write it without copy.
A2_LOG_DEBUG(fmt("Cache flush goff=%"PRId64", len=%lu",
start, static_cast<unsigned long>((*i)->len)));
writeData((*i)->data + (*i)->offset, (*i)->len, start);
start += (*i)->len;
} else {