You've already forked linux-packaging-mono
acceptance-tests
data
debian
docs
external
Newtonsoft.Json
api-doc-tools
api-snapshot
aspnetwebstack
binary-reference-assemblies
bockbuild
boringssl
cecil
cecil-legacy
corefx
corert
helix-binaries
ikdasm
ikvm
illinker-test-assets
linker
llvm
bindings
cmake
docs
examples
include
lib
Analysis
AsmParser
BinaryFormat
Bitcode
CodeGen
DebugInfo
Demangle
ExecutionEngine
FuzzMutate
Fuzzer
IR
IRReader
LTO
LineEditor
Linker
MC
Object
ObjectYAML
Option
Passes
ProfileData
Support
TableGen
Target
AArch64
AMDGPU
ARC
ARM
AVR
BPF
Hexagon
AsmParser
Disassembler
MCTargetDesc
TargetInfo
BitTracker.cpp
BitTracker.h
CMakeLists.txt
Hexagon.h
Hexagon.td
HexagonAsmPrinter.cpp
HexagonAsmPrinter.h
HexagonBitSimplify.cpp.REMOVED.git-id
HexagonBitTracker.cpp
HexagonBitTracker.h
HexagonBlockRanges.cpp
HexagonBlockRanges.h
HexagonBranchRelaxation.cpp
HexagonCFGOptimizer.cpp
HexagonCommonGEP.cpp
HexagonConstExtenders.cpp
HexagonConstPropagation.cpp
HexagonCopyToCombine.cpp
HexagonDepArch.h
HexagonDepArch.td
HexagonDepDecoders.h
HexagonDepIICHVX.td
HexagonDepIICScalar.td.REMOVED.git-id
HexagonDepITypes.h
HexagonDepITypes.td
HexagonDepInstrFormats.td
HexagonDepInstrInfo.td.REMOVED.git-id
HexagonDepMappings.td
HexagonDepOperands.td
HexagonDepTimingClasses.h
HexagonEarlyIfConv.cpp
HexagonExpandCondsets.cpp
HexagonFixupHwLoops.cpp
HexagonFrameLowering.cpp
HexagonFrameLowering.h
HexagonGatherPacketize.cpp
HexagonGenExtract.cpp
HexagonGenInsert.cpp
HexagonGenMux.cpp
HexagonGenPredicate.cpp
HexagonHardwareLoops.cpp
HexagonHazardRecognizer.cpp
HexagonHazardRecognizer.h
HexagonIICHVX.td
HexagonIICScalar.td
HexagonISelDAGToDAG.cpp
HexagonISelDAGToDAG.h
HexagonISelDAGToDAGHVX.cpp
HexagonISelLowering.cpp.REMOVED.git-id
HexagonISelLowering.h
HexagonISelLoweringHVX.cpp
HexagonInstrFormats.td
HexagonInstrFormatsV4.td
HexagonInstrFormatsV60.td
HexagonInstrFormatsV65.td
HexagonInstrInfo.cpp.REMOVED.git-id
HexagonInstrInfo.h
HexagonIntrinsics.td
HexagonIntrinsicsV3.td
HexagonIntrinsicsV4.td
HexagonIntrinsicsV5.td
HexagonIntrinsicsV60.td
HexagonLoopIdiomRecognition.cpp
HexagonMCInstLower.cpp
HexagonMachineFunctionInfo.cpp
HexagonMachineFunctionInfo.h
HexagonMachineScheduler.cpp
HexagonMachineScheduler.h
HexagonMapAsm2IntrinV62.gen.td
HexagonMapAsm2IntrinV65.gen.td
HexagonNewValueJump.cpp
HexagonOperands.td
HexagonOptAddrMode.cpp
HexagonOptimizeSZextends.cpp
HexagonPatterns.td.REMOVED.git-id
HexagonPatternsV65.td
HexagonPeephole.cpp
HexagonPseudo.td
HexagonRDFOpt.cpp
HexagonRegisterInfo.cpp
HexagonRegisterInfo.h
HexagonRegisterInfo.td
HexagonSchedule.td
HexagonScheduleV4.td
HexagonScheduleV55.td
HexagonScheduleV60.td
HexagonScheduleV62.td
HexagonScheduleV65.td
HexagonSelectionDAGInfo.cpp
HexagonSelectionDAGInfo.h
HexagonSplitConst32AndConst64.cpp
HexagonSplitDouble.cpp
HexagonStoreWidening.cpp
HexagonSubtarget.cpp
HexagonSubtarget.h
HexagonTargetMachine.cpp
HexagonTargetMachine.h
HexagonTargetObjectFile.cpp
HexagonTargetObjectFile.h
HexagonTargetStreamer.h
HexagonTargetTransformInfo.cpp
HexagonTargetTransformInfo.h
HexagonVLIWPacketizer.cpp
HexagonVLIWPacketizer.h
HexagonVectorLoopCarriedReuse.cpp
HexagonVectorPrint.cpp
LLVMBuild.txt
RDFCopy.cpp
RDFCopy.h
RDFDeadCode.cpp
RDFDeadCode.h
RDFGraph.cpp
RDFGraph.h
RDFLiveness.cpp
RDFLiveness.h
RDFRegisters.cpp
RDFRegisters.h
Lanai
MSP430
Mips
NVPTX
Nios2
PowerPC
RISCV
Sparc
SystemZ
WebAssembly
X86
XCore
CMakeLists.txt
LLVMBuild.txt
README.txt
Target.cpp
TargetIntrinsicInfo.cpp
TargetLoweringObjectFile.cpp
TargetMachine.cpp
TargetMachineC.cpp
Testing
ToolDrivers
Transforms
WindowsManifest
XRay
CMakeLists.txt
LLVMBuild.txt
projects
resources
runtimes
scripts
test
tools
unittests
utils
.arcconfig
.clang-format
.clang-tidy
.gitattributes
.gitignore
CMakeLists.txt
CODE_OWNERS.TXT
CREDITS.TXT
LICENSE.TXT
LLVMBuild.txt
README.txt
RELEASE_TESTERS.TXT
configure
llvm.spec.in
nuget-buildtasks
nunit-lite
roslyn-binaries
rx
xunit-binaries
how-to-bump-roslyn-binaries.md
ikvm-native
libgc
llvm
m4
man
mcs
mk
mono
msvc
po
runtime
samples
scripts
support
tools
COPYING.LIB
LICENSE
Makefile.am
Makefile.in
NEWS
README.md
acinclude.m4
aclocal.m4
autogen.sh
code_of_conduct.md
compile
config.guess
config.h.in
config.rpath
config.sub
configure.REMOVED.git-id
configure.ac.REMOVED.git-id
depcomp
install-sh
ltmain.sh.REMOVED.git-id
missing
mkinstalldirs
mono-uninstalled.pc.in
test-driver
winconfig.h
79 lines
3.1 KiB
C
79 lines
3.1 KiB
C
![]() |
//===--- HexagonHazardRecognizer.h - Hexagon Post RA Hazard Recognizer ----===//
|
||
|
//
|
||
|
// The LLVM Compiler Infrastructure
|
||
|
//
|
||
|
// This file is distributed under the University of Illinois Open Source
|
||
|
// License. See LICENSE.TXT for details.
|
||
|
//
|
||
|
//===----------------------------------------------------------------------===//
|
||
|
// This file defines the hazard recognizer for scheduling on Hexagon.
|
||
|
//===----------------------------------------------------------------------===//
|
||
|
|
||
|
#ifndef LLVM_LIB_TARGET_HEXAGON_HEXAGONPROFITRECOGNIZER_H
|
||
|
#define LLVM_LIB_TARGET_HEXAGON_HEXAGONPROFITRECOGNIZER_H
|
||
|
|
||
|
#include "HexagonInstrInfo.h"
|
||
|
#include "HexagonSubtarget.h"
|
||
|
#include "llvm/ADT/SmallSet.h"
|
||
|
#include "llvm/CodeGen/DFAPacketizer.h"
|
||
|
#include "llvm/CodeGen/ScheduleHazardRecognizer.h"
|
||
|
|
||
|
namespace llvm {
|
||
|
|
||
|
class HexagonHazardRecognizer : public ScheduleHazardRecognizer {
|
||
|
DFAPacketizer *Resources;
|
||
|
const HexagonInstrInfo *TII;
|
||
|
unsigned PacketNum;
|
||
|
// If the packet contains a potential dot cur instruction. This is
|
||
|
// used for the scheduling priority function.
|
||
|
SUnit *UsesDotCur;
|
||
|
// The packet number when a dor cur is emitted. If its use is not generated
|
||
|
// in the same packet, then try to wait another cycle before emitting.
|
||
|
int DotCurPNum;
|
||
|
// The set of registers defined by instructions in the current packet.
|
||
|
SmallSet<unsigned, 8> RegDefs;
|
||
|
|
||
|
public:
|
||
|
HexagonHazardRecognizer(const InstrItineraryData *II,
|
||
|
const HexagonInstrInfo *HII,
|
||
|
const HexagonSubtarget &ST)
|
||
|
: Resources(ST.createDFAPacketizer(II)), TII(HII), PacketNum(0),
|
||
|
UsesDotCur(nullptr), DotCurPNum(-1) { }
|
||
|
|
||
|
~HexagonHazardRecognizer() override {
|
||
|
if (Resources)
|
||
|
delete Resources;
|
||
|
}
|
||
|
|
||
|
/// This callback is invoked when a new block of instructions is about to be
|
||
|
/// scheduled. The hazard state is set to an initialized state.
|
||
|
void Reset() override;
|
||
|
|
||
|
/// Return the hazard type of emitting this node. There are three
|
||
|
/// possible results. Either:
|
||
|
/// * NoHazard: it is legal to issue this instruction on this cycle.
|
||
|
/// * Hazard: issuing this instruction would stall the machine. If some
|
||
|
/// other instruction is available, issue it first.
|
||
|
HazardType getHazardType(SUnit *SU, int stalls) override;
|
||
|
|
||
|
/// This callback is invoked when an instruction is emitted to be scheduled,
|
||
|
/// to advance the hazard state.
|
||
|
void EmitInstruction(SUnit *) override;
|
||
|
|
||
|
/// This callback may be invoked if getHazardType returns NoHazard. If, even
|
||
|
/// though there is no hazard, it would be better to schedule another
|
||
|
/// available instruction, this callback should return true.
|
||
|
bool ShouldPreferAnother(SUnit *) override;
|
||
|
|
||
|
/// This callback is invoked whenever the next top-down instruction to be
|
||
|
/// scheduled cannot issue in the current cycle, either because of latency
|
||
|
/// or resource conflicts. This should increment the internal state of the
|
||
|
/// hazard recognizer so that previously "Hazard" instructions will now not
|
||
|
/// be hazards.
|
||
|
void AdvanceCycle() override;
|
||
|
};
|
||
|
|
||
|
} // end namespace llvm
|
||
|
|
||
|
#endif // LLVM_LIB_TARGET_HEXAGON_HEXAGONPROFITRECOGNIZER_H
|