Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Spelling: change performances to performance #128

Open
rcampbel3 opened this issue Dec 4, 2019 · 0 comments
Open

Spelling: change performances to performance #128

rcampbel3 opened this issue Dec 4, 2019 · 0 comments

Comments

@rcampbel3
Copy link

application performance is always singular.
exakat should replace 'performances' with 'performance'

ross@Rosss-MacBook-Air:~/project/exakat $ ag -i performances .
tests/cli/analyze.php
20:php exakat analyze -p ut_nlptools -T Performances

tests/analyzer/Test/Performances/Autoappend.php
3:namespace Test\Performances;
12: public function testPerformances_Autoappend01() { $this->generic_test('Performances/Autoappend.01'); }

tests/analyzer/Test/Performances/AvoidArrayPush.php
3:namespace Test\Performances;
12: public function testPerformances_AvoidArrayPush01() { $this->generic_test('Performances/AvoidArrayPush.01'); }

tests/analyzer/Test/Performances/MakeOneCall.php
3:namespace Test\Performances;
12: public function testPerformances_MakeOneCall01() { $this->generic_test('Performances/MakeOneCall.01'); }
13: public function testPerformances_MakeOneCall02() { $this->generic_test('Performances/MakeOneCall.02'); }
14: public function testPerformances_MakeOneCall03() { $this->generic_test('Performances/MakeOneCall.03'); }
15: public function testPerformances_MakeOneCall04() { $this->generic_test('Performances/MakeOneCall.04'); }
16: public function testPerformances_MakeOneCall05() { $this->generic_test('Performances/MakeOneCall.05'); }
17: public function testPerformances_MakeOneCall06() { $this->generic_test('Performances/MakeOneCall.06'); }
18: public function testPerformances_MakeOneCall07() { $this->generic_test('Performances/MakeOneCall.07'); }

tests/analyzer/Test/Performances/NoConcatInLoop.php
3:namespace Test\Performances;
12: public function testPerformances_NoConcatInLoop01() { $this->generic_test('Performances/NoConcatInLoop.01'); }
13: public function testPerformances_NoConcatInLoop02() { $this->generic_test('Performances/NoConcatInLoop.02'); }
14: public function testPerformances_NoConcatInLoop03() { $this->generic_test('Performances/NoConcatInLoop.03'); }

tests/analyzer/Test/Performances/ArrayMergeInLoops.php
3:namespace Test\Performances;
12: public function testPerformances_ArrayMergeInLoops01() { $this->generic_test('Performances_ArrayMergeInLoops.01'); }
13: public function testPerformances_ArrayMergeInLoops02() { $this->generic_test('Performances/ArrayMergeInLoops.02'); }
14: public function testPerformances_ArrayMergeInLoops03() { $this->generic_test('Performances/ArrayMergeInLoops.03'); }
15: public function testPerformances_ArrayMergeInLoops04() { $this->generic_test('Performances/ArrayMergeInLoops.04'); }
16: public function testPerformances_ArrayMergeInLoops05() { $this->generic_test('Performances/ArrayMergeInLoops.05'); }

tests/analyzer/Test/Performances/MbStringInLoop.php
3:namespace Test\Performances;
12: public function testPerformances_MbStringInLoop01() { $this->generic_test('Performances/MbStringInLoop.01'); }

tests/analyzer/Test/Performances/StrposTooMuch.php
3:namespace Test\Performances;
12: public function testPerformances_StrposTooMuch01() { $this->generic_test('Performances/StrposTooMuch.01'); }
13: public function testPerformances_StrposTooMuch02() { $this->generic_test('Performances/StrposTooMuch.02'); }

tests/analyzer/Test/Performances/IssetWholeArray.php
3:namespace Test\Performances;
12: public function testPerformances_IssetWholeArray01() { $this->generic_test('Performances/IssetWholeArray.01'); }
13: public function testPerformances_IssetWholeArray02() { $this->generic_test('Performances/IssetWholeArray.02'); }
14: public function testPerformances_IssetWholeArray03() { $this->generic_test('Performances/IssetWholeArray.03'); }
15: public function testPerformances_IssetWholeArray04() { $this->generic_test('Performances/IssetWholeArray.04'); }

tests/analyzer/Test/Performances/NoGlob.php
3:namespace Test\Performances;
12: public function testPerformances_NoGlob01() { $this->generic_test('Performances/NoGlob.01'); }

