Skip to content

Latest commit

 

History

History
53 lines (50 loc) · 3.03 KB

CAPSTONE_INTRODUCTION.MD

File metadata and controls

53 lines (50 loc) · 3.03 KB

Capstone Introduction

GraalVM - terminology (simplified)

  • Graal - An advanced optimizing just-in-time (JIT) compiler for Java
  • GraalVM - A JVM distribution with GraalVM as the (tier 2) JIT compiler
  • Native Image - An ahead-of-time (AOT) compiler for Java.
  • Graal IR - An intermediate representation used in Graal. It is graph based and in SSA form.
    • More details can be found here.
  • Truffle - A framework for the implementation of programming language runtimes as AST interpreters.
    • AST interpreters are generally very slow compared to bytecode interpreters, JIT compilers or AOT compilers, but Truffle uses partial evaluation (futamura projections) to JIT-compile the ASTs of hot functions.
    • Documentation
    • Related paper

Useful links

Initial tasks

Shared

  • Setup a working environment
    • clone mx
    • add it to PATH
    • clone graal-prophet https://github.com/cloudhubs/graal
    • open the project in an IDE using mx intelijinit
    • build native image of helloworld
    • view the graph of the main method in IGV
    • build native image of helloworld using mx helloworld or write your own program
  • Look at the source code of the prophet plugin
  • Look at the source code of prophet-utils

Divide & Conquer

  • Design a more general approach for the annotation extraction.
    • Try to think of an approach that would generalize to other Spring Entities (and then, as the next step, to other java frameworks) without too much extra code.
    • Do not depend on concrete annotations in the code.
  • Bounded context comparison
    • Write a program to compare two bounded contexts and report differences.
  • Prophet-utils - graal-prophet interface
    • Design a proper (and ideally simple) interface between the prophet plugin in graal and the rest of the system
  • Refactoring, cleanup bug fixes
    • Everything is Work in Progress, so you might encounter some silly code.
  • Testing
    • Tests
    • continuous integration