Name Last Update
..
AsmParser Loading commit data...
Disassembler Loading commit data...
MCTargetDesc Loading commit data...
TargetInfo Loading commit data...
CMakeLists.txt Loading commit data...
ImmutableGraph.h Loading commit data...
LLVMBuild.txt Loading commit data...
README-FPStack.txt Loading commit data...
README-SSE.txt Loading commit data...
README-X86-64.txt Loading commit data...
README.txt Loading commit data...
X86.h Loading commit data...
X86.td Loading commit data...
X86AsmPrinter.cpp Loading commit data...
X86AsmPrinter.h Loading commit data...
X86AvoidStoreForwardingBlocks.cpp Loading commit data...
X86AvoidTrailingCall.cpp Loading commit data...
X86CallFrameOptimization.cpp Loading commit data...
X86CallLowering.cpp Loading commit data...
X86CallLowering.h Loading commit data...
X86CallingConv.cpp Loading commit data...
X86CallingConv.h Loading commit data...
X86CallingConv.td Loading commit data...
X86CmovConversion.cpp Loading commit data...
X86DiscriminateMemOps.cpp Loading commit data...
X86DomainReassignment.cpp Loading commit data...
X86EvexToVex.cpp Loading commit data...
X86ExpandPseudo.cpp Loading commit data...
X86FastISel.cpp Loading commit data...
X86FixupBWInsts.cpp Loading commit data...
X86FixupLEAs.cpp Loading commit data...
X86FixupSetCC.cpp Loading commit data...
X86FlagsCopyLowering.cpp Loading commit data...
X86FloatingPoint.cpp Loading commit data...
X86FrameLowering.cpp Loading commit data...
X86FrameLowering.h Loading commit data...
X86GenRegisterBankInfo.def Loading commit data...
X86ISelDAGToDAG.cpp Loading commit data...
X86ISelLowering.cpp Loading commit data...
X86ISelLowering.h Loading commit data...
X86IndirectBranchTracking.cpp Loading commit data...
X86IndirectThunks.cpp Loading commit data...
X86InsertPrefetch.cpp Loading commit data...
X86InsertWait.cpp Loading commit data...
X86InstCombineIntrinsic.cpp Loading commit data...
X86Instr3DNow.td Loading commit data...
X86InstrAMX.td Loading commit data...
X86InstrAVX512.td Loading commit data...
X86InstrArithmetic.td Loading commit data...
X86InstrBuilder.h Loading commit data...
X86InstrCMovSetCC.td Loading commit data...
X86InstrCompiler.td Loading commit data...
X86InstrControl.td Loading commit data...
X86InstrExtension.td Loading commit data...
X86InstrFMA.td Loading commit data...
X86InstrFMA3Info.cpp Loading commit data...
X86InstrFMA3Info.h Loading commit data...
X86InstrFPStack.td Loading commit data...
X86InstrFoldTables.cpp Loading commit data...
X86InstrFoldTables.h Loading commit data...
X86InstrFormats.td Loading commit data...
X86InstrFragmentsSIMD.td Loading commit data...
X86InstrInfo.cpp Loading commit data...
X86InstrInfo.h Loading commit data...
X86InstrInfo.td Loading commit data...
X86InstrKL.td Loading commit data...
X86InstrMMX.td Loading commit data...
X86InstrMPX.td Loading commit data...
X86InstrSGX.td Loading commit data...
X86InstrSSE.td Loading commit data...
X86InstrSVM.td Loading commit data...
X86InstrShiftRotate.td Loading commit data...
X86InstrSystem.td Loading commit data...
X86InstrTDX.td Loading commit data...
X86InstrTSX.td Loading commit data...
X86InstrVMX.td Loading commit data...
X86InstrVecCompiler.td Loading commit data...
X86InstrXOP.td Loading commit data...
X86InstructionSelector.cpp Loading commit data...
X86InterleavedAccess.cpp Loading commit data...
X86IntrinsicsInfo.h Loading commit data...
X86LegalizerInfo.cpp Loading commit data...
X86LegalizerInfo.h Loading commit data...
X86LoadValueInjectionLoadHardening.cpp Loading commit data...
X86LoadValueInjectionRetHardening.cpp Loading commit data...
X86MCInstLower.cpp Loading commit data...
X86MachineFunctionInfo.cpp Loading commit data...
X86MachineFunctionInfo.h Loading commit data...
X86MacroFusion.cpp Loading commit data...
X86MacroFusion.h Loading commit data...
X86OptimizeLEAs.cpp Loading commit data...
X86PadShortFunction.cpp Loading commit data...
X86PartialReduction.cpp Loading commit data...
X86PfmCounters.td Loading commit data...
X86RegisterBankInfo.cpp Loading commit data...
X86RegisterBankInfo.h Loading commit data...
X86RegisterBanks.td Loading commit data...
X86RegisterInfo.cpp Loading commit data...
X86RegisterInfo.h Loading commit data...
X86RegisterInfo.td Loading commit data...
X86SchedBroadwell.td Loading commit data...
X86SchedHaswell.td Loading commit data...
X86SchedPredicates.td Loading commit data...
X86SchedSandyBridge.td Loading commit data...
X86SchedSkylakeClient.td Loading commit data...
X86SchedSkylakeServer.td Loading commit data...
X86Schedule.td Loading commit data...
X86ScheduleAtom.td Loading commit data...
X86ScheduleBdVer2.td Loading commit data...
X86ScheduleBtVer2.td Loading commit data...
X86ScheduleSLM.td Loading commit data...
X86ScheduleZnver1.td Loading commit data...
X86ScheduleZnver2.td Loading commit data...
X86SelectionDAGInfo.cpp Loading commit data...
X86SelectionDAGInfo.h Loading commit data...
X86ShuffleDecodeConstantPool.cpp Loading commit data...
X86ShuffleDecodeConstantPool.h Loading commit data...
X86SpeculativeExecutionSideEffectSuppression.cpp Loading commit data...
X86SpeculativeLoadHardening.cpp Loading commit data...
X86Subtarget.cpp Loading commit data...
X86Subtarget.h Loading commit data...
X86TargetMachine.cpp Loading commit data...
X86TargetMachine.h Loading commit data...
X86TargetObjectFile.cpp Loading commit data...
X86TargetObjectFile.h Loading commit data...
X86TargetTransformInfo.cpp Loading commit data...
X86TargetTransformInfo.h Loading commit data...
X86VZeroUpper.cpp Loading commit data...
X86WinAllocaExpander.cpp Loading commit data...
X86WinEHState.cpp Loading commit data...
//===---------------------------------------------------------------------===//
// Random ideas for the X86 backend: FP stack related stuff
//===---------------------------------------------------------------------===//

