Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: dlang/phobos
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: e216c10b2ce0
Choose a base ref
...
head repository: dlang/phobos
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 5529e7afc335
Choose a head ref
  • 2 commits
  • 1 file changed
  • 2 contributors

Commits on Jun 2, 2016

  1. Improve speed of find for random access needles (strings)

    For find a string within a string, std.algorithm.searching.find was
    unnecessarily slow. The reason is it created intermediate slices. A
    naively written nested-for-loop implementation was a few times
    faster.
    
    For random access ranges (which strings are) this uses an index based
    algorithm, which does not need to create an intermediate slice. Speed
    is now comparable to the nested-for-loop implementation even in rather
    pathological cases.
    
    This might help with issue 9646.
    Andreas Zwinkau authored and qznc committed Jun 2, 2016
    Configuration menu
    Copy the full SHA
    a9d5b8c View commit details
    Browse the repository at this point in the history
  2. Merge pull request #4362 from qznc/faster-find

    Improve speed of find for random access needles (strings)
    andralex committed Jun 2, 2016
    Configuration menu
    Copy the full SHA
    5529e7a View commit details
    Browse the repository at this point in the history
Loading