Successfully reported this slideshow.
Your SlideShare is downloading. ×

Mission Pharo Kernel

Ad
Ad
Ad
Ad
Ad
Ad
Ad
Ad
Ad
Ad
Mission Pharo Kernel
ESUG 2016, Prague
Pavel Krivanek and Christophe Demarey
New libraries
New tools
New tests
More documentation
Pharo is growing
Pharo evolution
Squeak 3.9 Pharo 1.0 Pharo 1.1 Pharo 1.2 Pharo 1.3 Pharo 1.4 Pharo 2.0 Pharo 3.0 Pharo 4.0 Pharo 5.0
Class...

YouTube videos are no longer supported on SlideShare

View original on YouTube

Loading in …3
×

Check these out next

1 of 59 Ad

Mission Pharo Kernel

Download to read offline

Mission Pharo Kernel
Video: https://youtu.be/YQD0pSb2mzw

Thu, August 25, 10:00am – 10:30am

First Name: Guillermo
Last Name: Polito
Email: guillermopolito@gmail.com
Title: Mission Pharo Kernel
Type: Talk

Abstract: The Pharo team and community have been working a lot lately to make Pharo a modular system. The mission: make Pharo a simpler system, easier to
build and change. The tools: dependency analyses, refactorings, bootstrapping, modular package installation. The challenges: a circular system definition,
spaghetti and legacy code, hidden dependencies. This talk presents the work around the Pharo Kernel, a minimal Pharo image that contains the necessary
systems to boot and load your own packages. The Pharo Kernel is not only an image. It is also a new process to build an image. A new process to manage,
validate and install packages in Pharo, to integrate issues, to build Pharo systems. In this talk you'll learn what you could expect from Pharo in the
(not so far away) future.

Bio: Guille Polito is research engineer at CNRS, France. Pharoer since 2010, he participates actively in the Pharo open source community since several
years. He currently works on the modularization of Pharo where he does software archeology, refactoring, library rewriting and participates in the Virtual
Machine development.

Mission Pharo Kernel
Video: https://youtu.be/YQD0pSb2mzw

Thu, August 25, 10:00am – 10:30am

First Name: Guillermo
Last Name: Polito
Email: guillermopolito@gmail.com
Title: Mission Pharo Kernel
Type: Talk

Abstract: The Pharo team and community have been working a lot lately to make Pharo a modular system. The mission: make Pharo a simpler system, easier to
build and change. The tools: dependency analyses, refactorings, bootstrapping, modular package installation. The challenges: a circular system definition,
spaghetti and legacy code, hidden dependencies. This talk presents the work around the Pharo Kernel, a minimal Pharo image that contains the necessary
systems to boot and load your own packages. The Pharo Kernel is not only an image. It is also a new process to build an image. A new process to manage,
validate and install packages in Pharo, to integrate issues, to build Pharo systems. In this talk you'll learn what you could expect from Pharo in the
(not so far away) future.

Bio: Guille Polito is research engineer at CNRS, France. Pharoer since 2010, he participates actively in the Pharo open source community since several
years. He currently works on the modularization of Pharo where he does software archeology, refactoring, library rewriting and participates in the Virtual
Machine development.

Advertisement
Advertisement

More Related Content

More from ESUG (20)

Recently uploaded (20)

Advertisement