tests/analyzer/Test/Performances/Php74ArrayKeyExists.php
3:namespace Test\Performances;
12: public function testPerformances_Php74ArrayKeyExists01() { $this->generic_test('Performances/Php74ArrayKeyExists.01'); }
13: public function testPerformances_Php74ArrayKeyExists02() { $this->generic_test('Performances/Php74ArrayKeyExists.02'); }

tests/analyzer/Test/Performances/RegexOnCollector.php
3:namespace Test\Performances;
12: public function testPerformances_RegexOnCollector01() { $this->generic_test('Performances/RegexOnCollector.01'); }

tests/analyzer/Test/Performances/LogicalToInArray.php
3:namespace Test\Performances;
12: public function testPerformances_LogicalToInArray01() { $this->generic_test('Performances/LogicalToInArray.01'); }
13: public function testPerformances_LogicalToInArray02() { $this->generic_test('Performances/LogicalToInArray.02'); }
14: public function testPerformances_LogicalToInArray03() { $this->generic_test('Performances/LogicalToInArray.03'); }

tests/analyzer/Test/Performances/ArrayKeyExistsSpeedup.php
3:namespace Test\Performances;
12: public function testPerformances_ArrayKeyExistsSpeedup01() { $this->generic_test('Performances/ArrayKeyExistsSpeedup.01'); }

tests/analyzer/Test/Performances/RegexOnArrays.php
3:namespace Test\Performances;
12: public function testPerformances_RegexOnArrays01() { $this->generic_test('Performances/RegexOnArrays.01'); }

tests/analyzer/Test/Performances/NotCountNull.php
3:namespace Test\Performances;
12: public function testPerformances_NotCountNull01() { $this->generic_test('Performances/NotCountNull.01'); }
13: public function testPerformances_NotCountNull02() { $this->generic_test('Performances/NotCountNull.02'); }
14: public function testPerformances_NotCountNull03() { $this->generic_test('Performances/NotCountNull.03'); }
15: public function testPerformances_NotCountNull04() { $this->generic_test('Performances/NotCountNull.04'); }
16: public function testPerformances_NotCountNull05() { $this->generic_test('Performances/NotCountNull.05'); }

tests/analyzer/Test/Performances/SlowFunctions.php
3:namespace Test\Performances;
12: public function testPerformances_SlowFunctions01() { $this->generic_test('Performances_SlowFunctions.01'); }

tests/analyzer/Test/Performances/PrePostIncrement.php
3:namespace Test\Performances;
12: public function testPerformances_PrePostIncrement01() { $this->generic_test('Performances/PrePostIncrement.01'); }

tests/analyzer/Test/Performances/PHP7EncapsedStrings.php
3:namespace Test\Performances;
12: public function testPerformances_PHP7EncapsedStrings01() { $this->generic_test('Performances/PHP7EncapsedStrings.01'); }
13: public function testPerformances_PHP7EncapsedStrings02() { $this->generic_test('Performances/PHP7EncapsedStrings.02'); }

tests/analyzer/Test/Performances/FetchOneRowFormat.php
3:namespace Test\Performances;
12: public function testPerformances_FetchOneRowFormat01() { $this->generic_test('Performances/FetchOneRowFormat.01'); }

tests/analyzer/Test/Performances/CsvInLoops.php
3:namespace Test\Performances;
12: public function testPerformances_CsvInLoops01() { $this->generic_test('Performances/CsvInLoops.01'); }
13: public function testPerformances_CsvInLoops02() { $this->generic_test('Performances/CsvInLoops.02'); }
14: public function testPerformances_CsvInLoops03() { $this->generic_test('Performances/CsvInLoops.03'); }

tests/analyzer/Test/Performances/DoInBase.php
3:namespace Test\Performances;
12: public function testPerformances_DoInBase01() { $this->generic_test('Performances/DoInBase.01'); }

tests/analyzer/Test/Performances/DoubleArrayFlip.php
3:namespace Test\Performances;
12: public function testPerformances_DoubleArrayFlip01() { $this->generic_test('Performances/DoubleArrayFlip.01'); }

tests/analyzer/Test/Performances/CacheVariableOutsideLoop.php
3:namespace Test\Performances;
12: public function testPerformances_CacheVariableOutsideLoop01() { $this->generic_test('Performances/CacheVariableOutsideLoop.01'); }
13: public function testPerformances_CacheVariableOutsideLoop02() { $this->generic_test('Performances/CacheVariableOutsideLoop.02'); }

