<div dir="ltr">On 3 June 2013 06:38, Benjamin Thaut <span dir="ltr"><<a href="mailto:code@benjamin-thaut.de" target="_blank">code@benjamin-thaut.de</a>></span> wrote:<br><div class="gmail_extra"><div class="gmail_quote">
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div class="im">Am 01.06.2013 12:18, schrieb Benjamin Thaut:<br>

</div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
I've taken a look at core.simd and I have to say is unuseable. In a very<div><div class="h5"><br>
small test program I already found 3 bugs<br></div></div></blockquote></blockquote><div><br></div><div style>I've responded in the bugs, but I'll post here too.</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div><div class="h5">
1) Using debug symbols together with core.simd will cause a ICE<br>
<a href="http://d.puremagic.com/issues/show_bug.cgi?id=10224" target="_blank">http://d.puremagic.com/issues/<u></u>show_bug.cgi?id=10224</a></div></div></blockquote></blockquote><div><br></div><div style>Yup, this has bugged me a few times, but I hadn't pestered Walter yet.</div>
<div style><br></div><div style>I usually debug SIMD code with -O -release though, and I don't think -g is compatible with those flags anyway in DMD(?)</div><div style>I just use visual studio's asm debugging to see what's going on.</div>
<div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<div><div class="h5">
2) The STOUPS instruction is not correctly implemented:<br>
<a href="http://d.puremagic.com/issues/show_bug.cgi?id=10225" target="_blank">http://d.puremagic.com/issues/<u></u>show_bug.cgi?id=10225</a></div></div></blockquote></blockquote><div><br></div><div style>True.</div><div style>
I never use unaligned vectors ;)</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<div><div class="h5">
3) The XMM register allocation is catastrophic:<br>
<a href="http://d.puremagic.com/issues/show_bug.cgi?id=10226" target="_blank">http://d.puremagic.com/issues/<u></u>show_bug.cgi?id=10226</a></div></div></blockquote></blockquote><div><br></div><div style>What do you get when you remove the explicit mov's?</div>
<div style><pre class="" id="comment_text_2" style="font-size:medium;white-space:pre-wrap;width:50em;color:rgb(0,0,0)">    float4 result = [1,2,3,4];
    result = __simd(XMM.ADDPS, result, result);
    writefln("%s", result.array);</pre></div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div><div class="h5">
Whats the current state of core.simd? Is it still beeing worked on?<br>
Because it its current state its pretty much unuseable.<br></div></div></blockquote></blockquote><div><br></div><div style>I find it 'usable', but there are still some holes, and cases where it's not efficient.</div>
<div style>I've been working on std.simd (but was afk for the start of this year) mostly against GDC. Once I'm happy with the API and it's producing the correct code in GDC/LDC, then I planned to log a bunch of DMD bugs to get that up to scratch. But I needed a solid goal-post and units tests first..</div>
<div><br></div><div style>I'm back on std.simd now (although haven't had anywhere near as much time as I'd like lately). Hopefully show some significant progress soon.</div></div></div></div>