miri icon indicating copy to clipboard operation
miri copied to clipboard

in-tree serverless priroda

Open oli-obk opened this issue 3 years ago • 3 comments

Maintaining and using https://github.com/oli-obk/priroda is cumbersome.

  1. Breaks all the time when miri changes
  2. Requires a server backend to drive the HTML UI
  3. Need to use miri as a library and extract all kinds of possibly private data

So, my proposal is to rewrite priroda from scratch, but this time in-tree here.

  1. Get miri to compile to wasm and create a demo
  2. Add an API to the miri lib for debugger style usage. Initially this is just the stepper API wrapped
  3. Add a wasm project called priroda to this repo that renders the current state and drives the miri API just like original priroda did, but this time without the server

oli-obk avatar Oct 18 '22 12:10 oli-obk

I don't think the current priroda inherently depends on being a server, but it does require running rustc on a separate thread from the ui. Using wasm won't remove this requirement no matter how much you rewrite. By the way note that priroda already has the rustc driver and the http server driving the ui relatively separated. The http server side submits commands to the rustc driver and receives the result. This combined makes me think that a gradual change rather than a from the ground up rewrite would be more effective.

bjorn3 avatar Oct 18 '22 12:10 bjorn3

Ah yes, I completely forgot about this, thanks! So maybe the first step is to move priroda over here and update it and then keep it updated by building it together with miri, even in the rustc repo

oli-obk avatar Oct 18 '22 12:10 oli-obk

My concern here is maintenance cost, but if the development of the rest of Miri doesn't have to care much about the priroda part then that seems fine for me.

RalfJung avatar Oct 19 '22 20:10 RalfJung