Extension:PhpTags/Performance

The PhpTags extension is designed to obtain the best possible MediaWiki extensions performance without using any additional components (only pure PHP code).

This is achieved by using the concept of Magic expressions instead of Magic words. Although PhpTags himself uses the technology Magic words, but it allows to reduces to a minimum overhead of usage other extensions.

Time that takes PhpTags consists of:
 * analysis of expression
 * execution of instructions
 * data transfer between extensions
 * time spent by the extensions

PhpTags works so rapidly that when used under the concept of the magic expressions the run time is negligible or it is not possible to measure.
 * The main part of the code should be in the extensions, and in the PhpTags placed instructions which features of these extensions, and in what order to use.

Of course, you can use this application as you wish, and in order to find out the effectiveness (as possible) this solution, I ran some tests.
 * All of these tests can give only a general overview of performance since they use completely different approaches and technologies.

Compared to Magic Words
For comparison I took two nested loops of 20 loops each, a total of 420 loops.

MediaWiki with PhpTags faster Magic words in more 86 times. ( 5.950 / 0.069 = 86.232 ) The next time bytecode will be taken from the cache, and PhpTags will be faster more 95 times. ( 5.950 / (0.069-0.007) = 95.968 )

Compared to pure PHP
For a more accurate measurement I increased the number of cycles up to 100100

PhpTags: 11.462 secs PHP: 0.029 secs PhpTags/PHP: 394.573

As it can be seen PhpTags in this test is slower pure PHP almost in 400 times.