mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-11-24 23:19:03 +00:00
--- Reverse-merging r107947 into '.':
U utils/TableGen/FastISelEmitter.cpp --- Reverse-merging r107943 into '.': U test/CodeGen/X86/fast-isel.ll U test/CodeGen/X86/fast-isel-loads.ll U include/llvm/Target/TargetLowering.h U include/llvm/Support/PassNameParser.h U include/llvm/CodeGen/FunctionLoweringInfo.h U include/llvm/CodeGen/CallingConvLower.h U include/llvm/CodeGen/FastISel.h U include/llvm/CodeGen/SelectionDAGISel.h U lib/CodeGen/LLVMTargetMachine.cpp U lib/CodeGen/CallingConvLower.cpp U lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp U lib/CodeGen/SelectionDAG/FunctionLoweringInfo.cpp U lib/CodeGen/SelectionDAG/FastISel.cpp U lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp U lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.cpp U lib/CodeGen/SelectionDAG/InstrEmitter.cpp U lib/CodeGen/SelectionDAG/TargetLowering.cpp U lib/Target/XCore/XCoreISelLowering.cpp U lib/Target/XCore/XCoreISelLowering.h U lib/Target/X86/X86ISelLowering.cpp U lib/Target/X86/X86FastISel.cpp U lib/Target/X86/X86ISelLowering.h git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107987 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -188,7 +188,8 @@ public:
|
||||
/// CheckReturn - Analyze the return values of a function, returning
|
||||
/// true if the return can be performed without sret-demotion, and
|
||||
/// false otherwise.
|
||||
bool CheckReturn(const SmallVectorImpl<ISD::OutputArg> &ArgsFlags,
|
||||
bool CheckReturn(const SmallVectorImpl<EVT> &OutTys,
|
||||
const SmallVectorImpl<ISD::ArgFlagsTy> &ArgsFlags,
|
||||
CCAssignFn Fn);
|
||||
|
||||
/// AnalyzeCallOperands - Analyze the outgoing arguments to a call,
|
||||
|
||||
@@ -19,7 +19,6 @@
|
||||
#include "llvm/ADT/SmallSet.h"
|
||||
#endif
|
||||
#include "llvm/CodeGen/ValueTypes.h"
|
||||
#include "llvm/CodeGen/MachineBasicBlock.h"
|
||||
|
||||
namespace llvm {
|
||||
|
||||
@@ -45,6 +44,7 @@ class TargetRegisterInfo;
|
||||
/// lowering, but runs quickly.
|
||||
class FastISel {
|
||||
protected:
|
||||
MachineBasicBlock *MBB;
|
||||
DenseMap<const Value *, unsigned> LocalValueMap;
|
||||
FunctionLoweringInfo &FuncInfo;
|
||||
MachineRegisterInfo &MRI;
|
||||
@@ -56,21 +56,23 @@ protected:
|
||||
const TargetInstrInfo &TII;
|
||||
const TargetLowering &TLI;
|
||||
const TargetRegisterInfo &TRI;
|
||||
MachineInstr *LastLocalValue;
|
||||
bool IsBottomUp;
|
||||
|
||||
public:
|
||||
/// getLastLocalValue - Return the position of the last instruction
|
||||
/// emitted for materializing constants for use in the current block.
|
||||
MachineInstr *getLastLocalValue() { return LastLocalValue; }
|
||||
|
||||
/// setLastLocalValue - Update the position of the last instruction
|
||||
/// emitted for materializing constants for use in the current block.
|
||||
void setLastLocalValue(MachineInstr *I) { LastLocalValue = I; }
|
||||
|
||||
/// startNewBlock - Set the current block to which generated machine
|
||||
/// instructions will be appended, and clear the local CSE map.
|
||||
///
|
||||
void startNewBlock();
|
||||
void startNewBlock(MachineBasicBlock *mbb) {
|
||||
setCurrentBlock(mbb);
|
||||
LocalValueMap.clear();
|
||||
}
|
||||
|
||||
/// setCurrentBlock - Set the current block to which generated machine
|
||||
/// instructions will be appended.
|
||||
///
|
||||
void setCurrentBlock(MachineBasicBlock *mbb) {
|
||||
MBB = mbb;
|
||||
}
|
||||
|
||||
/// getCurDebugLoc() - Return current debug location information.
|
||||
DebugLoc getCurDebugLoc() const { return DL; }
|
||||
@@ -102,17 +104,6 @@ public:
|
||||
/// index value.
|
||||
std::pair<unsigned, bool> getRegForGEPIndex(const Value *V);
|
||||
|
||||
/// recomputeInsertPt - Reset InsertPt to prepare for insterting instructions
|
||||
/// into the current block.
|
||||
void recomputeInsertPt();
|
||||
|
||||
/// enterLocalValueArea - Prepare InsertPt to begin inserting instructions
|
||||
/// into the local value area and return the old insert position.
|
||||
MachineBasicBlock::iterator enterLocalValueArea();
|
||||
|
||||
/// leaveLocalValueArea - Reset InsertPt to the given old insert position
|
||||
void leaveLocalValueArea(MachineBasicBlock::iterator OldInsertPt);
|
||||
|
||||
virtual ~FastISel();
|
||||
|
||||
protected:
|
||||
|
||||
@@ -25,7 +25,6 @@
|
||||
#endif
|
||||
#include "llvm/CodeGen/ValueTypes.h"
|
||||
#include "llvm/CodeGen/ISDOpcodes.h"
|
||||
#include "llvm/CodeGen/MachineBasicBlock.h"
|
||||
#include "llvm/Support/CallSite.h"
|
||||
#include <vector>
|
||||
|
||||
@@ -81,15 +80,6 @@ public:
|
||||
/// function arguments that are inserted after scheduling is completed.
|
||||
SmallVector<MachineInstr*, 8> ArgDbgValues;
|
||||
|
||||
/// RegFixups - Registers which need to be replaced after isel is done.
|
||||
DenseMap<unsigned, unsigned> RegFixups;
|
||||
|
||||
/// MBB - The current block.
|
||||
MachineBasicBlock *MBB;
|
||||
|
||||
/// MBB - The current insert position inside the current block.
|
||||
MachineBasicBlock::iterator InsertPt;
|
||||
|
||||
#ifndef NDEBUG
|
||||
SmallSet<const Instruction *, 8> CatchInfoLost;
|
||||
SmallSet<const Instruction *, 8> CatchInfoFound;
|
||||
|
||||
@@ -280,14 +280,15 @@ private:
|
||||
SDNode *MorphNode(SDNode *Node, unsigned TargetOpc, SDVTList VTs,
|
||||
const SDValue *Ops, unsigned NumOps, unsigned EmitNodeInfo);
|
||||
|
||||
void PrepareEHLandingPad();
|
||||
void PrepareEHLandingPad(MachineBasicBlock *BB);
|
||||
void SelectAllBasicBlocks(const Function &Fn);
|
||||
void FinishBasicBlock();
|
||||
void FinishBasicBlock(MachineBasicBlock *BB);
|
||||
|
||||
void SelectBasicBlock(BasicBlock::const_iterator Begin,
|
||||
BasicBlock::const_iterator End,
|
||||
bool &HadTailCall);
|
||||
void CodeGenAndEmitDAG();
|
||||
MachineBasicBlock *SelectBasicBlock(MachineBasicBlock *BB,
|
||||
BasicBlock::const_iterator Begin,
|
||||
BasicBlock::const_iterator End,
|
||||
bool &HadTailCall);
|
||||
MachineBasicBlock *CodeGenAndEmitDAG(MachineBasicBlock *BB);
|
||||
void LowerArguments(const BasicBlock *BB);
|
||||
|
||||
void ComputeLiveOutVRegInfo();
|
||||
|
||||
@@ -69,7 +69,6 @@ public:
|
||||
virtual void passRegistered(const PassInfo *P) {
|
||||
if (ignorablePass(P) || !Opt) return;
|
||||
if (findOption(P->getPassArgument()) != getNumOptions()) {
|
||||
return;
|
||||
errs() << "Two passes with the same argument (-"
|
||||
<< P->getPassArgument() << ") attempted to be registered!\n";
|
||||
llvm_unreachable(0);
|
||||
|
||||
@@ -24,7 +24,6 @@
|
||||
|
||||
#include "llvm/CallingConv.h"
|
||||
#include "llvm/InlineAsm.h"
|
||||
#include "llvm/Attributes.h"
|
||||
#include "llvm/CodeGen/SelectionDAGNodes.h"
|
||||
#include "llvm/CodeGen/RuntimeLibcalls.h"
|
||||
#include "llvm/ADT/APFloat.h"
|
||||
@@ -1160,7 +1159,8 @@ public:
|
||||
/// registers. If false is returned, an sret-demotion is performed.
|
||||
///
|
||||
virtual bool CanLowerReturn(CallingConv::ID CallConv, bool isVarArg,
|
||||
const SmallVectorImpl<ISD::OutputArg> &Outs,
|
||||
const SmallVectorImpl<EVT> &OutTys,
|
||||
const SmallVectorImpl<ISD::ArgFlagsTy> &ArgsFlags,
|
||||
LLVMContext &Context) const
|
||||
{
|
||||
// Return true by default to get preexisting behavior.
|
||||
@@ -1656,15 +1656,6 @@ protected:
|
||||
/// optimization.
|
||||
bool benefitFromCodePlacementOpt;
|
||||
};
|
||||
|
||||
/// GetReturnInfo - Given an LLVM IR type and return type attributes,
|
||||
/// compute the return value EVTs and flags, and optionally also
|
||||
/// the offsets, if the return value is being lowered to memory.
|
||||
void GetReturnInfo(const Type* ReturnType, Attributes attr,
|
||||
SmallVectorImpl<ISD::OutputArg> &Outs,
|
||||
const TargetLowering &TLI,
|
||||
SmallVectorImpl<uint64_t> *Offsets = 0);
|
||||
|
||||
} // end llvm namespace
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user