CIRCT  20.0.0git
Classes | Typedefs | Enumerations | Functions
MSFT.h File Reference
#include "mlir-c/IR.h"
#include "mlir-c/Pass.h"
Include dependency graph for MSFT.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  CirctMSFTPrimitiveDB
 
struct  CirctMSFTPlacementDB
 
struct  CirctMSFTWalkOrder
 

Typedefs

typedef int32_t CirctMSFTPrimitiveType
 
typedef void(* CirctMSFTPlacementCallback) (MlirAttribute loc, MlirOperation locOp, void *userData)
 

Enumerations

enum  CirctMSFTDirection { NONE = 0 , ASC = 1 , DESC = 2 }
 

Functions

 MLIR_DECLARE_CAPI_DIALECT_REGISTRATION (MSFT, msft)
 
MLIR_CAPI_EXPORTED void mlirMSFTRegisterPasses (void)
 
MLIR_CAPI_EXPORTED void circtMSFTReplaceAllUsesWith (MlirValue value, MlirValue newValue)
 
MLIR_CAPI_EXPORTED bool circtMSFTAttributeIsAPhysLocationAttribute (MlirAttribute)
 
MLIR_CAPI_EXPORTED MlirAttribute circtMSFTPhysLocationAttrGet (MlirContext, CirctMSFTPrimitiveType, uint64_t x, uint64_t y, uint64_t num)
 
MLIR_CAPI_EXPORTED CirctMSFTPrimitiveType circtMSFTPhysLocationAttrGetPrimitiveType (MlirAttribute)
 
MLIR_CAPI_EXPORTED uint64_t circtMSFTPhysLocationAttrGetX (MlirAttribute)
 
MLIR_CAPI_EXPORTED uint64_t circtMSFTPhysLocationAttrGetY (MlirAttribute)
 
MLIR_CAPI_EXPORTED uint64_t circtMSFTPhysLocationAttrGetNum (MlirAttribute)
 
MLIR_CAPI_EXPORTED MlirOperation circtMSFTGetInstance (MlirOperation root, MlirAttribute path)
 
MLIR_CAPI_EXPORTED bool circtMSFTAttributeIsAPhysicalBoundsAttr (MlirAttribute)
 
MLIR_CAPI_EXPORTED MlirAttribute circtMSFTPhysicalBoundsAttrGet (MlirContext, uint64_t, uint64_t, uint64_t, uint64_t)
 
MLIR_CAPI_EXPORTED bool circtMSFTAttributeIsALocationVectorAttribute (MlirAttribute)
 
MLIR_CAPI_EXPORTED MlirAttribute circtMSFTLocationVectorAttrGet (MlirContext, MlirType type, intptr_t numElements, MlirAttribute const *elements)
 
MLIR_CAPI_EXPORTED MlirType circtMSFTLocationVectorAttrGetType (MlirAttribute)
 
MLIR_CAPI_EXPORTED intptr_t circtMSFTLocationVectorAttrGetNumElements (MlirAttribute)
 
MLIR_CAPI_EXPORTED MlirAttribute circtMSFTLocationVectorAttrGetElement (MlirAttribute attr, intptr_t pos)
 
MLIR_CAPI_EXPORTED CirctMSFTPrimitiveDB circtMSFTCreatePrimitiveDB (MlirContext)
 
MLIR_CAPI_EXPORTED void circtMSFTDeletePrimitiveDB (CirctMSFTPrimitiveDB self)
 
MLIR_CAPI_EXPORTED MlirLogicalResult circtMSFTPrimitiveDBAddPrimitive (CirctMSFTPrimitiveDB, MlirAttribute locAndPrim)
 
MLIR_CAPI_EXPORTED bool circtMSFTPrimitiveDBIsValidLocation (CirctMSFTPrimitiveDB, MlirAttribute locAndPrim)
 
MLIR_CAPI_EXPORTED CirctMSFTPlacementDB circtMSFTCreatePlacementDB (MlirModule top, CirctMSFTPrimitiveDB seed)
 
MLIR_CAPI_EXPORTED void circtMSFTDeletePlacementDB (CirctMSFTPlacementDB self)
 
