- Популярные видео
- Авто
- Видео-блоги
- ДТП, аварии
- Для маленьких
- Еда, напитки
- Животные
- Закон и право
- Знаменитости
- Игры
- Искусство
- Комедии
- Красота, мода
- Кулинария, рецепты
- Люди
- Мото
- Музыка
- Мультфильмы
- Наука, технологии
- Новости
- Образование
- Политика
- Праздники
- Приколы
- Природа
- Происшествия
- Путешествия
- Развлечения
- Ржач
- Семья
- Сериалы
- Спорт
- Стиль жизни
- ТВ передачи
- Танцы
- Технологии
- Товары
- Ужасы
- Фильмы
- Шоу-бизнес
- Юмор
Optimize Your Kotlin Performance - Profiling, Micro-optimizations and Precomputing
In the last episode (https://youtu.be/811mqEMgNPs) we had fun generating anagrams. The code was too slow though, so today we are going to look at optimizing the performance of our algorithm.
We start with a performance test to allow us to measure how long it is taking, and then profile the running code in IntelliJ to see where it is spending most of its time. That gives us candidates for micro-optimizations - making specific pieces of code run quicker.
When that stops paying dividends we turn our attention to a more major change - precomputing information so that we we can weed out non-anagrams quicker. This needs structural changes, but gives another speed boost without making everything incomprehensible.
The code is available on GitHub - https://github.com/dmcg/bumper-generator
I'm offering a prize of a signed copy of my book to the best suggestion for further optimization - either raise a PR or, if you just have a bright idea, let's chat about it in the comments below.
If you like this, you’ll probably like the book Java to Kotlin, A Refactoring Guidebook
http://java-to-kotlin.dev
Видео Optimize Your Kotlin Performance - Profiling, Micro-optimizations and Precomputing канала Pairing with Duncan
We start with a performance test to allow us to measure how long it is taking, and then profile the running code in IntelliJ to see where it is spending most of its time. That gives us candidates for micro-optimizations - making specific pieces of code run quicker.
When that stops paying dividends we turn our attention to a more major change - precomputing information so that we we can weed out non-anagrams quicker. This needs structural changes, but gives another speed boost without making everything incomprehensible.
The code is available on GitHub - https://github.com/dmcg/bumper-generator
I'm offering a prize of a signed copy of my book to the best suggestion for further optimization - either raise a PR or, if you just have a bright idea, let's chat about it in the comments below.
If you like this, you’ll probably like the book Java to Kotlin, A Refactoring Guidebook
http://java-to-kotlin.dev
Видео Optimize Your Kotlin Performance - Profiling, Micro-optimizations and Precomputing канала Pairing with Duncan
Комментарии отсутствуют
Информация о видео
20 января 2023 г. 21:32:11
00:29:55
Другие видео канала




















