[llvm-dev] Weird code in MipsGenSubtargetInfo.inc

Eugene Zelenko via llvm-dev llvm-dev at lists.llvm.org
Fri Dec 9 12:10:28 PST 2016


Hi!

Clang-tidy modernize-use-bool-literals pointed to some weird code in:
MipsGenSubtargetInfo::resolveSchedClass(). For example:

  case 3: // II_ADD
    if (SchedModel->getProcessorID() == 2) { // MipsP5600Model
      if ((1))
        return 779; // P5600WriteALU
      if ((0))
        return 780; // P5600WriteAL2
    }
    break;

I think will be good idea if somebody who knows MIPS and table
generation specific will look onto this issue.

Eugene.


More information about the llvm-dev mailing list