MLIR_CAPI_EXPORTED MlirOperation circtMSFTPlacementDBPlace (CirctMSFTPlacementDB, MlirOperation inst, MlirAttribute loc, MlirStringRef subpath, MlirLocation srcLoc)
 
MLIR_CAPI_EXPORTED void circtMSFTPlacementDBRemovePlacement (CirctMSFTPlacementDB, MlirOperation locOp)
 
MLIR_CAPI_EXPORTED MlirLogicalResult circtMSFTPlacementDBMovePlacement (CirctMSFTPlacementDB, MlirOperation locOp, MlirAttribute newLoc)
 
MLIR_CAPI_EXPORTED MlirOperation circtMSFTPlacementDBGetInstanceAt (CirctMSFTPlacementDB, MlirAttribute loc)
 
MLIR_CAPI_EXPORTED MlirAttribute circtMSFTPlacementDBGetNearestFreeInColumn (CirctMSFTPlacementDB, CirctMSFTPrimitiveType prim, uint64_t column, uint64_t nearestToY)
 
MLIR_CAPI_EXPORTED void circtMSFTPlacementDBWalkPlacements (CirctMSFTPlacementDB, CirctMSFTPlacementCallback, int64_t bounds[4], CirctMSFTPrimitiveType primTypeFilter, CirctMSFTWalkOrder walkOrder, void *userData)
 Walk all the placements within 'bounds' ([xmin, xmax, ymin, ymax], inclusive on all sides), with -1 meaning unbounded. More...
 

Typedef Documentation

◆ CirctMSFTPlacementCallback

typedef void(* CirctMSFTPlacementCallback) (MlirAttribute loc, MlirOperation locOp, void *userData)

Definition at line 109 of file MSFT.h.

◆ CirctMSFTPrimitiveType

typedef int32_t CirctMSFTPrimitiveType

Definition at line 24 of file MSFT.h.

Enumeration Type Documentation

◆ CirctMSFTDirection

Enumerator
NONE 
ASC 
DESC 

Definition at line 87 of file MSFT.h.

Function Documentation

◆ circtMSFTAttributeIsALocationVectorAttribute()

MLIR_CAPI_EXPORTED bool circtMSFTAttributeIsALocationVectorAttribute ( MlirAttribute  attr)

Definition at line 212 of file MSFT.cpp.

References unwrap().

◆ circtMSFTAttributeIsAPhysicalBoundsAttr()

MLIR_CAPI_EXPORTED bool circtMSFTAttributeIsAPhysicalBoundsAttr ( MlirAttribute  attr)

Definition at line 201 of file MSFT.cpp.

References unwrap().

◆ circtMSFTAttributeIsAPhysLocationAttribute()

MLIR_CAPI_EXPORTED bool circtMSFTAttributeIsAPhysLocationAttribute ( MlirAttribute  attr)

Definition at line 173 of file MSFT.cpp.

References unwrap().

◆ circtMSFTCreatePlacementDB()

MLIR_CAPI_EXPORTED CirctMSFTPlacementDB circtMSFTCreatePlacementDB ( MlirModule  top,
CirctMSFTPrimitiveDB  seed 
)

Definition at line 70 of file MSFT.cpp.

References unwrap(), and wrap().

Referenced by PlacementDB::PlacementDB().

◆ circtMSFTCreatePrimitiveDB()

MLIR_CAPI_EXPORTED CirctMSFTPrimitiveDB circtMSFTCreatePrimitiveDB ( MlirContext  ctxt)

Definition at line 47 of file MSFT.cpp.

References esiaccel.accelerator::ctxt, unwrap(), and wrap().

Referenced by PrimitiveDB::PrimitiveDB().

◆ circtMSFTDeletePlacementDB()

MLIR_CAPI_EXPORTED void circtMSFTDeletePlacementDB ( CirctMSFTPlacementDB  self)

Definition at line 76 of file MSFT.cpp.

References unwrap().

Referenced by PlacementDB::~PlacementDB().

◆ circtMSFTDeletePrimitiveDB()

