New LLVM JIT Features

(Jackie Chan Fan) #1

Hi
I’m working on developing a Speculative compilation support in LLVM ORC JIT Infrastructure.

As LLVM ORC supports compiling in multiple backend threads, it would be effective if we compile the functions speculatively before they are called by the executing function. So when we request JIT to compile a function, JIT will immediately returns the function address for raw executable bits. This will greatly reduce the JIT latencies in modern multi-core machines. And also I’m working on designing a ORC in-place dynamic profiling support, by this JIT will automatically able to identify the hot functions, and compile it in higher optimization level to achieve good performance.

I’m proposing this project for GSoC 2019 under LLVM . It would be helpful to know how this new features are effective to swift language, so that I include your comments in “View from Clients” proposal section.

Thanks :)

1 Like
(Jackie Chan Fan) #2

Any thoughts?

(Gábor Sebestyén) #3

Well I'm wondering if it enables code hot swap like JVM can do with Java bytecode. It would be a huge advantage for server side developers so they can instantly try out their code changes without full restart.

1 Like
(Jackie Chan Fan) #4

Hi
Currently, There is no plan to add hot swapping, but I think it should not be that difficult to add. Once we get this feature on!

1 Like
(Spencer Kohan) #5

Hot-swapping would be huge for me as well. This would significantly streamline the development loop for interactive applications.

(Jordan Rose) #6

Tagging @akyrtzi as a GSoC contact.

(Jackie Chan Fan) #7

Any thoughts over this?