Changeset: 4b9b18668f76 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB/rev/4b9b18668f76
Modified Files:
monetdb5/optimizer/opt_mitosis.c
Branch: Dec2025
Log Message:
Added options min_mito_rows and max_mito_parts.
These options help keep the mitosis optimizer in check. When there are
many threads available, the mitosis optimizer may split a bat in too
many pieces which may then cause a plan explosion.
diffs (16 lines):
diff --git a/monetdb5/optimizer/opt_mitosis.c b/monetdb5/optimizer/opt_mitosis.c
--- a/monetdb5/optimizer/opt_mitosis.c
+++ b/monetdb5/optimizer/opt_mitosis.c
@@ -217,6 +217,12 @@ OPTmitosisImplementation(Client cntxt, M
mito_size = GDKgetenv_int("mito_size", 0);
if (mito_size > 0)
pieces = (int) ((rowcnt * row_size) / (mito_size * 1024));
+ mito_size = GDKgetenv_int("min_mito_rows", 0);
+ if (mito_size > 0 && pieces > 1 && rowcnt / pieces < (BUN) mito_size)
+ pieces = rowcnt / mito_size;
+ mito_parts = GDKgetenv_int("max_mito_parts", 0);
+ if (mito_parts > 0 && pieces > mito_parts)
+ pieces = mito_parts;
if (pieces <= 1) {
pieces = 0;
_______________________________________________
checkin-list mailing list -- [email protected]
To unsubscribe send an email to [email protected]