On 06/27/14 08:26, David Malcolm wrote:
Yeah, that's probably my primary concern here. The patch kit is going
to be big (currently at 133 patches [1]), and so I want something that
we can sanely keep track of, that is easily reviewable, and will be as
easy as possible to merge.
i.e. I don't want to get bogged down in a big revamp of the rest of the
RTL interface if I can help it.
Precisely. After revamping the objects at the toplevel of the insn
chain, we can evaluate what project makes the most sense to tackle.
If it's desirable to actually make insns be a separate class, I'm
considering the goal of making the attributes of insns become actual
fields, something like:
I think having the toplevel objects in the insn chain as a separate
class makes sense. My biggest concerns are a variety of implementation
details like is there code that wants to use the various rtl walkers on
those toplevel objects.
Which (and I hate to say it) makes me wonder if this is a two step
process. First step is to have the subclass style implementation. Then
we look deeper at what would need to change to break those toplevel
objects out into a distinct class. In theory if we do things right, we
leverage the new types and static checking to catch all the "don't
assume the toplevel objects in the insn chain are rtxs" issues.
Two stage also gives others a chance to chime in if they're aware of
good reasons not to make the change.
But even if we don't get there and simply keep insns as subclasses of
rtx, I think that having insn-handling code marked as such in the
type-system is a win from a readability standpoint.
Absolutely.
Hope these ideas sound sane
They do. I think we're very much on the same page here.
Jeff