How to write up XXInstFormat.td?

Hi all,

  I have some troubles in writing XXInstFormat.td for my little backend.
I don't know how should I start writing up this file. Is there any
general rule? Thanks.

Regards,
chenwj

I suggest u grep how this file is used.
Since it is included in xxInstrInfo.td and this is its only use, we can conclude that this file does nothng more than defining some helper tablegen classes and we thus can totally move these definitions into xxInstrInfo.td and then remove XXInstFormat.td

Regards.

在 2013-2-6 下午4:52,“陳韋任 (Wei-Ren Chen)” <chenwj@iis.sinica.edu.tw>写道:

Besizes, XXInstFormat.td usually represents how ISA is grouped in the manual.

在 2013-2-7 上午12:31,“Triple Yang” <triple.yang@gmail.com>写道:

AFAIK, XXInstFormat.td define a few basic instruction format template
(group), and XXInstInfo.td define target instruction based on those template.
The problem is I am not sure how to define those template properly.

Regards,
chenwj