Home | History | Annotate | Download | only in PTX
      1 //===-- PTXSelectionDAGInfo.h - PTX SelectionDAG Info -----------*- C++ -*-===//
      2 //
      3 //                     The LLVM Compiler Infrastructure
      4 //
      5 // This file is distributed under the University of Illinois Open Source
      6 // License. See LICENSE.TXT for details.
      7 //
      8 //===----------------------------------------------------------------------===//
      9 //
     10 // This file defines the PTX subclass for TargetSelectionDAGInfo.
     11 //
     12 //===----------------------------------------------------------------------===//
     13 
     14 #ifndef PTXSELECTIONDAGINFO_H
     15 #define PTXSELECTIONDAGINFO_H
     16 
     17 #include "llvm/Target/TargetSelectionDAGInfo.h"
     18 
     19 namespace llvm {
     20 
     21 /// PTXSelectionDAGInfo - TargetSelectionDAGInfo sub-class for the PTX target.
     22 /// At the moment, this is mostly just a copy of ARMSelectionDAGInfo.
     23 class PTXSelectionDAGInfo : public TargetSelectionDAGInfo {
     24   /// Subtarget - Keep a pointer to the PTXSubtarget around so that we can
     25   /// make the right decision when generating code for different targets.
     26   const PTXSubtarget *Subtarget;
     27 
     28 public:
     29   explicit PTXSelectionDAGInfo(const TargetMachine &TM);
     30   ~PTXSelectionDAGInfo();
     31 
     32   virtual
     33   SDValue EmitTargetCodeForMemcpy(SelectionDAG &DAG, DebugLoc dl,
     34                                   SDValue Chain,
     35                                   SDValue Dst, SDValue Src,
     36                                   SDValue Size, unsigned Align,
     37                                   bool isVolatile, bool AlwaysInline,
     38                                   MachinePointerInfo DstPtrInfo,
     39                                   MachinePointerInfo SrcPtrInfo) const;
     40 
     41   virtual
     42   SDValue EmitTargetCodeForMemset(SelectionDAG &DAG, DebugLoc dl,
     43                                   SDValue Chain,
     44                                   SDValue Op1, SDValue Op2,
     45                                   SDValue Op3, unsigned Align,
     46                                   bool isVolatile,
     47                                   MachinePointerInfo DstPtrInfo) const;
     48 };
     49 
     50 }
     51 
     52 #endif
     53 
     54