morganstanley / hobbes

A language and an embedded JIT compiler
http://hobbes.readthedocs.io/
Apache License 2.0
1.16k stars 105 forks source link

Custom x86 backend resource usage for very large programs #307

Closed kthielen closed 4 years ago

kthielen commented 4 years ago

When compiling/encoding very large programs with the custom x86 backend (in hobbes/mc), we use more memory than necessary by storing liveness at each program point. Instead, we should store liveness just at join points in the control flow graph and interpolate within basic blocks.

Also for very large programs, where variable counts exceed int32 representation in the interference bit matrix, we need to raise an error on truncation rather than silently truncating (and losing interference information). Also to allow such programs to be compiled, we should widen the var set index type to 64 bits.

These issues are both fixed by this PR: https://github.com/Morgan-Stanley/hobbes/pull/306

kthielen commented 4 years ago

For some reason, I can't assign this to myself, but I did resolve it in that PR.

This isn't a new feature, but addresses some scaling issues encountered with very large programs sent through this alternative backend.

chenkai036 commented 4 years ago

Perhaps it's due to the 'Triage' role, please have another try.

kthielen commented 4 years ago

I'm not sure why it is, when I click on "Assignees" it opens a dropdown window with a circular "loading" indicator that never changes. It doesn't tell me I can't do it, it just appears to get stuck.

Weird.