Dan Kenigsberg has posted comments on this change. Change subject: Use buffer size in multiplies of the recommended transfer size ......................................................................
Patch Set 1: I would prefer that you didn't submit this (2 inline comments) the suggestion makes sense, but .................................................... Commit Message Line 5: CommitDate: 2012-10-04 13:14:24 +0200 Line 6: Line 7: Use buffer size in multiplies of the recommended transfer size Line 8: Line 9: This seems to fix the issue but I'm not sure if it's the best possible I'm guessing "the issue" is https://bugzilla.redhat.com/show_bug.cgi?id=845660 please not it clearly. Line 10: solution. Might help get things rolling until we get this nailed down. Line 11: Line 12: Change-Id: Iadea310039b30073197b7ad90afb930c460bda17 .................................................... File vdsm/storage/fileUtils.py Line 298: # Because we usually have fixed sizes for our reads, caching Line 299: # buffers might give a slight performance boost. Line 300: alignment = libc.fpathconf(self.fileno(), _PC_REC_XFER_ALIGN) Line 301: minXferSize = libc.fpathconf(self.fileno(), _PC_REC_MIN_XFER_SIZE) Line 302: size = int(math.ceil(size / float(minXferSize))) * minXferSize why contaminate our code with "math" approximation, when all you need is to use def ceildiv(m, n): return (m + 1) // n Line 303: rc = libc.posix_memalign(ppbuff, alignment, size) Line 304: if rc: Line 305: raise OSError(rc, "Could not allocate aligned buffer") Line 306: try: -- To view, visit http://gerrit.ovirt.org/8356 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iadea310039b30073197b7ad90afb930c460bda17 Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Saggi Mizrahi <[email protected]> Gerrit-Reviewer: Ayal Baron <[email protected]> Gerrit-Reviewer: Barak Azulay <[email protected]> Gerrit-Reviewer: Dan Kenigsberg <[email protected]> Gerrit-Reviewer: Federico Simoncelli <[email protected]> Gerrit-Reviewer: Yaniv Bronhaim <[email protected]> _______________________________________________ vdsm-patches mailing list [email protected] https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
