[llvm-bugs] [Bug 39554] New: Add a unit test for frame index expansion

via llvm-bugs llvm-bugs at lists.llvm.org
Sun Nov 4 21:43:28 PST 2018


https://bugs.llvm.org/show_bug.cgi?id=39554

            Bug ID: 39554
           Summary: Add a unit test for frame index expansion
           Product: libraries
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Backend: AVR
          Assignee: unassignedbugs at nondot.org
          Reporter: me at dylanmckay.io
                CC: llvm-bugs at lists.llvm.org

In avr-rust bug #112, we encountered a backend bug caused by invalid expansion
of a FRMIDX instruction into a MOVWRdRr instruction. The backend would leave an
extraneous operand from the original FRMIDX that was not consistent with the
definition of MOVWRdRr.

This would trigger an assertion:

    Assertion failed: ((isImpReg || Op.isRegMask() || MCID->isVariadic() ||
                        OpNo < MCID->getNumOperands() || isMetaDataOp) &&
                        "Trying to add an operand to a machine instr that is
already done!"),
    function addOperand, file llvm/lib/CodeGen/MachineInstr.cpp


More informatiob about that bug can be found at:
https://github.com/avr-rust/rust/issues/112

We should write unit tests that cover the expansion of FRMIDX nodes into
MOVWRdRr instructions.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20181105/16b44e45/attachment.html>


More information about the llvm-bugs mailing list