<div dir="ltr">Tim,<div><br></div><div><span style="font-family:arial,sans-serif;font-size:13px">> This is because of the predicate and flag-setting operands (usually</span><br style="font-family:arial,sans-serif;font-size:13px">
<span style="font-family:arial,sans-serif;font-size:13px">> imm:14 and reg:0)? If so, couldn't you count from the back rather than</span><br style="font-family:arial,sans-serif;font-size:13px"><span style="font-family:arial,sans-serif;font-size:13px">> the front of the list? Or is there some even more evil mangling going</span><br style="font-family:arial,sans-serif;font-size:13px">
<span style="font-family:arial,sans-serif;font-size:13px">> on?</span><br></div><div><span style="font-family:arial,sans-serif;font-size:13px"><br></span></div><div>I tried counting from the top and from the bottom and there doesn't seem</div>
<div>to be any viable general approach. I'll look into it in more detail tomorrow.</div><div><br></div><div><span style="font-family:arial,sans-serif;font-size:13px">> We may need an umpire soon (or pistols at dawn?). I took a stab at the</span><br style="font-family:arial,sans-serif;font-size:13px">
<span style="font-family:arial,sans-serif;font-size:13px">> one-instruction-to-rule-them-</span><span style="font-family:arial,sans-serif;font-size:13px">all approach (in the MC layer so far)</span><br style="font-family:arial,sans-serif;font-size:13px">
<span style="font-family:arial,sans-serif;font-size:13px">> over the weekend</span><br></div><div class="gmail_extra"><br></div><div class="gmail_extra">Good for you. To be clear, I have nothing against the unified representation</div>
<div class="gmail_extra">as long as the changes are confined to the MC layer. If this affects any layer</div><div class="gmail_extra">above, it's wrong to do it.</div><div class="gmail_extra"><br></div><div class="gmail_extra">
Mihai</div><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Aug 19, 2013 at 5:43 PM, Tim Northover <span dir="ltr"><<a href="mailto:t.p.northover@gmail.com" target="_blank">t.p.northover@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Mihai,<br>
<div class="im"><br>
> I found a way to avoid having a big switch that converts opcodes between ri<br>
> and rii. Basically, I am assigning all the rii instructions to a new<br>
> DecoderNamespace.<br>
<br>
</div>Hmm. Interesting approach.<br>
<br>
We may need an umpire soon (or pistols at dawn?). I took a stab at the<br>
one-instruction-to-rule-them-all approach (in the MC layer so far)<br>
over the weekend: <a href="http://llvm-reviews.chandlerc.com/D1432" target="_blank">http://llvm-reviews.chandlerc.com/D1432</a><br>
<div class="im"><br>
> Now, surprisingly I am having problems with step 1!<br>
> Although the two immediates are always the final inputs, they are not the<br>
> final MCOperands, nor the final immediate MCOperands.<br>
<br>
</div>This is because of the predicate and flag-setting operands (usually<br>
imm:14 and reg:0)? If so, couldn't you count from the back rather than<br>
the front of the list? Or is there some even more evil mangling going<br>
on?<br>
<br>
Cheers.<br>
<span class="HOEnZb"><font color="#888888"><br>
Tim.<br>
</font></span></blockquote></div><br></div></div>