Some rough ideas:
- LSP-server aggregator. Create a prototype of a tool/protocol for interaction between lsp-servers. E.g. a thing that behave like a client for different lsp-servers and process and redirects requests from one to another. This might be helpful for interlanguage interaction.
- light-weight extension? a-la idea in browser; Lightweight extension that brings most of inspections and functionality for code-review, pr-review, and project management. The main goal — bring as much ide-functionality as possible to any place where one may need to inspect code (focus: for team leads and reviewers).
- LLMs:
- test prioritization
- source code + failing test =[get]=> why it is failing
- Practically define a class of problems where existing solutions runs much better with LLM with bigger context
- Prioritization search (i.e. in logic programming or parsing). For example, parsers: one can use an exponential approach (e.g. for fair alternation); get from LLM why in this case parsing failed (extract real reason from a set of different errors)
- Code optimization. Find (in the background somewhere continuously) where the code can be optimized by synthesizing alternative solutions for pieces of code + test generation + measurements => proposal for improvement with prioritization of what to improve
- loop invariant generation; application to reversible programming
Bringing new language features to Kotlin
Keywords: compilers, type systems, program analysis, language design, Kotlin
Active topics/projects:
- [~] GADTs
- [~] (Restricted) Union types
- [~] Denotable existantionals
- [~] Compound expressions; e.g. enriching structural control flow operators with optional init-statement before condition (like C)
- [~] Internal and external parameter names (like Swift) and ability to enforce parameter usage in named form only
- [~] Comprehensions
- [~] ReplaceWith specification
- …
Requirements
- Desire to work and learn something new and dig into the Kotlin compiler
- Proficiency in Kotlin
- Knowledge of fundamental concepts of compiler and programming languages design
- Knowledge/Experience with type systems, static analysis is desirable
Relational programming with miniKanren/OCanren
Keywords: relational/logic programming, profiling, embedded languages
Description
OCanren is a strongly-typed embedding of miniKanren relational programming language into OCaml. Nowadays, the implementation of OCanren strongly resembles faster-miniKanren. Previous implementation was based on microKanren with disequality constraints.
Actual topics/projects:
- [Easy, introduction project] Implement a set of useful programs on OCanren; for example, a schedule generator for a university that takes into account the restrictions and wishes of the university and teachers
- Visualiser of miniKanren execution
- OCanren/miniKanren profiler gathering information about relations calls
- Dynamic compiler for OCanren
- OCanren search parallelization. The crucial part of of any relational programming language is the search of answers. The goal of the project is to research and development of a suitable way to parallelize the search in order to speed it up.
- Apply machine learning to the optimal order of conjuncts problem
- Enrich Haskell^{-1} approach with miniKanren interleaving and compare with existing miniKanren implementations
- Embed minikanren into mainstream language like Kotlin
Useful links:
- Fail Fast and Profile On: Towards a miniKanren Profiler
- Some criteria for implementations of conjunction and disjunction in microKanren
- Efficient fair conjunction for structurally-recursive relations
Knowledge in the following areas would be a plus:
- Basic knowledge in programming languages theory
- Basic knowledge in programming languages formal semantics
- Experience with functional programming paradigm (Haskell/OCaml/Scheme/Racket/…)
- Basic knowledge of logic/relational programming
Lama compiler and infrastructure
Keywords: compilers, semantics, static analisys, code generation
Lama is a programming language developed by JetBrains Research for educational purposes (as an exemplary language to introduce the domain of programming languages, compilers, and tools). It currently exists for x86_32 architecture only. There are many directions for its (and its infrastructure) development, both scientific and purely technical:
- [~] Implement a lsp-server (together with a basic plugin for VSCode/IntelliJ which runs the server for all .lama files); useful links: ocaml-lsp, lsp-spec
- Implement a native compiler to ARM (32 and/or 64) [the task can be naturally extended with advanced register allocation]
- [~] Implement a native compiler to x86_64 [the task can be naturally extended with advanced register allocation]
- [~] Lama memory management; current garbage collector is a tiny simplest mark-and-copy stop-the-world algorithm; it can be improved in a number of ways: mark-and-compact, generational (partial) GC, concurrent and/or parallel GC, …
- Debugger + better gdb support
- Better support for course On Virtual Machines; tasks are:
- Bytecode interpreter
- Bytecode idioms analyzer
- Truffle Lama
- Bytecode verifier
- Dynamic profiler
- Dynamic compiler (at least simple one-pass one)
- Console debugger (for bytecode interpreter)
- GC: a lot (generational, incremental, parallel, …)
- Type of bounds in runtime:
size_t
$\to$uint32_t*
- Define program interface for globals locations
- byterun disassembler. Current “small” problems:
- add checks that input data are correct
- current implementation assumes
char
to be unsigned; we shall use unsigned char instead - Numerical instruction labels written into the disassembler source code. If you think about a possible change in the encoding of instructions, you need to describe it separately and use named constants or generate switches with a preprocessor
- Bytecode
STOP
doesn’t disassemble - add const qualifier
static
for private functions and globals- move the disassembly of one bytecode into a separate function that produces the advanced bytecode address
- tables of functions and globals
- Support compilation into OCaml; useful link: Malfunctional
- Develop a weak (or at least gradual) type system
- Compiler into LLVM-IR; This task can be extended later to support specialization of the generated IR subset
- Implement a tool set for support different static analysis approaches
- Partial evaluator for generated x86_32 GASM subset
- Concurrency
- Make tag hashes smarter (a-la like in ocaml)
- …
Requirements
- Basic knowledge of functional programming
- The very basic knowledge about compiler design
- Ability to read documentation and papers in English
- Desire to work and learn something new =)
Patching OCaml and ML-like languages
Keywords: functional programming, OCaml, compilation
Description
OCaml is one of the mainstream functional programming languages. The project aims to bring new features in ML-like languages and produce some patches fixing ad-hoc or poorly designed language features such as polymorphic variants, active patterns, and modules.
Actual topics/projects:
-
ML to .Net
Long-term goal: port OCaml with all the features into .Net
Short-term goal: miniML & SML to .Net
Useful links: ocamil, smldotnet, a paper, miniML - OCaml to JVM
- [~v] Patching polymorphic variants for OCaml
Usefull links: a paper, Tommaso Petrucciani PhD thesis and prototype
Knowledge in the following areas would be a plus:
- Basic knowledge in programming languages theory
- Basic knowledge in programming languages formal semantics
- Experience with functional programming paradigm (Haskell/OCaml/Scheme/…)
Metacomputations
Keywords: functional programming, metacomputations, program specialization, inverse programming
Description
The aim of this project is research and practical application of metacomputation techniques such as partial evaluation, supercompilation, distillation, and inverse programming.
Actual topics/projects:
- On-the-fly specialization/SC as a plugin for IDE
Goal: implement high-level specialization for some mainstream language as a plugin for IDE - Enrich Haskell^{-1} approach with miniKanren interleaving and compare with existing miniKanren implementations
- DSL compiler generation
Goal: automatically generate a compiler from the DSL implementation - Machine code specialization
Short-term goal: enrich and reimplement approach from the paper to tiny subsect of X86 generated by training compiler for Lama - [research] Trace-based Just-in-Time Type Specialization for Dynamic Languages
- [research] Just-in-Time Value Specialization
- [research] Representation-Based Just-In-Time Specialization and the Psyco Prototype for Python
- [research] Guided just-in-time specialization
- [research] Optimizing Matlab through Just-In-Time Specialization
- [long-term] Framework for semantics-based program/infrastructure generation
Knowledge in the following areas would be a plus:
- Basic knowledge in programming languages theory
- Basic knowledge in programming languages formal semantics
- Experience with functional programming paradigm (Haskell/OCaml/Scheme/…)
- Some knowledge in automatic program transformation and generation