src/hotspot/share/adlc/archDesc.cpp
changeset 51078 fc6cfe40e32a
parent 47216 71c04702a3d5
child 59277 31272cef28e2
equal deleted inserted replaced
51077:9baa91bc7567 51078:fc6cfe40e32a
     1 //
     1 //
     2 // Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
     2 // Copyright (c) 1997, 2018, Oracle and/or its affiliates. All rights reserved.
     3 // DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     3 // DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     4 //
     4 //
     5 // This code is free software; you can redistribute it and/or modify it
     5 // This code is free software; you can redistribute it and/or modify it
     6 // under the terms of the GNU General Public License version 2 only, as
     6 // under the terms of the GNU General Public License version 2 only, as
     7 // published by the Free Software Foundation.
     7 // published by the Free Software Foundation.
   541       (!form->ideal_only())) {
   541       (!form->ideal_only())) {
   542     return;
   542     return;
   543   }
   543   }
   544 
   544 
   545   // Identify index position among ideal operands
   545   // Identify index position among ideal operands
   546   intptr_t    index     = _last_opcode;
   546   intptr_t index = _last_opcode;
   547   const char *indexStr  = node ? node->_opType : (char *) " ";
   547   const char *indexStr = node ? node->_opType : (char *) " ";
   548   index            = (intptr_t)_idealIndex[indexStr];
   548   index = (intptr_t)_idealIndex[indexStr];
   549   if (index == 0) {
   549   if (index == 0) {
   550     fprintf(stderr, "error: operand \"%s\" not found\n", indexStr);
   550     fprintf(stderr, "error: operand \"%s\" not found\n", indexStr);
   551     assert(0, "fatal error");
   551     assert(0, "fatal error");
   552   }
   552   }
   553 
   553 
       
   554   if (node == NULL) {
       
   555     fprintf(stderr, "error: node is NULL\n");
       
   556     assert(0, "fatal error");
       
   557   }
   554   // Build MatchLists for children
   558   // Build MatchLists for children
   555   // Check each child for an internal operand name, and use that name
   559   // Check each child for an internal operand name, and use that name
   556   // for the parent's matchlist entry if it exists
   560   // for the parent's matchlist entry if it exists
   557   mnode = node->_lChild;
   561   mnode = node->_lChild;
   558   if (mnode) {
   562   if (mnode) {