tests/analyzer/Test/Performances/JoinFile.php
3:namespace Test\Performances;
12: public function testPerformances_JoinFile01() { $this->generic_test('Performances/JoinFile.01'); }
13: public function testPerformances_JoinFile02() { $this->generic_test('Performances/JoinFile.02'); }

tests/analyzer/Test/Performances/UseBlindVar.php
3:namespace Test\Performances;
12: public function testPerformances_UseBlindVar01() { $this->generic_test('Performances/UseBlindVar.01'); }
13: public function testPerformances_UseBlindVar02() { $this->generic_test('Performances/UseBlindVar.02'); }

tests/analyzer/Test/Performances/timeVsstrtotime.php
3:namespace Test\Performances;
12: public function testPerformances_timeVsstrtotime01() { $this->generic_test('Performances/timeVsstrtotime.01'); }

tests/analyzer/Test/Performances/SubstrFirst.php
3:namespace Test\Performances;
12: public function testPerformances_SubstrFirst01() { $this->generic_test('Performances/SubstrFirst.01'); }
13: public function testPerformances_SubstrFirst02() { $this->generic_test('Performances/SubstrFirst.02'); }
14: public function testPerformances_SubstrFirst03() { $this->generic_test('Performances/SubstrFirst.03'); }
15: public function testPerformances_SubstrFirst04() { $this->generic_test('Performances/SubstrFirst.04'); }

tests/analyzer/Test/Performances/SimpleSwitch.php
3:namespace Test\Performances;
12: public function testPerformances_SimpleSwitch01() { $this->generic_test('Performances/SimpleSwitch.01'); }
13: public function testPerformances_SimpleSwitch02() { $this->generic_test('Performances/SimpleSwitch.02'); }
14: public function testPerformances_SimpleSwitch03() { $this->generic_test('Performances/SimpleSwitch.03'); }
15: public function testPerformances_SimpleSwitch04() { $this->generic_test('Performances/SimpleSwitch.04'); }

tests/analyzer/Test/Performances/MemoizeMagicCall.php
3:namespace Test\Performances;
12: public function testPerformances_MemoizeMagicCall01() { $this->generic_test('Performances/MemoizeMagicCall.01'); }
13: public function testPerformances_MemoizeMagicCall02() { $this->generic_test('Performances/MemoizeMagicCall.02'); }

tests/analyzer/Test/Performances/UseArraySlice.php
3:namespace Test\Performances;
12: public function testPerformances_UseArraySlice01() { $this->generic_test('Performances/UseArraySlice.01'); }

library/Exakat/Analyzer/Performances/Autoappend.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/MakeOneCall.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/AvoidArrayPush.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/NoConcatInLoop.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/MbStringInLoop.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/ArrayMergeInLoops.php
24:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/StrposTooMuch.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/NoGlob.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/IssetWholeArray.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/Php74ArrayKeyExists.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/RegexOnCollector.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/LogicalToInArray.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/RegexOnArrays.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/ArrayKeyExistsSpeedup.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/SlowFunctions.php
24:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/NotCountNull.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/PrePostIncrement.php
24:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/CsvInLoops.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/PHP7EncapsedStrings.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/FetchOneRowFormat.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/DoInBase.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/DoubleArrayFlip.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/CacheVariableOutsideLoop.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/UseBlindVar.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/JoinFile.php
24:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/timeVsstrtotime.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/MemoizeMagicCall.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/SubstrFirst.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/SimpleSwitch.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Analyzer/Performances/UseArraySlice.php
23:namespace Exakat\Analyzer\Performances;

library/Exakat/Reports/Top10.php
83: 'array_merge in loops' => array('Performances/CsvInLoops',
84: 'Performances/NoConcatInLoop',
85: 'Performances/ArrayMergeInLoops',),
88: 'Shorten first' => array('Performances/SubstrFirst',),

library/Exakat/Reports/Emissary.yaml
37:performances:
38: title: Performances Issues
39: menu: Performances
41: file: performances_issues
43: ruleset: Performances

library/Exakat/Reports/Ambassador.yaml
37:performances:
38: title: Performances Issues
39: menu: Performances
41: file: performances_issues
43: ruleset: Performances

library/Exakat/Reports/Owasp.php
380: 'Performances' => 'Performances');

library/Exakat/Reports/Ambassador.php
105: 'Analyze', 'Preferences', 'Inventory', 'Performances',
1580: 'Performances' => 'Performances',
1752: 'Performances',