Mission Pharo Kernel

  1. 1. Mission Pharo Kernel ESUG 2016, Prague Pavel Krivanek and Christophe Demarey
  2. 2. New libraries New tools New tests More documentation Pharo is growing
  3. 3. Pharo evolution Squeak 3.9 Pharo 1.0 Pharo 1.1 Pharo 1.2 Pharo 1.3 Pharo 1.4 Pharo 2.0 Pharo 3.0 Pharo 4.0 Pharo 5.0 Classes Packages LOC
  4. 4. Code for future use Duplicities Obsolete code DO-NOT-TOUCH code
  5. 5. Pharo ZEN ● Easy to understand, easy to learn from, easy to change. ● Objects all the way down. ● Examples to learn from. ● Fully dynamic and malleable. ● Beauty in the code, beauty in the comments. ● Simplicity is the ultimate elegance. ● Better a set of small polymorphic classes than a large ugly one. ● Classes structure our vocabulary. ● Messages are our vocabulary. ● Polymorphism is our esperanto. ● Abstraction and composition are our friends. ● Tests are important but can be changed. ● Explicit is better than implicit. ● Magic only at the right place. ● One step at a time. ● There is no unimportant fix. ● Learning from mistakes. ● Perfection can kill movement. ● Quality is a emerging property. ● Simple processes to support progress. ● Communication is key. ● A system with robust abstractions that a single person can understand.
  6. 6. Modularity
  7. 7. Pharo Kernel
  8. 8. From top - cleaning - shrinking - reloading From bottom bootstrapping from zero - reloading -
  9. 9. From top shrinking and modularization - started before Pharo - removing of code is easy - clean removing is not easy - reloading is even harder Morphic reloaded [22.07.2006]
  10. 10. Kernel image evolution in shortcut BROKEN! works again BROKEN! works again BROKEN! works again BROKEN! works again BROKEN! works again BROKEN! works again BROKEN! works again Broken again... [18.8.2016]
  11. 11. Why so hard and long? Everyone needs to take of care of modularity integrated inintegrated in development processdevelopment process (tests, rules, CI jobs)(tests, rules, CI jobs)
  12. 12. CI jobs for Pharo modularization - since Pharo 2.0 - shrink image - increase granularity of reloaded modules - tests - coverage testing - experiments (Tanker) https://ci.inria.fr/pharo/view/6.0-SysConf/
  13. 13. CI jobs for Pharo modularization Kernel image (shrinked / bootstrapped) + Monticello + Network support + Remote repositories support + Metacello = minimal Pharo + SUnit, Display support, UFFI + Morphic core, Morphic + UI, Basic tools, IDE = Pharo
  14. 14. Bootstrapped & reloaded from GIT
  15. 15. Let's talk about BOOTSTRAP
  16. 16. « The process that builds the minimal infrastructure of a langage 
reusable to define the langage itself » Bootstrap
  17. 17. Why do we need a bootstrap ? ● Have a known initial state ● Be able to reproduce the state of a system ● Ensure we can reinitialize the system at any time ● Ease Kernel evolution ● Identify a small subset of the language allowing the definition of the language itself
  18. 18. Why bootstraping is difficult?
  19. 19. Archaelogy
  20. 20. Dead code!
  21. 21. Strange things
  22. 22. cleanups
  23. 23. Missing code
  24. 24. The dependency hell
  25. 25. Cut dependencies
  26. 26. Code refactoring
  27. 27. How to fix bad dependencies? Create a new package to isolate functionnalities Move some methods as extensions to another package Re-design completely a functionality e.g. startup list ...
  28. 28. Tools support
  29. 29. Dependency Analyser
  30. 30. Dependency dashboard X 2
  31. 31. Dependency visualization https://ci.inria.fr/pharo/job/Pharo-6.0-Dependenc yAnalysis/ws/bootstrap-dependency-report-graph.ht ml
  32. 32. The bootstrap process
  33. 33. 1 Day
  34. 34. 2 Day
  35. 35. 3 Day
  36. 36. 4 Day
  37. 37. 5 Day process
  38. 38. 6 Day
  39. 39. 7 Day
  40. 40. More details cf phd Guillermo Polito: https://hal.inria.fr/tel-01251173
  41. 41. Story #2
  42. 42. Road to a working bootstrap
  43. 43. Bootstrap challenge > language side bootstrap Language initialization generally done VM side We want to do it language side (image side): need to run code on top of a language under construction
  44. 44. Bootstrap challenge > language side bootstrap
  45. 45. Road to a working bootstrap First bootstrapped image!
  46. 46. Road to a working bootstrap
  47. 47. Road to a working bootstrap We run the image … … VM crash
  48. 48. Road to a working bootstrap > some debugging examples Missing class in the boostrap e.g. Float Super class not set Super class set to a wrong value
  49. 49. Road to a working bootstrap Compile VM in debug mode Run bootstrapped image through Xcode / LLDB
  50. 50. Road to a working bootstrap > verifying the bootstrap Rely on Pharo tests (>8 000 tests) ● Load SUnit ● Load test packages ● Run tests
  51. 51. Wants to know more? Bootstrap process hosted on Pharo CI server https://ci.inria.fr/pharo/view/Pharo%20bootstrap/ GitHub repository https://github.com/guillep/PharoBootstrap
  52. 52. Conclusion Having a modular system requires a lot of energy • Easy to break • Concern of everyone We now have a working Pharo bootstrapped image. We are able to load packages on top to build a full Pharo-image (UI, IDE, etc.)
  53. 53. Roadmap Make the boostrap process more robust Up-to-date package dependencies for the Pharo image + use of Cargo package manager Build the official Pharo image on top of the bootstrap Make the kernel smaller (e.g. kick out Unicode)
  54. 54. «  Always leave the campground cleaner than you found it. » -Boy Scout rule, Uncle Bob

×