Slow dhtmlx function check()?

Loading a large number of appointments (around 800-1400) is slow. I profiled it, and the slowest function seems to be check, taking about 531ms. Can somebody give me some insight into what this function is doing, and maybe some strategies to stop it from being such a bottleneck? Currently rendering is much slower than the server-side database query and data transfer.
Thanks,
Matt

dtmlXMLLoaderObject.prototype.waitLoadFunction=function(dhtmlObject){
    var once = true;
    this.check=function (){
        if ((dhtmlObject)&&(dhtmlObject.onloadAction)){
            if ((!dhtmlObject.xmlDoc.readyState)||(dhtmlObject.xmlDoc.readyState == 4)){
                if (!once)
                    return;

                once=false; //IE 5 fix
                dtmlXMLLoaderObject.count++;
                if (typeof dhtmlObject.onloadAction == "function")
                    dhtmlObject.onloadAction(dhtmlObject.mainObject, null, null, null, dhtmlObject);

                if (dhtmlObject.waitCall){
                    dhtmlObject.waitCall.call(this,dhtmlObject);
                    dhtmlObject.waitCall=null;
                }
            }
        }
    };
    return this.check;
};


“check” is called after ajax loading, and it initiates actual rendering after data loading. So the time is taken not by check itself, but by html rendering that starts here.

Do you have 800 visible events or 800 events in total where only part is visible ?
In first case 0.5sec is a normal time for data rendering, in second case - check do you have some event handlers or custom logic in templates, that can cause slowness.