//===---------------------------------------------------------------------===//

Some targets (e.g. athlons) prefer freep to fstp ST(0):
http://gcc.gnu.org/ml/gcc-patches/2004-04/msg00659.html

//===---------------------------------------------------------------------===//

This should use fiadd on chips where it is profitable:
double foo(double P, int *I) { return P+*I; }

We have fiadd patterns now but the followings have the same cost and
complexity. We need a way to specify the later is more profitable.

def FpADD32m  : FpI<(ops RFP:$dst, RFP:$src1, f32mem:$src2), OneArgFPRW,
                    [(set RFP:$dst, (fadd RFP:$src1,
                                     (extloadf64f32 addr:$src2)))]>;
                // ST(0) = ST(0) + [mem32]

def FpIADD32m : FpI<(ops RFP:$dst, RFP:$src1, i32mem:$src2), OneArgFPRW,
                    [(set RFP:$dst, (fadd RFP:$src1,
                                     (X86fild addr:$src2, i32)))]>;
                // ST(0) = ST(0) + [mem32int]

//===---------------------------------------------------------------------===//

The FP stackifier should handle simple permutates to reduce number of shuffle
instructions, e.g. turning:

fld P	->		fld Q
fld Q			fld P
fxch

or:

fxch	->		fucomi
fucomi			jl X
jg X

Ideas:
http://gcc.gnu.org/ml/gcc-patches/2004-11/msg02410.html


//===---------------------------------------------------------------------===//

Add a target specific hook to DAG combiner to handle SINT_TO_FP and
FP_TO_SINT when the source operand is already in memory.

//===---------------------------------------------------------------------===//

Open code rint,floor,ceil,trunc:
http://gcc.gnu.org/ml/gcc-patches/2004-08/msg02006.html
http://gcc.gnu.org/ml/gcc-patches/2004-08/msg02011.html

Opencode the sincos[f] libcall.

//===---------------------------------------------------------------------===//

None of the FPStack instructions are handled in
X86RegisterInfo::foldMemoryOperand, which prevents the spiller from
folding spill code into the instructions.

//===---------------------------------------------------------------------===//

Currently the x86 codegen isn't very good at mixing SSE and FPStack
code:

unsigned int foo(double x) { return x; }

foo:
	subl $20, %esp
	movsd 24(%esp), %xmm0
	movsd %xmm0, 8(%esp)
	fldl 8(%esp)
	fisttpll (%esp)
	movl (%esp), %eax
	addl $20, %esp
	ret

This just requires being smarter when custom expanding fptoui.

//===---------------------------------------------------------------------===//