MLIR_CAPI_EXPORTED void circtMSFTDeletePrimitiveDB ( CirctMSFTPrimitiveDB  self)

Definition at line 50 of file MSFT.cpp.

References unwrap().

Referenced by PrimitiveDB::~PrimitiveDB().

◆ circtMSFTGetInstance()

MLIR_CAPI_EXPORTED MlirOperation circtMSFTGetInstance ( MlirOperation  root,
MlirAttribute  path 
)

◆ circtMSFTLocationVectorAttrGet()

MLIR_CAPI_EXPORTED MlirAttribute circtMSFTLocationVectorAttrGet ( MlirContext  ctxt,
MlirType  type,
intptr_t  numElements,
MlirAttribute const *  elements 
)

◆ circtMSFTLocationVectorAttrGetElement()

MLIR_CAPI_EXPORTED MlirAttribute circtMSFTLocationVectorAttrGetElement ( MlirAttribute  attr,
intptr_t  pos 
)

Definition at line 233 of file MSFT.cpp.

References unwrap(), and wrap().

Referenced by PyLocationVecIterator::getItem().

◆ circtMSFTLocationVectorAttrGetNumElements()

MLIR_CAPI_EXPORTED intptr_t circtMSFTLocationVectorAttrGetNumElements ( MlirAttribute  attr)

Definition at line 230 of file MSFT.cpp.

References unwrap().

Referenced by PyLocationVecIterator::dunderNext().

◆ circtMSFTLocationVectorAttrGetType()

MLIR_CAPI_EXPORTED MlirType circtMSFTLocationVectorAttrGetType ( MlirAttribute  attr)

Definition at line 227 of file MSFT.cpp.

References unwrap(), and wrap().

◆ circtMSFTPhysicalBoundsAttrGet()

MLIR_CAPI_EXPORTED MlirAttribute circtMSFTPhysicalBoundsAttrGet ( MlirContext  cContext,
uint64_t  xMin,
uint64_t  xMax,
uint64_t  yMin,
uint64_t  yMax 
)

Definition at line 205 of file MSFT.cpp.

References circt::calyx::direction::get(), unwrap(), and wrap().

◆ circtMSFTPhysLocationAttrGet()

MLIR_CAPI_EXPORTED MlirAttribute circtMSFTPhysLocationAttrGet ( MlirContext  cCtxt,
CirctMSFTPrimitiveType  devType,
uint64_t  x,
uint64_t  y,
uint64_t  num 
)

Definition at line 176 of file MSFT.cpp.

References esiaccel.accelerator::ctxt, circt::calyx::direction::get(), unwrap(), and wrap().

◆ circtMSFTPhysLocationAttrGetNum()

MLIR_CAPI_EXPORTED uint64_t circtMSFTPhysLocationAttrGetNum ( MlirAttribute  attr)

Definition at line 197 of file MSFT.cpp.

References unwrap().

◆ circtMSFTPhysLocationAttrGetPrimitiveType()

MLIR_CAPI_EXPORTED CirctMSFTPrimitiveType circtMSFTPhysLocationAttrGetPrimitiveType ( MlirAttribute  attr)

Definition at line 186 of file MSFT.cpp.

References unwrap().

◆ circtMSFTPhysLocationAttrGetX()

MLIR_CAPI_EXPORTED uint64_t circtMSFTPhysLocationAttrGetX ( MlirAttribute  attr)

Definition at line 191 of file MSFT.cpp.

References unwrap().

◆ circtMSFTPhysLocationAttrGetY()

MLIR_CAPI_EXPORTED uint64_t circtMSFTPhysLocationAttrGetY ( MlirAttribute  attr)

Definition at line 194 of file MSFT.cpp.

References unwrap().

◆ circtMSFTPlacementDBGetInstanceAt()

MLIR_CAPI_EXPORTED MlirOperation circtMSFTPlacementDBGetInstanceAt ( CirctMSFTPlacementDB  db,
MlirAttribute  loc 
)

Definition at line 117 of file MSFT.cpp.

References unwrap(), and wrap().