library/Exakat/Reports/Emissary.php
376: protected function generatePerformances(Section $section) {
377: $this->generateIssuesEngine('performances_issues',
379: $this->getIssuesFaceted('Performances') );
1485: 'Performances' => 'Performances');
1645: 'Performances',

library/Exakat/Reports/Radwellcode.php
41: 'Performances/timeVsstrtotime' => 'Slow PHP built-in functions',
42: 'Performances/SlowFunctions' => 'Slow PHP built-in functions',

docs/Reports.rst
109:Ambassador depends on the following 20 themes : CompatibilityPHP53, CompatibilityPHP54, CompatibilityPHP55, CompatibilityPHP56, CompatibilityPHP70, CompatibilityPHP71, CompatibilityPHP72, CompatibilityPHP73, CompatibilityPHP74, CompatibilityPHP80, Analyze, Preferences, Inventory, Performances, Appinfo, Appcontent, Dead code, Security, Suggestions, Custom.
726: "Logical To in_array": Performances/LogicalToInArray
742: "No array_merge() In Loops": Performances/ArrayMergeInLoops
743: "Pre-increment": Performances/PrePostIncrement
768: "strpos() Too Much": Performances/StrposTooMuch
1592: /classes/test.php:1005 Performances/SlowFunctions Slow Functions array_unique(array_merge($classTags, $this->testMethods[$testMethodName]['tags']))

