<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<body>
<div dir="auto">
<div dir="auto">Drive-by comment: I don't think you actually want to base any decisions an a vec4 architecture. Nearly every company in the graphics industry thought that was a good idea and designed vec4 processors. Over the course of the last 15 years or so they have all, one by one, realized that it was a bad idea and stopped doing it. Instead, they all parallelize the other way and their SIMD instructions and on scalar values across 8, 16, 32, or 64 invocations (vertices, pixels, etc.) Of the shader program.</div><div dir="auto"><br></div><div dir="auto">That isn't too say that Mesa is there wrong choice or that there aren't other reasons why SwiftShader would be a bad fit. However, I would recommend against making major architectural decisions for the sole reason that it allows you to repeat one of the biggest architectural mistakes that the graphics industry as a whole managed to make and is only recently (last 5 years) finally gotten over.</div><div dir='auto'><br></div>
<div id="aqm-original" style="color: black;">
<!-- body start -->
<div class="aqm-original-body">
<div style="color: black;">
<p style="color: black; font-size: 10pt; font-family: sans-serif; margin: 8pt 0;">On January 8, 2020 18:35:16 Luke Kenneth Casson Leighton <lkcl@lkcl.net> wrote:</p>
<blockquote type="cite" class="gmail_quote" style="margin: 0 0 0 0.75ex; border-left: 1px solid #808080; padding-left: 0.75ex;">
<div>(if responding on mesa-dev please do cc me to help preserve the thread, i am subscribed in digest mode, thanks)</div><div><br></div><div>the NLNet funding application documented here was successful:</div><a href="https://libre-riscv.org/nlnet_2019_amdvlk_port/">https://libre-riscv.org/nlnet_2019_amdvlk_port/</a><div><br></div><div>we therefore have money (direct payment of tax free, tax deductible donations from the NLNet Foundation into your bank account [1]) available for anyone, anywhere in the world, to help create a 3D MESA Vulkan compliant driver for a hybrid hard-soft GPU.</div><div><br></div><div>we considered starting from SwiftShader because it is, on initial inspection, close to what we want. we could hypothetically have added deep SIMD instructions, and the project would be 90% complete.</div><div><br></div><div>however when it comes to predication and to vector types such as vec2, vec3 and vec4, the infrastructure in SwiftShader is unable to cope. thus, if we add custom hardware opcodes which can accelerate vector-vector operations, SwiftShader would have been an extremely bad decision as it would be incapable of using such hardware without a drastic redesign.</div><div><br></div><div>hence the reason for choosing MESA, because NIR can retain that critical type information right up until it hits the hardware.</div><div><br></div><div>as you know, a hybrid CPU/GPU does not have a separate CPU and a separate GPU, they are *one and the same*.  therefore if starting from the Intel MESA driver or RADV, the initial work needed is to make the chosen base actually a *software* renderer, just like SwiftShader.</div><div><br></div><div>this is a desirable goal and it will be important to have the code be portable, unaccelerated, and run on at the minimum x86, and (later) the Libre SoC.</div><div><br></div><div>once that phase is completed, *then* we may move to adding custom accelerated opcodes (Transcendentals, YUV2RGB etc). bear in mind that these will be added *to the CPU*... because the CPU *is* the GPU.</div><div><br></div><div>to be absolutely clear: there will be no marshalling of GPU data or instructions, to be sent over to kernelspace IPC. the CPU will execute the accelerated opcode (e.g atan2) directly and immediately.</div><div><br></div><div>this is significantly simpler than standard GPUs, saving on power consumption and drastically simplifying debugging and application developnent.</div><div><br></div><div>if this is of interest please do get in touch, and feel free to ask questions.</div><div><br></div><div>best,</div><div><br></div><div>l.</div><div><br></div><div>[1] your accountant, with assistance from Bob Goudriaans, an International Tax Law Specialist and Director of NLNet, can help confirm that the payments from NLNet are considered charitable tax deductible donations... *to you*.  all the International Tax Agreements are in place and the documents available for inspection by your accountant.</div><div><br></div><br><br>-- <br>---<br>crowd-funded eco-conscious hardware: <a href="https://www.crowdsupply.com/eoma68" target="_blank">https://www.crowdsupply.com/eoma68</a><br><br>

<div>_______________________________________________</div>
<div>mesa-dev mailing list</div>
<div><a class="aqm-autolink aqm-autowrap" href="mailto:mesa-dev%40lists.freedesktop.org">mesa-dev@lists.freedesktop.org</a></div>
<div><a class="aqm-autolink aqm-autowrap" href="https://lists.freedesktop.org/mailman/listinfo/mesa-dev">https://lists.freedesktop.org/mailman/listinfo/mesa-dev</a></div>
<div><br></div>
</blockquote>
</div>
</div>
<!-- body end -->

</div><div dir="auto"><br></div>
</div></body>
</html>