Severe compiler perf problem
Added by Anonymous about 20 years ago
Legacy ID: #2860485 Legacy Poster: Francis Upton (francisu)
This started happening when I upgraded to b8.1.1. I have been compiling the same (several hundred line) XQuery programs in previous versions with no problems. With the new version the time to compile a query has grown from a few second to tens of minutes. I tracked down the problem to this code: public int allocateLocationId(String module, int lineNumber) { if (module == null) { // the module has no base URI module = "module-" + numberOfModules + " (no base URI)"; } int mod = -1; for (int m=numberOfModules-1; m>=0; m--) { if (modules[m].equals(module)) { mod = m; } } In my case, I don't specify a base-URI, so it appears to be generating 10s of thousands of modules (I interrupted the code at module number 24K), and then doing a linear search for those. I will work around this by specifying a systemId in the environment, but this probably should be fixed for the next unsuspecting person. Thanks, Francis
Replies (2)
RE: Severe compiler perf problem - Added by Anonymous about 20 years ago
Legacy ID: #2860632 Legacy Poster: Michael Kay (mhkay)
Thanks for reporting this, will fix. Michael Kay
RE: Severe compiler perf problem - Added by Anonymous about 20 years ago
Legacy ID: #2860994 Legacy Poster: Michael Kay (mhkay)
Now fixed. I will in future use the same module ID whenever the systemId of the module is unknown. Michael Kay
Please register to reply