[gnumeric] xlsx: improve performance.



commit 8a616ac48d552945223bd9ece6fe205b78376af5
Author: Morten Welinder <terra gnome org>
Date:   Tue Oct 9 08:54:07 2012 -0400

    xlsx: improve performance.
    
    Swapping two lines so the cheaper MIN comes first helps.  (The now-last
    is a MIN too.  It just doesn't look like it.)

 plugins/excel/xlsx-write.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/plugins/excel/xlsx-write.c b/plugins/excel/xlsx-write.c
index 9af286f..08d6916 100644
--- a/plugins/excel/xlsx-write.c
+++ b/plugins/excel/xlsx-write.c
@@ -1268,8 +1268,8 @@ xlsx_write_cells (XLSXWriteState *state, GsfXMLOut *xml,
 		if (needs_row) {
 			GnmCell *cell = g_ptr_array_index (all_cells, cno);
 			int rows = (cell ? cell->pos.row : extent->end.row) - r;
-			rows = count_default_rows (sheet, col_styles, r, rows);
 			rows = MIN (rows, boring_count[r]);
+			rows = count_default_rows (sheet, col_styles, r, rows);
 			if (rows > 0) {
 				r += (rows - 1);
 				continue;



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]