Inefficient case .. of.
Original Reporter info from Mantis: runewalsh
-
Reporter name:
Original Reporter info from Mantis: runewalsh
- Reporter name:
Description:
http://freepascal.org/docs-html/ref/refsu57.html explicitly states that "no optimizations performed" for strings, so the naive reader would think they are implemented for ordinals. However, the code attached produces 1023 sequential subtractions (sub+je) instead of comparison tree. This noticeably degrades performance of large non-sequential cases, such as those on Unicode codepoints.
Mantis conversion info:
- Mantis ID: 31536
- Version: 3.0.1
- Fixed in version: 3.1.1
- Fixed in revision: 35645 (#d5754cf4)