<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/91617>91617</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
[HLSL] Design/Spec a library for performing work out of process (example: compiling a shader)
</td>
</tr>
<tr>
<th>Labels</th>
<td>
HLSL
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
coopp
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
coopp
</td>
</tr>
</table>
<pre>
The current DXC compiler library is an in process component. Desire has been expressed to have an out of process solution for compiling shaders. This solution should perform compilation in a reusable host process that is connected to by the c-style compiler library.
# Design a reliable/reusable IPC mechanism
The llvm-project encourages building reusable libraries (called support libraries) that can be connected to together to create compelling clang tooling. Clang itself is constructed using these libraries. Each support library is individually tested. IPC logic seems like a good fit to be added to the support library set of features.
A design needs to be spec'd out and run through a design meeting with the team. This will bottom out on the details around standing up such a system and implemented in another task Issue #90782 .
Thoughts
* Investigate ORC, an existing jit compilation system. Perhaps there is some code reuse there that can be leveraged
* Keep the design simple and to the point. There is no need to create a full featured library.
Requirements
* Reusable library in design
* Ensure that if one process goes down/crashes that proper cleanups occur
* Must be cross platform in design. ( linux has fork( ), Windows does not ).
* Thoughts on test approach
* documentation is written and located where other support library docs live
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJxsVU1z4zYM_TX0BbMam44T--BDmqynO91Od3Yz014hEpa4oUiVAJP433dIyx_J9pJYEr4e8B6AzK4LRFu1-k1pbWIcR6W1Wj3OMEsf07a-mrXRHrZPPYHJKVEQePznAUwcRucpgXdtwnQAx4ABXIAxRUPM1SIGCtLAI7FLBD0ytEQB6G1MxEwWJEKPL1RcYxaI-7M7R5_FxQD7mKZsLnTAPVpK3MBT766MuI_ZWxgp7WMaJnusn1wAhESZsfUEfWQ555AepRRuYghk5FhPewApYD-xHDz9ArRR80c1v5_-6mUF1x1zeFdyKL07p_vy7QEGMj0Gx8PRp3TS-5fh05jiTzICFEzMCTt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