Subzero: Improve non-MINIMAL string performance.

In a DUMP-enabled build, such as the standard Release+Asserts build, translator performance has regressed as a result of 467ffe51bebcb3ae3e3ce745c38fc20e8837c31c (https://codereview.chromium.org/1838753002).

This is because Variable and CfgNode names are being instantiated unconditionally, rather than on-demand.

This CL restores most of that performance by going back to being on-demand.  Note that it should have no effect on MINIMAL build performance.

Also, it turns out that Variable::getName() does not really need the Cfg* parameter, so that is removed (and all its callers are fixed transitively).

In addition, Variable and CfgNode are made more uniform with respect to each other in terms of inline definitions of the ctor, getName(), and setName().

BUG= none
R=jpp@chromium.org, kschimpf@google.com

Review URL: https://codereview.chromium.org/1866463002 .
diff --git a/src/IceCfgNode.cpp b/src/IceCfgNode.cpp
index 4b5268a..94acff9 100644
--- a/src/IceCfgNode.cpp
+++ b/src/IceCfgNode.cpp
@@ -26,15 +26,6 @@
 
 namespace Ice {
 
-CfgNode::CfgNode(Cfg *Func, SizeT Number) : Func(Func), Number(Number) {
-  if (BuildDefs::dump()) {
-    Name =
-        NodeString::createWithString(Func, "__" + std::to_string(getIndex()));
-  } else {
-    Name = NodeString::createWithoutString(Func);
-  }
-}
-
 // Adds an instruction to either the Phi list or the regular instruction list.
 // Validates that all Phis are added before all regular instructions.
 void CfgNode::appendInst(Inst *Instr, bool AllowPhisAnywhere) {
@@ -797,7 +788,7 @@
       auto Next = Start + 1;
       Str << "Duplicate LR begin, block " << getName() << ", instructions "
           << Start->second << " & " << Next->second << ", variable "
-          << Liveness->getVariable(Start->first, this)->getName(Func) << "\n";
+          << Liveness->getVariable(Start->first, this)->getName() << "\n";
     }
     for (auto Start = MapEnd.begin();
          (Start = std::adjacent_find(Start, MapEnd.end(), ComparePair)) !=
@@ -806,7 +797,7 @@
       auto Next = Start + 1;
       Str << "Duplicate LR end,   block " << getName() << ", instructions "
           << Start->second << " & " << Next->second << ", variable "
-          << Liveness->getVariable(Start->first, this)->getName(Func) << "\n";
+          << Liveness->getVariable(Start->first, this)->getName() << "\n";
     }
   }
 
@@ -1402,7 +1393,7 @@
       for (SizeT i = 0; i < LiveIn.size(); ++i) {
         if (LiveIn[i]) {
           Variable *Var = Liveness->getVariable(i, this);
-          Str << " %" << Var->getName(Func);
+          Str << " %" << Var->getName();
           if (Func->isVerbose(IceV_RegOrigins) && Var->hasReg()) {
             Str << ":"
                 << Func->getTarget()->getRegName(Var->getRegNum(),
@@ -1428,7 +1419,7 @@
       for (SizeT i = 0; i < LiveOut.size(); ++i) {
         if (LiveOut[i]) {
           Variable *Var = Liveness->getVariable(i, this);
-          Str << " %" << Var->getName(Func);
+          Str << " %" << Var->getName();
           if (Func->isVerbose(IceV_RegOrigins) && Var->hasReg()) {
             Str << ":"
                 << Func->getTarget()->getRegName(Var->getRegNum(),