|
1 | 1 | # Performance
|
2 | 2 |
|
3 |
| -[](https://github.com/timholy/Performance.jl/actions) |
| 3 | +[](https://github.com/AdvancedScientificComputingInJuliaWashU/Performance.jl/actions) |
| 4 | + |
| 5 | +This assignment has two goals: |
| 6 | +- it coaches you in good Julia practices, avoiding traps that can kill performance. By and large, this is an exercise in avoiding patterns that result in poor type inference, and in experimenting with tools that help you detect, diagnose, and resolve inference problems. |
| 7 | +- it introduces a few concepts from the analysis of algorithms, specifically the "big-O" notation and its use in evaluating implementations. |
| 8 | + |
| 9 | +For this homework, start from the `test/runtests.jl` file, which mostly just `include`s a number of individual test files. |
| 10 | +Open them one-by-one and read the comments that describe the problems to be solved. |
| 11 | +These individual test files start with one or more links, usually to sections of the Julia manual's [Performance tips](https://docs.julialang.org/en/v1/manual/performance-tips/) page. Start by reading those pages/sections for background information that will help in solving this problem. |
| 12 | + |
| 13 | +Solve the problems by modifying the file of the same name in `src/`, *not* by modifying the tests. |
| 14 | +One exception to this rule is the `ntests_finished` at the top of `runtests.jl`: if you're bothered by failures of the |
| 15 | +tests you haven't yet fixed, just set this to the number of files whose tests you want to run. For example, to run |
| 16 | +just the tests in `test/globals.jl`, set `ntests_finished = 1`. If you do modify `ntests_finished`, |
| 17 | +make sure you put it back (or set `ntests_finished = typemax(Int)`) to ensure they all run before |
| 18 | +you declare victory with this assignment. |
| 19 | + |
| 20 | +Some problems might say "See `?somefunction`," which means you should read the help on `somefunction`. |
| 21 | + |
| 22 | +Finally, a couple of notes about this repository: |
| 23 | +- when creating it, I deliberately left out the `Documenter` and `Codecov` plugins since neither is needed |
| 24 | +for this assignment. |
| 25 | +- some packages like ProfileView are listed as depenencies of this repository. This is for your convenience, but |
| 26 | + any real package generally shouldn't include such dependencies. Put them in your default environment instead, |
| 27 | + reserving the package environment for things actually needed by the package. |
0 commit comments