<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Feb 17, 2016 at 9:28 AM, Kristian Høgsberg <span dir="ltr"><<a href="mailto:krh@bitplanet.net" target="_blank">krh@bitplanet.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">On Tue, Feb 16, 2016 at 11:36 PM, Jose Fonseca <<a href="mailto:jfonseca@vmware.com">jfonseca@vmware.com</a>> wrote:<br>
> On 16/02/16 22:19, Brian Paul wrote:<br>
>><br>
>> On 02/16/2016 02:41 PM, Dave Airlie wrote:<br>
>>><br>
>>> On 17 February 2016 at 04:39, Jason Ekstrand <<a href="mailto:jason@jlekstrand.net">jason@jlekstrand.net</a>><br>
>>> wrote:<br>
>>>><br>
>>>> So, we just pushed a branch containing a Vulkan driver.  Naturally, we<br>
>>>> would like to incorporate that driver into the upstream mesa tree.<br>
>>>> While<br>
>>>> we work on upstreaming the prerequisites in NIR and the i965 back-end<br>
>>>> compiler, there is a question that needs answering:  Where do we put it?<br>
>>>><br>
>>>> The Vulkan driver challenges the tree-like nature of the way mesa is<br>
>>>> currently organized.  We now have two drivers that share a lot of the<br>
>>>> same<br>
>>>> underlying hardware-specific code (compiler and ISL) but target<br>
>>>> different<br>
>>>> APIs and no gallium-like middle layer to hide behind.  Obviously, we<br>
>>>> don't<br>
>>>> want to put a Vulkan driver in src/mesa/drivers/dri/i965.  If we start a<br>
>>>> src/vulkan directory, we don't really want to put the shared parts into<br>
>>>> src/vulkan/intel.  Where should we put the Intel-specific but<br>
>>>> API-agnostic<br>
>>>> bits?  In particular, we need a place to put ISL and the back-end<br>
>>>> compiler.<br>
>>>> We don't want to deal with the headaches of making a public API and<br>
>>>> keeping<br>
>>>> it stable, so they need to live somewhere in the mesa tree.<br>
>>>><br>
>>>> In my personal opinion, the best thing to do is probably to add a<br>
>>>> src/intel<br>
>>>> folder with subfolders for vulkan, isl, and the back-end compiler.  The<br>
>>>> src/mesa/drivers/dri/i965 folder would then basically be just the GL<br>
>>>> bits<br>
>>>> of the driver.  It does seem a little odd to have "intel" as a top-level<br>
>>>> source folder, but I can't come up with anything better.<br>
>>>><br>
>>>> Thoughts?  Opinions?  Favorite colors?<br>
>>><br>
>>><br>
>>> I don't think we'll get this right the first time, and when we<br>
>>> randomly decide to<br>
>>> change it we can just make poor Emil handle the fallout. :-P<br>
>>><br>
>>> Anyways,<br>
>>><br>
>>> src/intel works for me, also src/shed/intel, src/shared/intel,<br>
>>> src/drivers/intel<br>
>><br>
>><br>
>> I like src/shared/intel/ FWIW.<br>
>><br>
>> -Brian<br>
><br>
><br>
> Me too FWIW.  We could also consider putting all non-GL/Gallium/Vulkan<br>
> specific stuff in src/shared too, like src/util, nir, etc.<br>
<br>
</div></div>We do have a few pieces that are intel-specific that we'd want to<br>
share with the GL driver, so I don't feel that src/shared is<br>
necessarily the best place. I'd prefer something like<br>
src/intel/isl, src/intel/compiler, src/intel/genxml and<br>
src/intel/vulkan. You could say that we should put out intel compiler<br>
backend in src/compiler/intel and perhaps the vulkan API in<br>
src/vulkan/intel, but the other pieces are intel specific helper<br>
libraries that don't really fit under any other umbrella.<br></blockquote><div><br></div><div>Also, given the complete lack of other Vulkan drivers, splitting the pieces into src/vulkan/intel and src/compiler/intel and src/shared/isl would create two folders (src/shared and src/vulkan) that each have only contain intel-specific subdirectory.  We can, of course, make that split if it seems useful, but at present it seems like src/intel would be simpler.<br></div><div>--Jason<br></div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<span class="HOEnZb"><font color="#888888"><br>
Kristian<br>
</font></span><span class="im HOEnZb"><br>
> But like Dave said, we can always tweak these things later.<br>
><br>
> Congrats on getting 0-day Vulkan support BTW!<br>
><br>
> Jose<br>
><br>
</span><div class="HOEnZb"><div class="h5">> _______________________________________________<br>
> mesa-dev mailing list<br>
> <a href="mailto:mesa-dev@lists.freedesktop.org">mesa-dev@lists.freedesktop.org</a><br>
> <a href="https://lists.freedesktop.org/mailman/listinfo/mesa-dev" rel="noreferrer" target="_blank">https://lists.freedesktop.org/mailman/listinfo/mesa-dev</a><br>
</div></div></blockquote></div><br></div></div>