docs/Rules.rst
417:| Rulesets | :ref:Analyze, :ref:Performances |
712:Aliases are compiled in PHP, and do not provide any performances over the normal function.
1136:| Short name | Performances/Php74ArrayKeyExists |
1138:| Rulesets | :ref:Performances |
1676:| Short name | Performances/Autoappend |
1678:| Rulesets | :ref:Performances |
1693:Concatenations inside a loop generate a lot of temporary variables. They are accumulated and tend to raise the memory usage, leading to slower performances.
1727:| Short name | Performances/NoConcatInLoop |
1729:| Rulesets | :ref:Performances, :ref:Top10 |
1735:| Examples | :ref:suitecrm-performances-noconcatinloop, :ref:thinkphp-performances-noconcatinloop |
1814:| Rulesets | :ref:Performances |
2098:| Short name | Performances/AvoidArrayPush |
2100:| Rulesets | :ref:Performances |
2152:| Rulesets | :ref:Performances |
2255:| Short name | Performances/NoGlob |
2257:| Rulesets | :ref:Performances |
2263:| Examples | :ref:phinx-performances-noglob, :ref:nextcloud-performances-noglob |
2870:| Short name | Performances/CacheVariableOutsideLoop |
2872:| Rulesets | :ref:Performances |
4049:Performances : simplifying a closure tends to reduce the call time by 50%.
4088:| Rulesets | :ref:Suggestions, :ref:Performances |
4274:For performances reasons, this analysis only works inside methods and functions.
6062:| Rulesets | :ref:Analyze, :ref:Performances |
7104:| Short name | Performances/DoInBase |
7106:| Rulesets | :ref:Performances |
7689:| Short name | Performances/DoubleArrayFlip |
7691:| Rulesets | :ref:Performances |
7697:| Examples | :ref:nextcloud-performances-doublearrayflip |
7979:| Rulesets | :ref:Performances, :ref:Analyze, :ref:Suggestions |
8662:Using eval() <http://www.php.net/eval>_ is bad for performances (compilation time), for caches (it won't be compiled), and for security (if it includes external data).
8701:| Rulesets | :ref:Analyze, :ref:Performances, :ref:Security |
8976:| Short name | Performances/FetchOneRowFormat |
8978:| Rulesets | :ref:Performances |
9211:| Rulesets | :ref:Performances, :ref:Top10 |
9962:| Rulesets | :ref:Performances |
9999:| Rulesets | :ref:Performances |
12392:There is a gain in performances by using one call to isset <http://www.www.php.net/isset>_, instead of several, but it is a micro-optimization.
12404:| Short name | Performances/IssetWholeArray |
12406:| Rulesets | :ref:Suggestions, :ref:Performances |
12412:| Examples | :ref:tine20-performances-issetwholearray, :ref:expressionengine-performances-issetwholearray |
12463:| Short name | Performances/JoinFile |
12465:| Rulesets | :ref:Performances |
12471:| Examples | :ref:wordpress-performances-joinfile, :ref:spip-performances-joinfile, :ref:expressionengine-performances-joinfile, :ref:prestashop-performances-joinfile |
12871:| Short name | Performances/LogicalToInArray |
12879:| Examples | :ref:zencart-performances-logicaltoinarray |
13206:| Rulesets | :ref:Performances |
13309:| Short name | Performances/MakeOneCall |
13311:| Rulesets | :ref:Performances |
13317:| Examples | :ref:humo-gen-performances-makeonecall, :ref:edusoho-performances-makeonecall |
13621:| Short name | Performances/MemoizeMagicCall |
16642:| Short name | Performances/NotCountNull |
16644:| Rulesets | :ref:Performances |
16650:| Examples | :ref:contao-performances-notcountnull, :ref:wordpress-performances-notcountnull |
18154:| Rulesets | :ref:Analyze, :ref:Performances, :ref:CompatibilityPHP71, :ref:Suggestions, :ref:Top10 |
18251:| Short name | Performances/ArrayMergeInLoops |
18253:| Rulesets | :ref:Analyze, :ref:Performances, :ref:Top10 |
18261:| Examples | :ref:tine20-performances-arraymergeinloops |
18399:| Short name | Performances/MbStringInLoop |
18401:| Rulesets | :ref:Performances |
21368:The latter needs an extra memory allocation that costs about 10% of performances.
21395:| Short name | Performances/PrePostIncrement |
21397:| Rulesets | :ref:Analyze, :ref:Performances |
21403:| Examples | :ref:expressionengine-performances-prepostincrement, :ref:traq-performances-prepostincrement |
21653:| Short name | Performances/RegexOnCollector |
21655:| Rulesets | :ref:Performances |
21896:Querying an external database in a loop usually leads to performances problems. This is also called the 'n + 1 problem'.
22418:| Short name | Performances/RegexOnArrays |
22420:| Rulesets | :ref:Performances |
24276:This analysis is a related to Performances/Php74ArrayKeyExists, and is a more general version.
24291:| Rulesets | :ref:Performances |
24614:| Rulesets | :ref:Performances, :ref:Suggestions |
25022:| Short name | Performances/SimpleSwitch |
25024:| Rulesets | :ref:Performances |
25069:| Rulesets | :ref:Performances |
25112:| Rulesets | :ref:Performances, :ref:Suggestions |
25180:| Short name | Performances/SlowFunctions |
25182:| Rulesets | :ref:Performances |
25190:| Examples | :ref:churchcrm-performances-slowfunctions, :ref:suitecrm-performances-slowfunctions |
25947:| Short name | Performances/SubstrFirst |
25949:| Rulesets | :ref:Performances, :ref:Suggestions, :ref:Top10 |
25955:| Examples | :ref:spip-performances-substrfirst, :ref:prestashop-performances-substrfirst |
29916:| Rulesets | :ref:Analyze, :ref:Performances |
30602:| Short name | Performances/PHP7EncapsedStrings |
30604:| Rulesets | :ref:Performances |
30798:| Short name | Performances/UseBlindVar |
30800:| Rulesets | :ref:Performances |
30941:| Short name | Performances/UseArraySlice |
31200:| Rulesets | :ref:Performances |
32941:| Rulesets | :ref:Analyze, :ref:Performances, :ref:Suggestions |
33825: // taking advantages of performances for PHP 7.4 and older
33842:| Short name | Performances/ArrayKeyExistsSpeedup |
33844:| Rulesets | :ref:Suggestions, :ref:Performances |
34584:| Short name | Performances/CsvInLoops |
34586:| Rulesets | :ref:Performances, :ref:Top10 |
34663:include_once() and require_once() functions should be avoided for performances reasons.
35230:| Short name | Performances/StrposTooMuch |
35238:| Examples | :ref:wordpress-performances-strpostoomuch |
35274:| Short name | Performances/timeVsstrtotime |
35276:| Rulesets | :ref:Performances |
35282:| Examples | :ref:woocommerce-performances-timevsstrtotime |

docs/Rulesets.rst
45:|:ref:Performances | Check the code for slow code. |
1152:.. _performances:
1154:Performances
1157:This ruleset focuses on performances issues : anything that slows the code's execution.

docs/Configuration.rst
192: analyzer[] = 'Performances/ArrayMergeInLoops';

