Skip to content

Latest commit

 

History

History
59 lines (41 loc) · 3.31 KB

README.md

File metadata and controls

59 lines (41 loc) · 3.31 KB

Julia2021 Workshop – Package development: improving engineering quality & latency

Abstract

Julia holds immense promise for a composable package ecosystem. Potential obstacles to achieving this promise include missing methods for unanticipated types, unwitting type-piracy, poor performance due to inference failures, method ambiguities, and latency due to long compilation times and/or invalidation of previously-compiled code.

This workshop will tutor developers on the use of some of the tools available for improving package quality and reducing latency. We will begin by summarizing the factors that influence dispatch, inference, latency, and invalidation, and how monitoring inference provides a framework for detecting problems before or as they arise. We will then tutor attendees in the use of tools like MethodAnalysis, JET, Cthulhu, and SnoopCompile to discover, analyze, and fix detected problems in package implementation. We will also show how in addition to improving robustness, such steps can often streamline design and reduce latency.

This workshop is aimed at experienced Julia developers.

Prerequisites

For this workshop, we recommend you use Julia v1.7 or higher. You can download a prebuilt v1.7 binary or an nightly build. You can also use Julia built from the latest source.

If you've installed an appropriate Julia version, clone this repository and install the required packages with the following commands:

julia> pwd()    # check whether you're in this folder (if not, navigate here with `cd`)
"/home/user/path/to/juliacon2021-workshop-pkgdev"

julia> using Pkg

julia> Pkg.activate(@__DIR__)

julia> Pkg.instantiate()

If you have any errors involving PyPlot or PyCall, try this:

julia> ENV["PYTHON"]=""
julia> Pkg.build("PyCall")

Now you can run the workshop notebooks with:

julia> using IJulia

# # install Jupyter kernel if not exist
# julia> IJulia.installkernel(KERNEL_NAME)

julia> IJulia.notebook(; dir=@__DIR__)

Workshop Outline