<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Mon, Jan 11, 2016 at 3:43 PM, Chad Versace <span dir="ltr"><<a href="mailto:chad.versace@intel.com" target="_blank">chad.versace@intel.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">There are two sets of very different json patchsets on the list. Each<br>
has advantages and disadvantages.<br>
<br>
Dylan's patchset duplicates a small amount of code. And it doesn't teach<br>
wflinfo to print any additional info, such as GLX or EGL specific info.<br>
However, the patchset is short, sweet, has no major flaw, and is<br>
the correct approach for what he wished to accomplish: teach wflinfo to<br>
print its current output in a new format, json.<br>
<br>
Having json output makes Dylan's life easier as a Piglit developer, and<br>
the sooner he can get json the better. So I'm inclined to expedite<br>
Dylan's patchset and merge it soon, pending fixes.<br>
<br>
Frank's patchset adds platform-specific info the wflinfo's output, which<br>
is a feature it really needs. And the code for the platform-specific<br>
info rightly belongs in core waffle, which the patchset gets right.<br>
However, the patchset is much larger, needs lots more review, and needs<br>
to undergo some API changes.<br>
<br>
In other words, Frank's patches will take more time to land, and Dylan's<br>
are nearly ready to land as-is. And I don't want to artificially stall<br>
Dylan's Piglit work.<br>
<br>
I've decided my preferred format for wflinfo's json output. If the<br>
format is acceptable to everyone, then I want to see Dylan fixup<br>
patch 4/4 of his series and resubmit.<br>
<br>
I've been taking notes on Frank's patchset, but won't have time to<br>
provide real feedback until Tuesday (tomorrow) morning.<br>
<br>
<br>
JSON Format<br>
-----------<br>
Below is the json format I prefer. Is this acceptable to everyone? Did I<br>
underspecify the format?<br>
<br>
The major things I considered when deciding the format are:<br>
  1. Keep it simple.<br>
  2. Explicit is better than implicit.<br>
  3. Make life easy for existing wflinfo parsers<br>
     that wish to begin consuming the json. That means existing keys and<br>
     values should closely resemble eachother, and preferably be<br>
     identical.<br>
<br>
Definition:<br>
  * All key names are lower case, for consistency.<br>
  * Key names use ' ', not '-' nor '_', as the separator. This is<br>
    consistent with wflinfo's current output and glxinfo's output.<br>
  * For existing keys in wflinfo's current output, the JSON key names<br>
    should match modulo case.<br>
  * For existing values in wflinfo's current output, the JSON value<br>
    should be identical.<br>
  * The "opengl" table contains all info specific to the OpenGL context.<br>
    That includes GLSL info, as that is a property of the OpenGL<br>
    context.<br>
<br>
  {<br>
    "waffle": {<br>
      "platform": String,<br>
      "api": String,<br>
    },<br>
    "opengl": {<br>
      "vendor string": String,<br>
      "renderer string": String,<br>
      "version string": String,<br>
      "shading language version string": String,<br>
      "extensions": [String],<br>
    },<br>
    <if platform uses EGL><br>
    "egl": {<br>
      "vendor string": String,<br>
      "version string": String,<br>
      "version": [Int, Int],<br>
      "extensions": [String],<br>
      "client apis": [String],<br>
    },<br>
    <endif><br>
    <if platform is GLX><br>
    "glx": {<br>
      "server": {<br>
        "vendor string": String,<br>
        "version string": String,<br>
        "extensions string": [String],<br>
      },<br>
      "client": {<br>
        "vendor string": String,<br>
        "version string": String,<br>
        "extensions": [String],<br>
      }<br>
      "common": {<br>
        "version": [Int, Int],<br>
        "extensions": [String],<br>
      },<br>
    },<br>
    <endif><br>
  }<br>
<br>
The GLX and EGL tables can be extended in the future to contain<br>
additional information, such as visual configs.<br></blockquote><div><br></div><div>Your JSON format is fine with me.</div><div><br></div><div>So if I understand, you're still interested in my patches after landing Dylan's?  If so I'll just wait until all review comments are in (take your time) and then prepare v2.  Thanks.</div></div><br></div></div>