Welcome Guest, Not a member yet? Register   Sign In
CodeIgntier Execution Time Bug
#1

[eluser]Unknown[/eluser]
Hi there,

I am not sure if this is a bug or not.

In my controllers/my.php, I have the following code:

Code:
function ajax()
{
// all my other code here
            $this->benchmark->mark('section1_start');
            echo $this->load->view('my_newsfeed_tabajax',$data,true);
            $this->benchmark->mark('section1_end');
die();
}

As for view/my_newsfeed_tabajax.php, I have the following code:

Code:
$this->benchmark->mark('sectionview_start');
// all other code here
$this->benchmark->mark('sectionview_end');

Funnily, when I opened up the page with profiler enabled, it shows the following data:

Loading Time Base Classes 0.0008
Sectionview 0.0935
Section1 1.9501
Controller Execution Time ( My / Ajax ) 1.9631
Total Execution Time 1.9640

There is like 1.0+ second difference in between the loading of the view and executing the whole code in the view. I have been trying to do a benchmark on every single code in my view page but to no avail. All shows that it falls below 0.01 second. Thus, 1.0+ second seems a little bit too much and sometimes it can go more than 5 seconds.

Anybody know why this is happening? Thank you so much. Your help / suggestions are much appreciated!




Theme © iAndrew 2016 - Forum software by © MyBB