RFR(S): 8077843: adlc: allow nodes that use TEMP inputs in expand rules.

Vladimir Kozlov vladimir.kozlov at oracle.com
Fri Apr 17 00:27:53 UTC 2015


Here is what Tom R said during review of TEMP implementation:

 >> 3. In formssel.cpp you restricted TEMP usage only to instruction
 >> with match rule, why? What about effect()?:
 >> + bool InstructForm::has_temps() {
 >> +   if (_matrule) {
 >
 >TEMP isn't allowed for instructions which don't have match rules.  The 
 >reason is that if an instruct doesn't have a match rule the only way 
 >it can be constructed is by an expand rule.  expand rules look like 
 >explicit invocations of encodings but TEMPs are synthetic so you can't 
 >properly write an expand rule to work with TEMP.  I mean you could 
 >make it work but I decided not to support it.  I'll make this more 
 >explicit.

So I am not sure that just removing the assert will be enough. Please, 
verify.

Regards,
Vladimir

On 4/15/15 6:08 AM, Lindenmaier, Goetz wrote:
> Hi,
>
> I have a tiny fix that allows nodes that use TEMP inputs / TEMP effect in
> expand rules.
>
> Currently an assertion fires if you do so.
> This is harmless, though, as the TEMP node is added in the Expand() of the used node,
> which is called by the Expand() of the node being expanded.
> Probably the assertion was meant for the node being expanded.
>
> The change simply removed the assertion.
>
> Please review this change.  I please need a sponsor.
> http://cr.openjdk.java.net/~goetz/webrevs/8077843-adlcTEMP/webrev.01/
>
> I need this feature for a change I intend to do in the ppc.ad file.
>
> Best regards,
>    Goetz.
>


More information about the hotspot-dev mailing list