[WebAssembly] Add a TODO comment for a possible future optimization.
authorDan Gohman <dan433584@gmail.com>
Wed, 23 Dec 2015 00:22:04 +0000 (00:22 +0000)
committerDan Gohman <dan433584@gmail.com>
Wed, 23 Dec 2015 00:22:04 +0000 (00:22 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@256306 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/WebAssembly/WebAssemblyRegNumbering.cpp

index 0a945336a2bb8b2870fc3a16eb1a40d81391bb6f..f621db070b5bd0fc0f47befedb520c237d2571d5 100644 (file)
@@ -82,7 +82,8 @@ bool WebAssemblyRegNumbering::runOnMachineFunction(MachineFunction &MF) {
   }
 
   // Then assign regular WebAssembly registers for all remaining used
-  // virtual registers.
+  // virtual registers. TODO: Consider sorting the registers by frequency of
+  // use, to maximize usage of small immediate fields.
   unsigned NumArgRegs = MFI.getParams().size();
   unsigned NumVRegs = MF.getRegInfo().getNumVirtRegs();
   unsigned NumStackRegs = 0;