mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-08-05 13:26:55 +00:00
[Hexagon] Resubmission of 220427
Modified library structure to deal with circular dependency between HexagonInstPrinter and HexagonMCInst. Adding encoding bits for add opcode. Adding llvm-mc tests. Removing unit tests. http://reviews.llvm.org/D5624 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@220584 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -18,7 +18,7 @@
|
||||
#include "HexagonMachineFunctionInfo.h"
|
||||
#include "HexagonSubtarget.h"
|
||||
#include "HexagonTargetMachine.h"
|
||||
#include "InstPrinter/HexagonInstPrinter.h"
|
||||
#include "MCTargetDesc/HexagonInstPrinter.h"
|
||||
#include "MCTargetDesc/HexagonMCInst.h"
|
||||
#include "llvm/ADT/SmallString.h"
|
||||
#include "llvm/ADT/SmallVector.h"
|
||||
@@ -195,8 +195,8 @@ void HexagonAsmPrinter::EmitInstruction(const MachineInstr *MI) {
|
||||
unsigned Size = BundleMIs.size();
|
||||
assert((Size+IgnoreCount) == MI->getBundleSize() && "Corrupt Bundle!");
|
||||
for (unsigned Index = 0; Index < Size; Index++) {
|
||||
HexagonMCInst MCI;
|
||||
MCI.setPacketStart(Index == 0);
|
||||
HexagonMCInst MCI (BundleMIs[Index]->getOpcode());
|
||||
MCI.setPacketBegin(Index == 0);
|
||||
MCI.setPacketEnd(Index == (Size-1));
|
||||
|
||||
HexagonLowerToMC(BundleMIs[Index], MCI, *this);
|
||||
@@ -204,9 +204,9 @@ void HexagonAsmPrinter::EmitInstruction(const MachineInstr *MI) {
|
||||
}
|
||||
}
|
||||
else {
|
||||
HexagonMCInst MCI;
|
||||
HexagonMCInst MCI(MI->getOpcode());
|
||||
if (MI->getOpcode() == Hexagon::ENDLOOP0) {
|
||||
MCI.setPacketStart(true);
|
||||
MCI.setPacketBegin(true);
|
||||
MCI.setPacketEnd(true);
|
||||
}
|
||||
HexagonLowerToMC(MI, MCI, *this);
|
||||
|
Reference in New Issue
Block a user