<div dir="ltr"><div>Hi Nagaraju,<br></div><div><br></div><div>Few suggestions split this into following steps.</div><div><br></div><div>1/ DAG Legalization : Custom lower the instruction (branch in your case) appropriately in legalization to target specific DAG nodes and glue the nodes together which you want scheduler should schedule together.</div><div> </div><div>2/ Instruction Selection : Define patterns to match the custom DAG nodes.</div><div class="gmail_extra"><br></div><div class="gmail_extra">Thus actual decision of creating multiple instruction is taken care by legalizer and selection phase is dump which does pattern matching over whatever DAG is</div><div class="gmail_extra">feeded to it. </div><div class="gmail_extra"><br></div><div class="gmail_extra">Thanks,</div><div class="gmail_extra">Jatin</div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Mar 2, 2018 at 4:39 PM, Nagaraju Mekala via llvm-dev <span dir="ltr"><<a href="mailto:llvm-dev@lists.llvm.org" target="_blank">llvm-dev@lists.llvm.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi All,<br>
<br>
   I am working on a target which requires to generated two<br>
instructions for a single branch instruction.<br>
ex:<br>
   imm 1<br>
   br r4,0xabcd<br>
   branch address is 0x1abcd, imm has the upper 16 bits and br has<br>
lower 16 bits.<br>
<br>
  Can anyone let me know how to write these kind of patterns in the<br>
InstrInfo.td file.<br>
<br>
Thanks in Advance,<br>
Nagaraju<br>
______________________________<wbr>_________________<br>
LLVM Developers mailing list<br>
<a href="mailto:llvm-dev@lists.llvm.org">llvm-dev@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/<wbr>mailman/listinfo/llvm-dev</a><br>
</blockquote></div><br></div></div>