ZF2 Optimize for high traffic

There’s few very simple steps to achieve a faster application. There’s three things that can always be considered. ZF2 Performance QuickTipp #1 – ViewModels Always manually assign the fully qualified script to render. This will increase the performance a little. It’s done like this: public function someAction() { $viewModel = new ViewModel(); $viewModel->setTemplate(‘MODULE / CONTROLLER … Read more

faster equivalent of gettimeofday

POSIX Clocks I wrote a benchmark for POSIX clock sources: time (s) => 3 cycles ftime (ms) => 54 cycles gettimeofday (us) => 42 cycles clock_gettime (ns) => 9 cycles (CLOCK_MONOTONIC_COARSE) clock_gettime (ns) => 9 cycles (CLOCK_REALTIME_COARSE) clock_gettime (ns) => 42 cycles (CLOCK_MONOTONIC) clock_gettime (ns) => 42 cycles (CLOCK_REALTIME) clock_gettime (ns) => 173 cycles (CLOCK_MONOTONIC_RAW) … Read more

How can I speed up my Perl program?

Please remember the rules of Optimization Club: The first rule of Optimization Club is, you do not Optimize. The second rule of Optimization Club is, you do not Optimize without measuring. If your app is running faster than the underlying transport protocol, the optimization is over. One factor at a time. No marketroids, no marketroid … Read more

Is there a workaround to the C# 28-time inline limit?

I haven’t tested this, but it seems like one possible workaround is to have multiple properties that all return the same thing. Conceivably you could then get 28 inlines per property. Note that the number of times a method is inlined most likely depends on the size of native code for that method (See http://blogs.msdn.com/b/vancem/archive/2008/08/19/to-inline-or-not-to-inline-that-is-the-question.aspx), … Read more

tech