Referenced by PlacementDB::getInstanceAt().

◆ circtMSFTPlacementDBGetNearestFreeInColumn()

MLIR_CAPI_EXPORTED MlirAttribute circtMSFTPlacementDBGetNearestFreeInColumn ( CirctMSFTPlacementDB  db,
CirctMSFTPrimitiveType  prim,
uint64_t  column,
uint64_t  nearestToY 
)

Definition at line 121 of file MSFT.cpp.

References unwrap(), and wrap().

Referenced by PlacementDB::getNearestFreeInColumn().

◆ circtMSFTPlacementDBMovePlacement()

MLIR_CAPI_EXPORTED MlirLogicalResult circtMSFTPlacementDBMovePlacement ( CirctMSFTPlacementDB  db,
MlirOperation  locOp,
MlirAttribute  newLoc 
)

Definition at line 104 of file MSFT.cpp.

References unwrap(), and wrap().

Referenced by PlacementDB::movePlacement().

◆ circtMSFTPlacementDBPlace()

MLIR_CAPI_EXPORTED MlirOperation circtMSFTPlacementDBPlace ( CirctMSFTPlacementDB  db,
MlirOperation  inst,
MlirAttribute  loc,
MlirStringRef  subpath,
MlirLocation  srcLoc 
)

Definition at line 80 of file MSFT.cpp.

References unwrap(), and wrap().

Referenced by PlacementDB::place().

◆ circtMSFTPlacementDBRemovePlacement()

MLIR_CAPI_EXPORTED void circtMSFTPlacementDBRemovePlacement ( CirctMSFTPlacementDB  db,
MlirOperation  locOp 
)

Definition at line 94 of file MSFT.cpp.

References assert(), and unwrap().

Referenced by PlacementDB::removePlacement().

◆ circtMSFTPlacementDBWalkPlacements()

MLIR_CAPI_EXPORTED void circtMSFTPlacementDBWalkPlacements ( CirctMSFTPlacementDB  cdb,
CirctMSFTPlacementCallback  ccb,
int64_t  bounds[4],
CirctMSFTPrimitiveType  primTypeFilter,
CirctMSFTWalkOrder  walkOrder,
void *  userData 
)

Walk all the placements within 'bounds' ([xmin, xmax, ymin, ymax], inclusive on all sides), with -1 meaning unbounded.

Definition at line 131 of file MSFT.cpp.

References CirctMSFTWalkOrder::columns, NONE, CirctMSFTWalkOrder::rows, unwrap(), circt::msft::PlacementDB::walkPlacements(), and wrap().

Referenced by PlacementDB::walkPlacements().

◆ circtMSFTPrimitiveDBAddPrimitive()

MLIR_CAPI_EXPORTED MlirLogicalResult circtMSFTPrimitiveDBAddPrimitive ( CirctMSFTPrimitiveDB  self,
MlirAttribute  locAndPrim 
)

Definition at line 53 of file MSFT.cpp.

References unwrap(), and wrap().

Referenced by PrimitiveDB::addPrimitive().

◆ circtMSFTPrimitiveDBIsValidLocation()

MLIR_CAPI_EXPORTED bool circtMSFTPrimitiveDBIsValidLocation ( CirctMSFTPrimitiveDB  self,
MlirAttribute  locAndPrim 
)

Definition at line 58 of file MSFT.cpp.

References unwrap().

Referenced by PrimitiveDB::isValidLocation().

◆ circtMSFTReplaceAllUsesWith()

MLIR_CAPI_EXPORTED void circtMSFTReplaceAllUsesWith ( MlirValue  value,
MlirValue  newValue 
)

Definition at line 37 of file MSFT.cpp.

References unwrap().

◆ MLIR_DECLARE_CAPI_DIALECT_REGISTRATION()

MLIR_DECLARE_CAPI_DIALECT_REGISTRATION ( MSFT  ,
msft   
)

◆ mlirMSFTRegisterPasses()

MLIR_CAPI_EXPORTED void mlirMSFTRegisterPasses ( void  )

Definition at line 32 of file MSFT.cpp.

References registerPasses().