emit vs. visit in LIR interface
Deneau, Tom
tom.deneau at amd.com
Thu Oct 17 12:40:12 PDT 2013
Say you've defined a new XxxNode and a LoweredXxxNode version also.
In the generate method for the LoweredXxxNode, what determines whether one should
a) define a emitXxx in the LIRGenerator interface, do the parsing work in the LoweredXxxNode.generate method itself, and then call gen.emitXXX (like for example the say BitCountNode.generate works)
b) define a visitXxx routine as part of the LIRGenerator interface, and the LoweredXxxNode.generate basically just calls gen.visitXxx(LoweredXxxNode) and do the real work in the visitXxx (like for example VisitCompareAndSwap)
-- Tom
More information about the graal-dev
mailing list