docs/Introduction.rst
38:Exakat detects several specialized analyzes, for Web security : making the code more secure online; PHP performances : allowing faster execution.
40:Security, performances, testability
43:Exakat has several specialized analyzes, for Web security : making the code more secure online; PHP performances : allowing faster execution; Testability : targeting the common pitfalls that makes code less testable.

docs/Cases.rst
2873:.. _tine20-performances-arraymergeinloops:
3715:.. _expressionengine-performances-prepostincrement:
3745:.. _traq-performances-prepostincrement:
6740:.. _zencart-performances-logicaltoinarray:
7893:.. _wordpress-performances-strpostoomuch:
8821:.. _churchcrm-performances-slowfunctions:
8838:.. _suitecrm-performances-slowfunctions:
8854:.. _wordpress-performances-joinfile:
8871:.. _spip-performances-joinfile:
8888:.. _expressionengine-performances-joinfile:
8909:.. _prestashop-performances-joinfile:
8964:.. _humo-gen-performances-makeonecall:
8988:.. _edusoho-performances-makeonecall:
9008:.. _contao-performances-notcountnull:
9025:.. _wordpress-performances-notcountnull:
9044:.. _woocommerce-performances-timevsstrtotime:
9063:.. _phinx-performances-noglob:
9088:.. _nextcloud-performances-noglob:
9118:.. _suitecrm-performances-noconcatinloop:
9142:.. _thinkphp-performances-noconcatinloop:
9218:.. _spip-performances-substrfirst:
9237:.. _prestashop-performances-substrfirst:
9269:.. _nextcloud-performances-doublearrayflip:
9328:.. _tine20-performances-issetwholearray:
9345:.. _expressionengine-performances-issetwholearray:

