Changeset: d495ac24535e for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=d495ac24535e
Modified Files:
clients/Tests/exports.stable.out
monetdb5/modules/kernel/aggr.c
monetdb5/modules/kernel/aggr.mal
monetdb5/modules/kernel/aggr.mal.sh
monetdb5/optimizer/Tests/tst4800.stable.out
Branch: int128
Log Message:
added int128 / "hge" support in monetdb5/modules/kernel/aggr.*
diffs (truncated from 596 to 300 lines):
diff --git a/clients/Tests/exports.stable.out b/clients/Tests/exports.stable.out
--- a/clients/Tests/exports.stable.out
+++ b/clients/Tests/exports.stable.out
@@ -635,6 +635,7 @@ str AGGRmin3(bat *retval, bat *bid, bat
str AGGRprod2_bte(bat *retval, bat *bid, bat *eid);
str AGGRprod2_dbl(bat *retval, bat *bid, bat *eid);
str AGGRprod2_flt(bat *retval, bat *bid, bat *eid);
+str AGGRprod2_hge(bat *retval, bat *bid, bat *eid);
str AGGRprod2_int(bat *retval, bat *bid, bat *eid);
str AGGRprod2_lng(bat *retval, bat *bid, bat *eid);
str AGGRprod2_sht(bat *retval, bat *bid, bat *eid);
@@ -642,6 +643,7 @@ str AGGRprod2_wrd(bat *retval, bat *bid,
str AGGRprod3_bte(bat *retval, bat *bid, bat *gid, bat *eid);
str AGGRprod3_dbl(bat *retval, bat *bid, bat *gid, bat *eid);
str AGGRprod3_flt(bat *retval, bat *bid, bat *gid, bat *eid);
+str AGGRprod3_hge(bat *retval, bat *bid, bat *gid, bat *eid);
str AGGRprod3_int(bat *retval, bat *bid, bat *gid, bat *eid);
str AGGRprod3_lng(bat *retval, bat *bid, bat *gid, bat *eid);
str AGGRprod3_sht(bat *retval, bat *bid, bat *gid, bat *eid);
@@ -670,6 +672,7 @@ str AGGRsubmincand_val(bat *retval, bat
str AGGRsubprod_bte(bat *retval, bat *bid, bat *gid, bat *eid, bit *skip_nils,
bit *abort_on_error);
str AGGRsubprod_dbl(bat *retval, bat *bid, bat *gid, bat *eid, bit *skip_nils,
bit *abort_on_error);
str AGGRsubprod_flt(bat *retval, bat *bid, bat *gid, bat *eid, bit *skip_nils,
bit *abort_on_error);
+str AGGRsubprod_hge(bat *retval, bat *bid, bat *gid, bat *eid, bit *skip_nils,
bit *abort_on_error);
str AGGRsubprod_int(bat *retval, bat *bid, bat *gid, bat *eid, bit *skip_nils,
bit *abort_on_error);
str AGGRsubprod_lng(bat *retval, bat *bid, bat *gid, bat *eid, bit *skip_nils,
bit *abort_on_error);
str AGGRsubprod_sht(bat *retval, bat *bid, bat *gid, bat *eid, bit *skip_nils,
bit *abort_on_error);
@@ -677,6 +680,7 @@ str AGGRsubprod_wrd(bat *retval, bat *bi
str AGGRsubprodcand_bte(bat *retval, bat *bid, bat *gid, bat *eid, bat *sid,
bit *skip_nils, bit *abort_on_error);
str AGGRsubprodcand_dbl(bat *retval, bat *bid, bat *gid, bat *eid, bat *sid,
bit *skip_nils, bit *abort_on_error);
str AGGRsubprodcand_flt(bat *retval, bat *bid, bat *gid, bat *eid, bat *sid,
bit *skip_nils, bit *abort_on_error);
+str AGGRsubprodcand_hge(bat *retval, bat *bid, bat *gid, bat *eid, bat *sid,
bit *skip_nils, bit *abort_on_error);
str AGGRsubprodcand_int(bat *retval, bat *bid, bat *gid, bat *eid, bat *sid,
bit *skip_nils, bit *abort_on_error);
str AGGRsubprodcand_lng(bat *retval, bat *bid, bat *gid, bat *eid, bat *sid,
bit *skip_nils, bit *abort_on_error);
str AGGRsubprodcand_sht(bat *retval, bat *bid, bat *gid, bat *eid, bat *sid,
bit *skip_nils, bit *abort_on_error);
@@ -688,6 +692,7 @@ str AGGRsubstdevpcand_dbl(bat *retval, b
str AGGRsubsum_bte(bat *retval, bat *bid, bat *gid, bat *eid, bit *skip_nils,
bit *abort_on_error);
str AGGRsubsum_dbl(bat *retval, bat *bid, bat *gid, bat *eid, bit *skip_nils,
bit *abort_on_error);
str AGGRsubsum_flt(bat *retval, bat *bid, bat *gid, bat *eid, bit *skip_nils,
bit *abort_on_error);
+str AGGRsubsum_hge(bat *retval, bat *bid, bat *gid, bat *eid, bit *skip_nils,
bit *abort_on_error);
str AGGRsubsum_int(bat *retval, bat *bid, bat *gid, bat *eid, bit *skip_nils,
bit *abort_on_error);
str AGGRsubsum_lng(bat *retval, bat *bid, bat *gid, bat *eid, bit *skip_nils,
bit *abort_on_error);
str AGGRsubsum_sht(bat *retval, bat *bid, bat *gid, bat *eid, bit *skip_nils,
bit *abort_on_error);
@@ -695,6 +700,7 @@ str AGGRsubsum_wrd(bat *retval, bat *bid
str AGGRsubsumcand_bte(bat *retval, bat *bid, bat *gid, bat *eid, bat *sid,
bit *skip_nils, bit *abort_on_error);
str AGGRsubsumcand_dbl(bat *retval, bat *bid, bat *gid, bat *eid, bat *sid,
bit *skip_nils, bit *abort_on_error);
str AGGRsubsumcand_flt(bat *retval, bat *bid, bat *gid, bat *eid, bat *sid,
bit *skip_nils, bit *abort_on_error);
+str AGGRsubsumcand_hge(bat *retval, bat *bid, bat *gid, bat *eid, bat *sid,
bit *skip_nils, bit *abort_on_error);
str AGGRsubsumcand_int(bat *retval, bat *bid, bat *gid, bat *eid, bat *sid,
bit *skip_nils, bit *abort_on_error);
str AGGRsubsumcand_lng(bat *retval, bat *bid, bat *gid, bat *eid, bat *sid,
bit *skip_nils, bit *abort_on_error);
str AGGRsubsumcand_sht(bat *retval, bat *bid, bat *gid, bat *eid, bat *sid,
bit *skip_nils, bit *abort_on_error);
@@ -708,6 +714,7 @@ str AGGRsubxmlcand(bat *retval, bat *bid
str AGGRsum2_bte(bat *retval, bat *bid, bat *eid);
str AGGRsum2_dbl(bat *retval, bat *bid, bat *eid);
str AGGRsum2_flt(bat *retval, bat *bid, bat *eid);
+str AGGRsum2_hge(bat *retval, bat *bid, bat *eid);
str AGGRsum2_int(bat *retval, bat *bid, bat *eid);
str AGGRsum2_lng(bat *retval, bat *bid, bat *eid);
str AGGRsum2_sht(bat *retval, bat *bid, bat *eid);
@@ -715,6 +722,7 @@ str AGGRsum2_wrd(bat *retval, bat *bid,
str AGGRsum3_bte(bat *retval, bat *bid, bat *gid, bat *eid);
str AGGRsum3_dbl(bat *retval, bat *bid, bat *gid, bat *eid);
str AGGRsum3_flt(bat *retval, bat *bid, bat *gid, bat *eid);
+str AGGRsum3_hge(bat *retval, bat *bid, bat *gid, bat *eid);
str AGGRsum3_int(bat *retval, bat *bid, bat *gid, bat *eid);
str AGGRsum3_lng(bat *retval, bat *bid, bat *gid, bat *eid);
str AGGRsum3_sht(bat *retval, bat *bid, bat *gid, bat *eid);
diff --git a/monetdb5/modules/kernel/aggr.c b/monetdb5/modules/kernel/aggr.c
--- a/monetdb5/modules/kernel/aggr.c
+++ b/monetdb5/modules/kernel/aggr.c
@@ -240,6 +240,16 @@ AGGRsum3_lng(bat *retval, bat *bid, bat
BATgroupsum, NULL, 1,
"aggr.sum");
}
+#ifdef HAVE_HGE
+aggr_export str AGGRsum3_hge(bat *retval, bat *bid, bat *gid, bat *eid);
+str
+AGGRsum3_hge(bat *retval, bat *bid, bat *gid, bat *eid)
+{
+ return AGGRgrouped3(retval, NULL, bid, gid, eid, TYPE_hge,
+ BATgroupsum, NULL, 1,
"aggr.sum");
+}
+#endif
+
aggr_export str AGGRsum3_flt(bat *retval, bat *bid, bat *gid, bat *eid);
str
AGGRsum3_flt(bat *retval, bat *bid, bat *gid, bat *eid)
@@ -291,6 +301,15 @@ AGGRsum2_lng(bat *retval, bat *bid, bat
return AGGRgrouped2(retval, NULL, bid, eid, TYPE_lng, BATgroupsum,
NULL, 1, "aggr.sum");
}
+#ifdef HAVE_HGE
+aggr_export str AGGRsum2_hge(bat *retval, bat *bid, bat *eid);
+str
+AGGRsum2_hge(bat *retval, bat *bid, bat *eid)
+{
+ return AGGRgrouped2(retval, NULL, bid, eid, TYPE_hge, BATgroupsum,
NULL, 1, "aggr.sum");
+}
+#endif
+
aggr_export str AGGRsum2_flt(bat *retval, bat *bid, bat *eid);
str
AGGRsum2_flt(bat *retval, bat *bid, bat *eid)
@@ -345,6 +364,16 @@ AGGRprod3_lng(bat *retval, bat *bid, bat
BATgroupprod, NULL, 1,
"aggr.prod");
}
+#ifdef HAVE_HGE
+aggr_export str AGGRprod3_hge(bat *retval, bat *bid, bat *gid, bat *eid);
+str
+AGGRprod3_hge(bat *retval, bat *bid, bat *gid, bat *eid)
+{
+ return AGGRgrouped3(retval, NULL, bid, gid, eid, TYPE_hge,
+ BATgroupprod, NULL, 1,
"aggr.prod");
+}
+#endif
+
aggr_export str AGGRprod3_flt(bat *retval, bat *bid, bat *gid, bat *eid);
str
AGGRprod3_flt(bat *retval, bat *bid, bat *gid, bat *eid)
@@ -396,6 +425,15 @@ AGGRprod2_lng(bat *retval, bat *bid, bat
return AGGRgrouped2(retval, NULL, bid, eid, TYPE_lng, BATgroupprod,
NULL, 1, "aggr.prod");
}
+#ifdef HAVE_HGE
+aggr_export str AGGRprod2_hge(bat *retval, bat *bid, bat *eid);
+str
+AGGRprod2_hge(bat *retval, bat *bid, bat *eid)
+{
+ return AGGRgrouped2(retval, NULL, bid, eid, TYPE_hge, BATgroupprod,
NULL, 1, "aggr.prod");
+}
+#endif
+
aggr_export str AGGRprod2_flt(bat *retval, bat *bid, bat *eid);
str
AGGRprod2_flt(bat *retval, bat *bid, bat *eid)
@@ -724,6 +762,16 @@ AGGRsubsum_lng(bat *retval, bat *bid, ba
*abort_on_error, TYPE_lng,
BATgroupsum, NULL, "aggr.subsum");
}
+#ifdef HAVE_HGE
+aggr_export str AGGRsubsum_hge(bat *retval, bat *bid, bat *gid, bat *eid, bit
*skip_nils, bit *abort_on_error);
+str
+AGGRsubsum_hge(bat *retval, bat *bid, bat *gid, bat *eid, bit *skip_nils, bit
*abort_on_error)
+{
+ return AGGRsubgrouped(retval, NULL, bid, gid, eid, NULL, *skip_nils,
+ *abort_on_error, TYPE_hge,
BATgroupsum, NULL, "aggr.subsum");
+}
+#endif
+
aggr_export str AGGRsubsum_flt(bat *retval, bat *bid, bat *gid, bat *eid, bit
*skip_nils, bit *abort_on_error);
str
AGGRsubsum_flt(bat *retval, bat *bid, bat *gid, bat *eid, bit *skip_nils, bit
*abort_on_error)
@@ -780,6 +828,16 @@ AGGRsubsumcand_lng(bat *retval, bat *bid
*abort_on_error, TYPE_lng,
BATgroupsum, NULL, "aggr.subsum");
}
+#ifdef HAVE_HGE
+aggr_export str AGGRsubsumcand_hge(bat *retval, bat *bid, bat *gid, bat *eid,
bat *sid, bit *skip_nils, bit *abort_on_error);
+str
+AGGRsubsumcand_hge(bat *retval, bat *bid, bat *gid, bat *eid, bat *sid, bit
*skip_nils, bit *abort_on_error)
+{
+ return AGGRsubgrouped(retval, NULL, bid, gid, eid, sid, *skip_nils,
+ *abort_on_error, TYPE_hge,
BATgroupsum, NULL, "aggr.subsum");
+}
+#endif
+
aggr_export str AGGRsubsumcand_flt(bat *retval, bat *bid, bat *gid, bat *eid,
bat *sid, bit *skip_nils, bit *abort_on_error);
str
AGGRsubsumcand_flt(bat *retval, bat *bid, bat *gid, bat *eid, bat *sid, bit
*skip_nils, bit *abort_on_error)
@@ -836,6 +894,16 @@ AGGRsubprod_lng(bat *retval, bat *bid, b
*abort_on_error, TYPE_lng,
BATgroupprod, NULL, "aggr.subprod");
}
+#ifdef HAVE_HGE
+aggr_export str AGGRsubprod_hge(bat *retval, bat *bid, bat *gid, bat *eid, bit
*skip_nils, bit *abort_on_error);
+str
+AGGRsubprod_hge(bat *retval, bat *bid, bat *gid, bat *eid, bit *skip_nils, bit
*abort_on_error)
+{
+ return AGGRsubgrouped(retval, NULL, bid, gid, eid, NULL, *skip_nils,
+ *abort_on_error, TYPE_hge,
BATgroupprod, NULL, "aggr.subprod");
+}
+#endif
+
aggr_export str AGGRsubprod_flt(bat *retval, bat *bid, bat *gid, bat *eid, bit
*skip_nils, bit *abort_on_error);
str
AGGRsubprod_flt(bat *retval, bat *bid, bat *gid, bat *eid, bit *skip_nils, bit
*abort_on_error)
@@ -892,6 +960,16 @@ AGGRsubprodcand_lng(bat *retval, bat *bi
*abort_on_error, TYPE_lng,
BATgroupprod, NULL, "aggr.subprod");
}
+#ifdef HAVE_HGE
+aggr_export str AGGRsubprodcand_hge(bat *retval, bat *bid, bat *gid, bat *eid,
bat *sid, bit *skip_nils, bit *abort_on_error);
+str
+AGGRsubprodcand_hge(bat *retval, bat *bid, bat *gid, bat *eid, bat *sid, bit
*skip_nils, bit *abort_on_error)
+{
+ return AGGRsubgrouped(retval, NULL, bid, gid, eid, sid, *skip_nils,
+ *abort_on_error, TYPE_hge,
BATgroupprod, NULL, "aggr.subprod");
+}
+#endif
+
aggr_export str AGGRsubprodcand_flt(bat *retval, bat *bid, bat *gid, bat *eid,
bat *sid, bit *skip_nils, bit *abort_on_error);
str
AGGRsubprodcand_flt(bat *retval, bat *bid, bat *gid, bat *eid, bat *sid, bit
*skip_nils, bit *abort_on_error)
diff --git a/monetdb5/modules/kernel/aggr.mal b/monetdb5/modules/kernel/aggr.mal
--- a/monetdb5/modules/kernel/aggr.mal
+++ b/monetdb5/modules/kernel/aggr.mal
@@ -198,6 +198,40 @@ command subprod(b:bat[:oid,:bte],g:bat[:
address AGGRsubprodcand_lng
comment "Grouped product aggregate with candidates list";
+command sum(b:bat[:oid,:bte], e:bat[:oid,:any_1]) :bat[:oid,:hge]
+address AGGRsum2_hge
+comment "Sum over grouped tail sum on bte";
+
+command sum(b:bat[:oid,:bte],g:bat[:oid,:oid],e:bat[:oid,:any_1])
+ :bat[:oid,:hge]
+address AGGRsum3_hge
+comment "Grouped tail sum on bte";
+
+command
subsum(b:bat[:oid,:bte],g:bat[:oid,:oid],e:bat[:oid,:any_1],skip_nils:bit,abort_on_error:bit)
:bat[:oid,:hge]
+address AGGRsubsum_hge
+comment "Grouped sum aggregate";
+
+command
subsum(b:bat[:oid,:bte],g:bat[:oid,:oid],e:bat[:oid,:any_1],s:bat[:oid,:oid],skip_nils:bit,abort_on_error:bit)
:bat[:oid,:hge]
+address AGGRsubsumcand_hge
+comment "Grouped sum aggregate with candidates list";
+
+command prod(b:bat[:oid,:bte], e:bat[:oid,:any_1]) :bat[:oid,:hge]
+address AGGRprod2_hge
+comment "Product over grouped tail product on bte";
+
+command prod(b:bat[:oid,:bte],g:bat[:oid,:oid],e:bat[:oid,:any_1])
+ :bat[:oid,:hge]
+address AGGRprod3_hge
+comment "Grouped tail product on bte";
+
+command
subprod(b:bat[:oid,:bte],g:bat[:oid,:oid],e:bat[:oid,:any_1],skip_nils:bit,abort_on_error:bit)
:bat[:oid,:hge]
+address AGGRsubprod_hge
+comment "Grouped product aggregate";
+
+command
subprod(b:bat[:oid,:bte],g:bat[:oid,:oid],e:bat[:oid,:any_1],s:bat[:oid,:oid],skip_nils:bit,abort_on_error:bit)
:bat[:oid,:hge]
+address AGGRsubprodcand_hge
+comment "Grouped product aggregate with candidates list";
+
command sum(b:bat[:oid,:sht], e:bat[:oid,:any_1]) :bat[:oid,:dbl]
address AGGRsum2_dbl
comment "Sum over grouped tail sum on sht";
@@ -343,6 +377,40 @@ command subprod(b:bat[:oid,:sht],g:bat[:
address AGGRsubprodcand_lng
comment "Grouped product aggregate with candidates list";
+command sum(b:bat[:oid,:sht], e:bat[:oid,:any_1]) :bat[:oid,:hge]
+address AGGRsum2_hge
+comment "Sum over grouped tail sum on sht";
+
+command sum(b:bat[:oid,:sht],g:bat[:oid,:oid],e:bat[:oid,:any_1])
+ :bat[:oid,:hge]
+address AGGRsum3_hge
+comment "Grouped tail sum on sht";
+
+command
subsum(b:bat[:oid,:sht],g:bat[:oid,:oid],e:bat[:oid,:any_1],skip_nils:bit,abort_on_error:bit)
:bat[:oid,:hge]
+address AGGRsubsum_hge
+comment "Grouped sum aggregate";
+
+command
subsum(b:bat[:oid,:sht],g:bat[:oid,:oid],e:bat[:oid,:any_1],s:bat[:oid,:oid],skip_nils:bit,abort_on_error:bit)
:bat[:oid,:hge]
+address AGGRsubsumcand_hge
+comment "Grouped sum aggregate with candidates list";
+
+command prod(b:bat[:oid,:sht], e:bat[:oid,:any_1]) :bat[:oid,:hge]
+address AGGRprod2_hge
+comment "Product over grouped tail product on sht";
+
+command prod(b:bat[:oid,:sht],g:bat[:oid,:oid],e:bat[:oid,:any_1])
+ :bat[:oid,:hge]
+address AGGRprod3_hge
+comment "Grouped tail product on sht";
+
+command
subprod(b:bat[:oid,:sht],g:bat[:oid,:oid],e:bat[:oid,:any_1],skip_nils:bit,abort_on_error:bit)
:bat[:oid,:hge]
+address AGGRsubprod_hge
+comment "Grouped product aggregate";
+
+command
subprod(b:bat[:oid,:sht],g:bat[:oid,:oid],e:bat[:oid,:any_1],s:bat[:oid,:oid],skip_nils:bit,abort_on_error:bit)
:bat[:oid,:hge]
+address AGGRsubprodcand_hge
+comment "Grouped product aggregate with candidates list";
+
command sum(b:bat[:oid,:int], e:bat[:oid,:any_1]) :bat[:oid,:dbl]
address AGGRsum2_dbl
comment "Sum over grouped tail sum on int";
@@ -454,6 +522,40 @@ command subprod(b:bat[:oid,:int],g:bat[:
address AGGRsubprodcand_lng
comment "Grouped product aggregate with candidates list";
+command sum(b:bat[:oid,:int], e:bat[:oid,:any_1]) :bat[:oid,:hge]
+address AGGRsum2_hge
+comment "Sum over grouped tail sum on int";
+
+command sum(b:bat[:oid,:int],g:bat[:oid,:oid],e:bat[:oid,:any_1])
+ :bat[:oid,:hge]
+address AGGRsum3_hge
_______________________________________________
checkin-list mailing list
[email protected]
http://mail.monetdb.org/mailman/listinfo/checkin-list