X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Dev Questions (https://forum.x-cart.com/forumdisplay.php?f=20)
-   -   4.0.x performance improvement (https://forum.x-cart.com/showthread.php?t=24694)

geckoday 09-06-2006 09:26 PM

4.0.x performance improvement
 
I was running some profiling on CPU usage and ran into something that slows down every page considerably that was fixed in 4.1. In func.php function func_display find these lines and delete them:
PHP Code:

if (empty($templater->strict_resources) && ($r=func_bf_psc('r''asc'))!==false) {
$templater->strict_resources[] = $r;


These lines were deleted in 4.1.x so I'm pretty sure the change is safe. They seem to have something to do with getting a list of templates that should always be compiled, even if the compiled version already exists in templates_c.

I'm running this now and it doesn't cause any problems, but the performance improvement is dramatic.

NOTE: I have checked the upgrade packages and this fix applies only to 4.0.14 through 4.0.19.

inebriate 09-06-2006 10:29 PM

Re: 4.0.x performance improvement
 
Thanks for the tip! Seems to greatly improve the load times on my site, even cleared the cache just to make sure.

B00MER 09-07-2006 02:30 AM

Re: 4.0.x performance improvement
 
Nice find, defiantly a turbo boost :)

TJ Stephens 09-07-2006 08:22 AM

Re: 4.0.x performance improvement
 
Wow! Thank you. Seems to really improve speed on my site...

creative xpress 09-07-2006 08:36 AM

Re: 4.0.x performance improvement
 
Great Find!!!!!!!! My store is now loading in less that one second will more than 100 users. Thank you for sharing this!!!

Cameron

NightFire 09-07-2006 09:05 AM

Re: 4.0.x performance improvement
 
WOW !!!! It really makes a difference :|
Thanks for sharing this great solution.

augustash 09-07-2006 10:29 AM

Re: 4.0.x performance improvement
 
Friggin Wow. Does anyone know what these lines did. Don't want to find out later that an email notice or something is not working.

geckoday 09-07-2006 10:54 AM

Re: 4.0.x performance improvement
 
Quote:

Originally Posted by augustash
Friggin Wow. Does anyone know what these lines did. Don't want to find out later that an email notice or something is not working.

Yeah, my site went from 3 seconds to under a second. I've traced the code pretty good and am pretty darn sure it won't cause any problems removing it. Particularly as X-Cart removed it from 4.1. I think its leftover junk that forces product.tpl to always be compiled. X-Cart does a few unnatural acts with Smarty and perhaps there was a reason at one time but I have looked at it pretty hard and can't find any good reason for it.

augustash 09-07-2006 11:06 AM

Re: 4.0.x performance improvement
 
Well you would think that since they removed it from the new version that they could notify users of older versions of this. If everything continues to work properly this is not just oops I missed that thing. With the loads times now, I feel like I just stepped into a Porsche instead of a Saturn

Zaja 09-07-2006 04:35 PM

Re: 4.0.x performance improvement
 
Thanks Ralph, great/incredible speed improvement.... 8O


All times are GMT -8. The time now is 02:56 PM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.