Changeset: d4d111f7624c for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB/rev/d4d111f7624c
Modified Files:
gdk/gdk_select.c
Branch: default
Log Message:
Don't check orderedness if we don't actually need the information.
diffs (20 lines):
diff --git a/gdk/gdk_select.c b/gdk/gdk_select.c
--- a/gdk/gdk_select.c
+++ b/gdk/gdk_select.c
@@ -1342,9 +1342,13 @@ BATselect(BAT *b, BAT *s, const void *tl
hash = phash = true;
}
- /* make sure tsorted and trevsorted flags are set */
- (void) BATordered(b);
- (void) BATordered_rev(b);
+ if (hash && (phash || b->thash)) {
+ /* make sure tsorted and trevsorted flags are set, but
+ * we only need to know if we're not yet sure that we're
+ * going for the hash (i.e. it already exists) */
+ (void) BATordered(b);
+ (void) BATordered_rev(b);
+ }
/* If there is an order index or it is a view and the parent
* has an ordered index, and the bat is not tsorted or
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list