[prev in list] [next in list] [prev in thread] [next in thread] 

List:       mesa3d-dev
Subject:    Re: [Mesa-dev] OpenGL and OpenCL on top of D3D12
From:       Jose Fonseca <jfonseca () vmware ! com>
Date:       2020-03-26 14:42:17
Message-ID: BL0PR05MB5026953128DCB52D02032B10B6CF0 () BL0PR05MB5026 ! namprd05 ! prod ! outlook ! com
[Download RAW message or body]

Hi,

This is very interesting work from my POV.  It's definitely great to have more \
members in Mesa community interested in Windows, and is exciting to see renewed \
interest in OpenGL from Microsoft.  There are always very difficult corner cases when \
translating between one graphics API to another, but given enough dedication, I see \
no reason why one can't achieve an OpenGL implementation on top of D3D12 that gets \
the job well done on virtually all the important uses cases.

Regarding the WGL headers, please give us a shout if you notice anything obviously \
wrong in the reversed engineered interfaces.  I've been away from Mesa dev lately, \
but I'll do my best to keep an eye on this work.  It would be helpful if you could \
explicitly CC @jrfonseca on changes specific to WGL headers / state tracker.  Thanks.

Jose

________________________________
From: mesa-dev <mesa-dev-bounces@lists.freedesktop.org> on behalf of Gert Wollny \
                <gert.wollny@collabora.com>
Sent: Tuesday, March 24, 2020 16:38
To: Mesa ML <mesa-dev@lists.freedesktop.org>
Subject: [Mesa-dev] OpenGL and OpenCL on top of D3D12

Dear Mesa developers,

Today, we at Collabora together with Microsoft have announced a new
project based on Mesa: OpenGL and OpenCL on top of Microsoft's D3D12.
You can find the full  announcements here:

https://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.collabora.com%2F \
news-and-blog%2Fnews-and-events%2Fintroducing-opencl-and-opengl-on-directx.html&amp;da \
ta=02%7C01%7Cjfonseca%40vmware.com%7C1fbe982d5e534ff7eb6308d7d011dac7%7Cb39138ca3cee4b \
4aa4d6cd83d9dd62f0%7C0%7C0%7C637206647447892216&amp;sdata=TGEvmkS73dffnLz%2BEgHSmN3QQ%2FTRPRoza%2ByySEc4s88%3D&amp;reserved=0


https://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdevblogs.microsoft.c \
om%2Fdirectx%2Fin-the-works-opencl-and-opengl-mapping-layers-to-directx&amp;data=02%7C \
01%7Cjfonseca%40vmware.com%7C1fbe982d5e534ff7eb6308d7d011dac7%7Cb39138ca3cee4b4aa4d6cd \
83d9dd62f0%7C0%7C0%7C637206647447892216&amp;sdata=qDVwOUZjteHtCaWmkbSiyka7Fc1ZJyTCMXS7q8pN0Ec%3D&amp;reserved=0


How does this affect Mesa?

First of all, we intend to contribute this work into upstream Mesa.

The OpenGL work is similar to what Zink does with Vulkan, and will use
some comparable approaches for the emulation of features, hence there
will be some obvious opportunities for code-sharing with Zink.

The OpenCL support is not using the Clover runtime, but instead is a
standalone runtime that shares the NIR-to-DXIL compiler that we
contribute to Mesa and that is also used by above OpenGL layer.

As we are using spirv-to-nir in our OpenCL compiler, we have
implemented some missing OpenCL-specific features there as well. In
addition, we are also carrying some out-of-tree changes from other mesa
contributors, where we also contribute reviews of in order to help them
land.

Our work also includes contributing, improving, and maintaining the CI
for Windows, to be run on a variety of supported Windows targets.
Currently, Collabora is providing a Windows GitLab CI runner in order
to run our builds. We are looking into integrating this into fd.o's
general fleet of shared runners.

A high-performance DXGI libgl-target/winsys is also in the works, so we
can render directly into Windows' compositor surfaces. In theory, and
as a benefit to the wider Mesa community, other hardware driver could
be ported to support rendering into those surfaces as well.

As part of this work and thanks to Microsoft's support, the WGL header
files are being re-licensed as MIT, so we can reuse these original
headers rather than a reverse-engineered copy. Patches for this will
follow soon.

A dump of the code in its current state can be found here:
https://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgitlab.freedesktop.o \
rg%2Fkusma%2Fmesa%2F-%2Ftree%2Fmsclc-d3d12&amp;data=02%7C01%7Cjfonseca%40vmware.com%7C \
1fbe982d5e534ff7eb6308d7d011dac7%7Cb39138ca3cee4b4aa4d6cd83d9dd62f0%7C0%7C0%7C63720664 \
7447892216&amp;sdata=iozk7RT5jnXweFeM8dlcizCvs020obG0aPZHReVAMlw%3D&amp;reserved=0 \
and we intend to upstream this code by breaking it into independent MRs shortly.

We hope you're all as excited about this as we are!

Gert Wollny, on behalf of the Microsoft development team (Bill
Kristiansen and Jesse Natalie) and the Collabora development team
(Boris Brezillon, Daniel Stone, Elie Tournier, Erik Faye-Lund, Louis-
Francis Ratté-Boulianne)


_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.freedesktop.or \
g%2Fmailman%2Flistinfo%2Fmesa-dev&amp;data=02%7C01%7Cjfonseca%40vmware.com%7C1fbe982d5 \
e534ff7eb6308d7d011dac7%7Cb39138ca3cee4b4aa4d6cd83d9dd62f0%7C0%7C0%7C637206647447892216&amp;sdata=RLRF0ByyMp9HU0EdplrenaAU6s1ew9oIQtrn%2BOd8Ym4%3D&amp;reserved=0



[Attachment #3 (text/html)]

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} \
</style> </head>
<body dir="ltr">
<div style=""><font color="#000000" face="Calibri, Helvetica, sans-serif"><span \
style="font-size: 12pt;">Hi,</span></font></div> <div style=""><font color="#000000" \
face="Calibri, Helvetica, sans-serif"><span style="font-size: 12pt;"><br> \
</span></font></div> <div style=""><font color="#000000" face="Calibri, Helvetica, \
sans-serif"><span style="font-size: 12pt;">This is very interesting work from my \
POV.&nbsp; It's </span>definitely<span style="font-size: 12pt;">&nbsp;great to have \
more members in Mesa community interested in Windows, and is exciting to see renewed \
interest in OpenGL from Microsoft.&nbsp; There are always very difficult corner cases \
when </span>translating<span style="font-size: 12pt;">&nbsp;between one graphics API \
to another, but given enough dedication, I see no reason why one can't achieve an \
OpenGL implementation on top of D3D12 that gets the job well done on virtually all \
the important uses  cases.</span></font><br>
</div>
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: \
rgb(0, 0, 0);"> <br>
</div>
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: \
rgb(0, 0, 0);"> Regarding the WGL headers, please give us a shout if you notice \
anything obviously wrong in the reversed engineered interfaces.&nbsp; I've been away \
from Mesa dev lately, but I'll do my best to keep an eye on this work.&nbsp; It would \
be helpful if you could explicitly  CC @jrfonseca on changes specific to WGL headers \
/ state tracker.&nbsp; Thanks.</div> <div style="font-family: Calibri, Helvetica, \
sans-serif; font-size: 12pt; color: rgb(0, 0, 0);"> <br>
</div>
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: \
rgb(0, 0, 0);"> Jose</div>
<div>
<div id="appendonsend"></div>
<div style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt; \
color:rgb(0,0,0)"> <br>
</div>
<hr tabindex="-1" style="display:inline-block; width:98%">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" color="#000000" \
style="font-size:11pt"><b>From:</b> mesa-dev \
&lt;mesa-dev-bounces@lists.freedesktop.org&gt; on behalf of Gert Wollny \
&lt;gert.wollny@collabora.com&gt;<br> <b>Sent:</b> Tuesday, March 24, 2020 16:38<br>
<b>To:</b> Mesa ML &lt;mesa-dev@lists.freedesktop.org&gt;<br>
<b>Subject:</b> [Mesa-dev] OpenGL and OpenCL on top of D3D12</font>
<div>&nbsp;</div>
</div>
<div class="BodyFragment"><font size="2"><span style="font-size:11pt">
<div class="PlainText">Dear Mesa developers,<br>
<br>
Today, we at Collabora together with Microsoft have announced a new<br>
project based on Mesa: OpenGL and OpenCL on top of Microsoft's D3D12.<br>
You can find the full&nbsp; announcements here:<br>
<br>
<a href="https://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.collabo \
ra.com%2Fnews-and-blog%2Fnews-and-events%2Fintroducing-opencl-and-opengl-on-directx.ht \
ml&amp;amp;data=02%7C01%7Cjfonseca%40vmware.com%7C1fbe982d5e534ff7eb6308d7d011dac7%7Cb \
39138ca3cee4b4aa4d6cd83d9dd62f0%7C0%7C0%7C637206647447892216&amp;amp;sdata=TGEvmkS73df \
fnLz%2BEgHSmN3QQ%2FTRPRoza%2ByySEc4s88%3D&amp;amp;reserved=0">https://nam04.safelinks. \
protection.outlook.com/?url=https%3A%2F%2Fwww.collabora.com%2Fnews-and-blog%2Fnews-and \
-events%2Fintroducing-opencl-and-opengl-on-directx.html&amp;amp;data=02%7C01%7Cjfonsec \
a%40vmware.com%7C1fbe982d5e534ff7eb6308d7d011dac7%7Cb39138ca3cee4b4aa4d6cd83d9dd62f0%7 \
C0%7C0%7C637206647447892216&amp;amp;sdata=TGEvmkS73dffnLz%2BEgHSmN3QQ%2FTRPRoza%2ByySEc4s88%3D&amp;amp;reserved=0</a><br>
 <br>
<a href="https://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdevblogs.mi \
crosoft.com%2Fdirectx%2Fin-the-works-opencl-and-opengl-mapping-layers-to-directx&amp;a \
mp;data=02%7C01%7Cjfonseca%40vmware.com%7C1fbe982d5e534ff7eb6308d7d011dac7%7Cb39138ca3 \
cee4b4aa4d6cd83d9dd62f0%7C0%7C0%7C637206647447892216&amp;amp;sdata=qDVwOUZjteHtCaWmkbS \
iyka7Fc1ZJyTCMXS7q8pN0Ec%3D&amp;amp;reserved=0">https://nam04.safelinks.protection.out \
look.com/?url=https%3A%2F%2Fdevblogs.microsoft.com%2Fdirectx%2Fin-the-works-opencl-and \
-opengl-mapping-layers-to-directx&amp;amp;data=02%7C01%7Cjfonseca%40vmware.com%7C1fbe9 \
82d5e534ff7eb6308d7d011dac7%7Cb39138ca3cee4b4aa4d6cd83d9dd62f0%7C0%7C0%7C6372066474478 \
92216&amp;amp;sdata=qDVwOUZjteHtCaWmkbSiyka7Fc1ZJyTCMXS7q8pN0Ec%3D&amp;amp;reserved=0</a><br>
 <br>
How does this affect Mesa? <br>
<br>
First of all, we intend to contribute this work into upstream Mesa. <br>
<br>
The OpenGL work is similar to what Zink does with Vulkan, and will use<br>
some comparable approaches for the emulation of features, hence there<br>
will be some obvious opportunities for code-sharing with Zink. <br>
<br>
The OpenCL support is not using the Clover runtime, but instead is a<br>
standalone runtime that shares the NIR-to-DXIL compiler that we<br>
contribute to Mesa and that is also used by above OpenGL layer.&nbsp; <br>
<br>
As we are using spirv-to-nir in our OpenCL compiler, we have<br>
implemented some missing OpenCL-specific features there as well. In<br>
addition, we are also carrying some out-of-tree changes from other mesa<br>
contributors, where we also contribute reviews of in order to help them<br>
land.<br>
<br>
Our work also includes contributing, improving, and maintaining the CI<br>
for Windows, to be run on a variety of supported Windows targets. <br>
Currently, Collabora is providing a Windows GitLab CI runner in order<br>
to run our builds. We are looking into integrating this into fd.o's<br>
general fleet of shared runners.<br>
<br>
A high-performance DXGI libgl-target/winsys is also in the works, so we<br>
can render directly into Windows' compositor surfaces. In theory, and<br>
as a benefit to the wider Mesa community, other hardware driver could<br>
be ported to support rendering into those surfaces as well.<br>
<br>
As part of this work and thanks to Microsoft's support, the WGL header<br>
files are being re-licensed as MIT, so we can reuse these original<br>
headers rather than a reverse-engineered copy. Patches for this will<br>
follow soon.<br>
<br>
A dump of the code in its current state can be found here:<br>
<a href="https://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgitlab.free \
desktop.org%2Fkusma%2Fmesa%2F-%2Ftree%2Fmsclc-d3d12&amp;amp;data=02%7C01%7Cjfonseca%40 \
vmware.com%7C1fbe982d5e534ff7eb6308d7d011dac7%7Cb39138ca3cee4b4aa4d6cd83d9dd62f0%7C0%7 \
C0%7C637206647447892216&amp;amp;sdata=iozk7RT5jnXweFeM8dlcizCvs020obG0aPZHReVAMlw%3D&a \
mp;amp;reserved=0">https://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fg \
itlab.freedesktop.org%2Fkusma%2Fmesa%2F-%2Ftree%2Fmsclc-d3d12&amp;amp;data=02%7C01%7Cj \
fonseca%40vmware.com%7C1fbe982d5e534ff7eb6308d7d011dac7%7Cb39138ca3cee4b4aa4d6cd83d9dd \
62f0%7C0%7C0%7C637206647447892216&amp;amp;sdata=iozk7RT5jnXweFeM8dlcizCvs020obG0aPZHReVAMlw%3D&amp;amp;reserved=0</a><br>
 and we intend to upstream this code by breaking it into independent<br>
MRs shortly.<br>
<br>
We hope you're all as excited about this as we are!<br>
<br>
Gert Wollny, on behalf of the Microsoft development team (Bill<br>
Kristiansen and Jesse Natalie) and the Collabora development team<br>
(Boris Brezillon, Daniel Stone, Elie Tournier, Erik Faye-Lund, Louis-<br>
Francis Ratté-Boulianne)<br>
<br>
<br>
_______________________________________________<br>
mesa-dev mailing list<br>
mesa-dev@lists.freedesktop.org<br>
<a href="https://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.freed \
esktop.org%2Fmailman%2Flistinfo%2Fmesa-dev&amp;amp;data=02%7C01%7Cjfonseca%40vmware.co \
m%7C1fbe982d5e534ff7eb6308d7d011dac7%7Cb39138ca3cee4b4aa4d6cd83d9dd62f0%7C0%7C0%7C6372 \
06647447892216&amp;amp;sdata=RLRF0ByyMp9HU0EdplrenaAU6s1ew9oIQtrn%2BOd8Ym4%3D&amp;amp; \
reserved=0">https://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.fr \
eedesktop.org%2Fmailman%2Flistinfo%2Fmesa-dev&amp;amp;data=02%7C01%7Cjfonseca%40vmware \
.com%7C1fbe982d5e534ff7eb6308d7d011dac7%7Cb39138ca3cee4b4aa4d6cd83d9dd62f0%7C0%7C0%7C6 \
37206647447892216&amp;amp;sdata=RLRF0ByyMp9HU0EdplrenaAU6s1ew9oIQtrn%2BOd8Ym4%3D&amp;amp;reserved=0</a><br>
 </div>
</span></font></div>
</div>
</body>
</html>



_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev

--===============1772514772==--

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic