<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<style type="text/css" style="display:none;"><!-- P {margin-top:0;margin-bottom:0;} --></style>
</head>
<body dir="ltr">
<div id="divtagdefaultwrapper" style="font-size:12pt;color:#000000;font-family:Calibri,Helvetica,sans-serif;" dir="ltr">
<p>Looks good to me.</p>
<p><br>
</p>
<p>Reviewed-by: Neha Bhende <bhenden@vmware.com></p>
<p><br>
</p>
<div id="Signature">
<div id="divtagdefaultwrapper" style="font-size: 12pt; color: rgb(0, 0, 0); background-color: rgb(255, 255, 255); font-family: Calibri, Arial, Helvetica, sans-serif, Helvetica, EmojiFont, "Apple Color Emoji", "Segoe UI Emoji", NotoColorEmoji, "Segoe UI Symbol", "Android Emoji", EmojiSymbols;">
<p>Regards,</p>
<p>Neha<br>
</p>
</div>
</div>
</div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> mesa-dev <mesa-dev-bounces@lists.freedesktop.org> on behalf of Brian Paul <brianp@vmware.com><br>
<b>Sent:</b> Friday, November 10, 2017 6:40:26 PM<br>
<b>To:</b> mesa-dev@lists.freedesktop.org<br>
<b>Subject:</b> [Mesa-dev] [PATCH] svga: issue debug warning for unsupported two-sided stencil state</font>
<div> </div>
</div>
<div class="BodyFragment"><font size="2"><span style="font-size:10pt;">
<div class="PlainText">We only have a single stencil read mask and write mask.  Issue a<br>
warning if different front/back values are used.  The Piglit<br>
gl-2.0-two-sided-stencil test hits this.<br>
---<br>
 src/gallium/drivers/svga/svga_pipe_depthstencil.c | 15 +++++++++++++++<br>
 1 file changed, 15 insertions(+)<br>
<br>
diff --git a/src/gallium/drivers/svga/svga_pipe_depthstencil.c b/src/gallium/drivers/svga/svga_pipe_depthstencil.c<br>
index 1b62290..e5caa4b 100644<br>
--- a/src/gallium/drivers/svga/svga_pipe_depthstencil.c<br>
+++ b/src/gallium/drivers/svga/svga_pipe_depthstencil.c<br>
@@ -172,6 +172,21 @@ svga_create_depth_stencil_state(struct pipe_context *pipe,<br>
 <br>
       ds->stencil_mask      = templ->stencil[1].valuemask & 0xff;<br>
       ds->stencil_writemask = templ->stencil[1].writemask & 0xff;<br>
+<br>
+      if (templ->stencil[1].valuemask != templ->stencil[0].valuemask) {<br>
+         pipe_debug_message(&svga->debug.callback, CONFORMANCE,<br>
+                            "two-sided stencil mask not supported "<br>
+                            "(front=0x%x, back=0x%x)",<br>
+                            templ->stencil[0].valuemask,<br>
+                            templ->stencil[1].valuemask);<br>
+      }<br>
+      if (templ->stencil[1].writemask != templ->stencil[0].writemask) {<br>
+         pipe_debug_message(&svga->debug.callback, CONFORMANCE,<br>
+                            "two-sided stencil writemask not supported "<br>
+                            "(front=0x%x, back=0x%x)",<br>
+                            templ->stencil[0].writemask,<br>
+                            templ->stencil[1].writemask);<br>
+      }<br>
    }<br>
    else {<br>
       /* back face state is same as front-face state */<br>
-- <br>
1.9.1<br>
<br>
_______________________________________________<br>
mesa-dev mailing list<br>
mesa-dev@lists.freedesktop.org<br>
<a href="https://urldefense.proofpoint.com/v2/url?u=https-3A__lists.freedesktop.org_mailman_listinfo_mesa-2Ddev&d=DwIGaQ&c=uilaK90D4TOVoH58JNXRgQ&r=U9C05uEFArICiTQ6FqFIgVCB-YGE5G2JTThVEccv_Ec&m=G0jOYq_LoVonAPIAMBNujnLcGheNLWedG3WtYO3mbn0&s=QluX83Fb70cz1E8pS8V7mR4zpiIvPP-mO6XYaN-D7bU&e=">https://urldefense.proofpoint.com/v2/url?u=https-3A__lists.freedesktop.org_mailman_listinfo_mesa-2Ddev&d=DwIGaQ&c=uilaK90D4TOVoH58JNXRgQ&r=U9C05uEFArICiTQ6FqFIgVCB-YGE5G2JTThVEccv_Ec&m=G0jOYq_LoVonAPIAMBNujnLcGheNLWedG3WtYO3mbn0&s=QluX83Fb70cz1E8pS8V7mR4zpiIvPP-mO6XYaN-D7bU&e=</a><br>
</div>
</span></font></div>
</body>
</html>