docs/Annex.rst
57:* Performances
505: * No mb_substr In Loop (Performances/MbStringInLoop ; Performances)
516: * Use array_slice() (Performances/UseArraySlice ; Analyze)
626: * Always Use Function With array_key_exists() (Performances/Php74ArrayKeyExists ; Performances)
630: * Regex On Arrays (Performances/RegexOnArrays ; Performances)
636: * Autoappend (Performances/Autoappend ; Performances)
638: * Memoize MagicCall (Performances/MemoizeMagicCall ; Analyze, ClassReview)
744: * array_key_exists() Speedup (Performances/ArrayKeyExistsSpeedup)
760: * Isset() On The Whole Array (Performances/IssetWholeArray ; Performances, Suggestions)
769: * fputcsv() In Loops (Performances/CsvInLoops)
830: * Closure Could Be A Callback (Functions/Closure2String ; Performances, Suggestions)
916: * Use The Blind Var (Performances/UseBlindVar ; Performances)
920: * Cache Variable Outside Loop (Performances/CacheVariableOutsideLoop ; Performances)
922: * Do In Base (Performances/DoInBase ; Performances)
926: * strpos() Too Much (Performances/StrposTooMuch ; Analyze)
946: * Processing Collector (Performances/RegexOnCollector)
1005: * Double array_flip() (Performances/DoubleArrayFlip ; Performances)
1078: * Use PHP7 Encapsed Strings (Performances/PHP7EncapsedStrings ; Performances)
1093: * Simple Switch (Performances/SimpleSwitch)
1094: * Substring First (Performances/SubstrFirst ; Performances, Suggestions, Top10)
1124: * Use pathinfo() Arguments (Php/UsePathinfoArgs ; Performances)
1155: * Logical To in_array (Performances/LogicalToInArray)
1161: * Avoid Concat In Loop (Performances/NoConcatInLoop ; Performances, Top10)
1325: * Should Use array_column() (Php/ShouldUseArrayColumn ; Performances, Suggestions, Level 4)
1353: * Avoid Large Array Assignation (Structures/NoAssignationInFunction ; Performances)
1359: * Avoid glob() Usage (Performances/NoGlob ; Performances)
1360: * Fetch One Row Format (Performances/FetchOneRowFormat)
1365: * Should Use Function (Php/ShouldUseFunction ; Performances)
1393: * Avoid array_push() (Performances/AvoidArrayPush ; Performances, PHP recommendations)
1421: * time() Vs strtotime() (Performances/timeVsstrtotime ; Performances, OneFile, RadwellCodes)
1443: * @ Operator (Structures/Noscream ; Analyze, Appinfo, Performances, ClearPHP)
1468: * Avoid array_unique() (Structures/NoArrayUnique ; Performances)
1527: * Could Use Short Assignation (Structures/CouldUseShortAssignation ; Analyze, Performances, OneFile, Simple)
1560: * Echo With Concat (Structures/EchoWithConcat ; Analyze, Performances, Simple, Suggestions)
1577: * Eval() Usage (Structures/EvalUsage ; Analyze, Appinfo, Security, Performances, OneFile, ClearPHP, Simple)
1590: * For Using Functioncall (Structures/ForWithFunctioncall ; Performances, ClearPHP, Simple, Level 1, Top10)
1611: * Global Inside Loop (Structures/GlobalOutsideLoop ; Performances)
1663: * Joining file() (Performances/JoinFile ; Performances)
1680: * Make One Call With Array (Performances/MakeOneCall ; Performances)
1717: * No Count With 0 (Performances/NotCountNull ; Performances)
1732: * No Substr() One (Structures/NoSubstrOne ; Analyze, Performances, CompatibilityPHP71, Simple, Suggestions, Level 2, Top10)
1733: * No array_merge() In Loops (Performances/ArrayMergeInLoops ; Analyze, Performances, ClearPHP, Simple, Level 2, Top10)
1784: * Pre-increment (Performances/PrePostIncrement ; Analyze, Performances, Simple, Level 4)
1837: * Simplify Regex (Structures/SimplePreg ; Performances)
1838: * Slow Functions (Performances/SlowFunctions ; Performances, OneFile)
1965: * While(List() = Each()) (Structures/WhileListEach ; Analyze, Performances, OneFile, Simple, Suggestions, Level 2)
2939:* Performances <ruleset_ini_performances>_
3122:| analyzer[] = "Performances/ArrayMergeInLoops";
3123:| analyzer[] = "Performances/LogicalToInArray";
3124:| analyzer[] = "Performances/MemoizeMagicCall";
3125:| analyzer[] = "Performances/PrePostIncrement";
3126:| analyzer[] = "Performances/StrposTooMuch";
3127:| analyzer[] = "Performances/UseArraySlice";
3391:| analyzer[] = "Performances/MemoizeMagicCall";
4060:.. _ruleset_ini_performances:
4062:Performances
4063:This ruleset focuses on performances issues : anything that slows the code's execution.
4066:| [Performances]
4072:| analyzer[] = "Performances/ArrayKeyExistsSpeedup";
4073:| analyzer[] = "Performances/ArrayMergeInLoops";
4074:| analyzer[] = "Performances/Autoappend";
4075:| analyzer[] = "Performances/AvoidArrayPush";
4076:| analyzer[] = "Performances/CacheVariableOutsideLoop";
4077:| analyzer[] = "Performances/CsvInLoops";
4078:| analyzer[] = "Performances/DoInBase";
4079:| analyzer[] = "Performances/DoubleArrayFlip";
4080:| analyzer[] = "Performances/FetchOneRowFormat";
4081:| analyzer[] = "Performances/IssetWholeArray";
4082:| analyzer[] = "Performances/JoinFile";
4083:| analyzer[] = "Performances/MakeOneCall";
4084:| analyzer[] = "Performances/MbStringInLoop";
4085:| analyzer[] = "Performances/NoConcatInLoop";
4086:| analyzer[] = "Performances/NoGlob";
4087:| analyzer[] = "Performances/NotCountNull";
4088:| analyzer[] = "Performances/PHP7EncapsedStrings";
4089:| analyzer[] = "Performances/Php74ArrayKeyExists";
4090:| analyzer[] = "Performances/PrePostIncrement";
4091:| analyzer[] = "Performances/RegexOnArrays";
4092:| analyzer[] = "Performances/RegexOnCollector";
4093:| analyzer[] = "Performances/SimpleSwitch";
4094:| analyzer[] = "Performances/SlowFunctions";
4095:| analyzer[] = "Performances/SubstrFirst";
4096:| analyzer[] = "Performances/UseBlindVar";
4097:| analyzer[] = "Performances/timeVsstrtotime";
4245:| analyzer[] = "Performances/ArrayKeyExistsSpeedup";
4246:| analyzer[] = "Performances/IssetWholeArray";
4247:| analyzer[] = "Performances/SubstrFirst";
4322:| analyzer[] = "Performances/ArrayMergeInLoops";
4323:| analyzer[] = "Performances/CsvInLoops";
4324:| analyzer[] = "Performances/NoConcatInLoop";
4325:| analyzer[] = "Performances/SubstrFirst";

docs/src/Rulesets.rst
45:|:ref:Performances | Check the code for slow code. |

docs/src/images/report.exakatyaml.txt
386: "Logical To in_array": Performances/LogicalToInArray
402: "No array_merge() In Loops": Performances/ArrayMergeInLoops
403: "Pre-increment": Performances/PrePostIncrement
428: "strpos() Too Much": Performances/StrposTooMuch

docs/src/images/report.text.txt
4:/classes/test.php:1005 Performances/SlowFunctions Slow Functions array_unique(array_merge($classTags, $this->testMethods[$testMethodName]['tags']))

docs/src/Configuration.rst
192: analyzer[] = 'Performances/ArrayMergeInLoops';

docs/src/Introduction.rst
38:Exakat detects several specialized analyzes, for Web security : making the code more secure online; PHP performances : allowing faster execution.
40:Security, performances, testability
43:Exakat has several specialized analyzes, for Web security : making the code more secure online; PHP performances : allowing faster execution; Testability : targeting the common pitfalls that makes code less testable.

scripts/docs/buildDefinitions.php
100: 'Performances',

ChangeLog.txt
2205: + Ambassador : added Security and Performances
2308: + Optimized performances for large projects (over 2M tokens)
2320: + Removed several nested-subqueries (bad for performances)

data/directives/ob.json
1:[{"name":"output_buffering","suggested":"4096","documentation":"You can enable output buffering for all files by setting this directive to 'On'. If you wish to limit the size of the buffer to a certain size - you can use a maximum number of bytes instead of 'On', as a value for this directive (e.g., output_buffering=4096). As of PHP 4.3.5, this directive is always Off in PHP-CLI."},{"name":"output_handler","suggested":" mb_output_handler or ob_iconv_handler(), ob_gzhandler() or zlib.output_compression;","documentation":"Use the first suggested values to handle character encoding. Use the second values for on the fly compression; Use your own function if you have one."},{"name":"implicit_flush","suggested":"False","documentation":"Changing this to TRUE tells PHP to tell the output layer to flush itself automatically after every output block : this has performances penalty."}]

data/phpcsfixer.json
37: "Performances/PrePostIncrement": {

human/en/Performances/ArrayKeyExistsSpeedup.ini
17:// taking advantages of performances for PHP 7.4 and older

human/en/Performances/PrePostIncrement.ini
4:The latter needs an extra memory allocation that costs about 10% of performances.

human/en/Performances/NoConcatInLoop.ini
2:description = "Concatenations inside a loop generate a lot of temporary variables. They are accumulated and tend to raise the memory usage, leading to slower performances.

human/en/Performances/IssetWholeArray.ini
20:There is a gain in performances by using one call to isset, instead of several, but it is a micro-optimization.

human/en/Structures/UseArrayFunctions.ini
26: Performances/ArrayMergeInLoops.

human/en/Structures/NestedLoops.ini
18:Nested loops are worth a check for performances reasons, as they will process a lot of times the same instructions.

human/en/Structures/EvalUsage.ini
4:Using eval() is bad for performances (compilation time), for caches (it won't be compiled), and for security (if it includes external data).

human/en/Structures/QueriesInLoop.ini
4:Querying an external database in a loop usually leads to performances problems. This is also called the 'n + 1 problem'.

human/en/Structures/OnceUsage.ini
2:description = "include_once() and require_once() functions should be avoided for performances reasons.

human/en/Classes/MakeMagicConcrete.ini
25:See also Performances/MemoizeMagicCall.

human/en/Php/ShouldUseFunction.ini
27:This analysis is a related to Performances/Php74ArrayKeyExists, and is a more general version.

human/en/Php/CompactInexistant.ini
15:For performances reasons, this analysis only works inside methods and functions.

human/en/Functions/AliasesUsage.ini
16:Aliases are compiled in PHP, and do not provide any performances over the normal function.

human/en/Functions/Closure2String.ini
8:Performances : simplifying a closure tends to reduce the call time by 50%.

human/en/Rulesets/Performances.ini
1:name="Performances"
2:description = "This ruleset focuses on performances issues : anything that slows the code's execution."

human/en/Reports/Ambassador.ini
36:themes[] = "Performances";

media/devfaceted/data/menu.html
11:

  • Performances
  • media/devfaceted/data/performances_issues.html
    4: Performances issues

    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    None yet
    Projects
    None yet
    Development

    No branches or pull requests

    1 participant