I've done some additional testing, and these are the results: For the xray query, the largest that we have in the testsuite, compilation time with --compile-only is pretty much the same with and without the dataguide computaiton, at around ~0.08 sec.
With a specially constructed query that looks like this: (see dataguide-29.jq test) let $col := dml:collection() let $col2 := ($col.cat1, $col.cat2, ... , $col.cat10) return $col2.category.category.category ... category (repeated ~2000 times) the compilation time goes from ~0.7s without the dataguide to ~10s with the dataguide enabled, so it is significant. But this is a worst-case scenario. The resulting dataguide is an object 2000-levels deep. The compilation can be improved significantly by: - keeping track of the "leaves" nodes in the dataguide tree - rewriting a bit the dataguide structure to store the trees incrementally instead of cloning them - adding a depth cutoff What do you think? -- https://code.launchpad.net/~zorba-coders/zorba/dataguide/+merge/173026 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp