@@ -0,0 +1,1006 @@
+from __future__ import absolute_import%0A%0Aimport csv%0Aimport operator%0A%0A%0Aclass CSVResults(object):%0A    def __init__(self, columns, sort):%0A        self.columns = columns%0A        self.sort = sort%0A%0A    def render(self, stream, groups):%0A        writer = csv.writer(stream)%0A        params = sorted(set(%0A            param%0A            for group, benchmarks in groups%0A            for benchmark in benchmarks%0A            for param in benchmark%5B%22params%22%5D%0A        ))%0A        writer.writerow(%5B%0A            %22name%22,%0A        %5D + %5B%0A            %22param:%7B0%7D%22.format(p)%0A            for p in params%0A        %5D + self.columns)%0A%0A        for group, benchmarks in groups:%0A            benchmarks = sorted(benchmarks, key=operator.itemgetter(self.sort))%0A%0A            for bench in benchmarks:%0A                row = %5Bbench.get(%22fullfunc%22, bench%5B%22fullname%22%5D)%5D%0A                row.extend(bench%5B'params'%5D.get(param, %22%22) for param in params)%0A                row.extend(bench%5Bprop%5D for prop in self.columns)%0A                writer.writerow(row)%0A

Add a csv writer.