Helper class to generate LLVM IR for accessing fields of the Image struct via an opaque pointer. Assumes the following C++ struct layout: struct Image { uint32_t _width; // Offset 0 uint32_t _height; // Offset 4 unsigned char *_data; // Offset 8 };.
More...
#include <image_access_helper.h>
Helper class to generate LLVM IR for accessing fields of the Image struct via an opaque pointer. Assumes the following C++ struct layout: struct Image { uint32_t _width; // Offset 0 uint32_t _height; // Offset 4 unsigned char *_data; // Offset 8 };.
◆ ImageAccessHelper()
| picceler::ImageAccessHelper::ImageAccessHelper |
( |
mlir::Value | ptr, |
|
|
mlir::OpBuilder & | b, |
|
|
mlir::Location | l ) |
◆ getDataPtr()
| mlir::Value picceler::ImageAccessHelper::getDataPtr |
( |
| ) |
|
◆ getFieldAddr()
| mlir::Value picceler::ImageAccessHelper::getFieldAddr |
( |
int32_t | index | ) |
|
Internal helper to create the GEP (Address calculation) for a field index.
◆ getHeight()
| mlir::Value picceler::ImageAccessHelper::getHeight |
( |
| ) |
|
◆ getImageStructType()
| mlir::Type picceler::ImageAccessHelper::getImageStructType |
( |
mlir::MLIRContext * | ctx | ) |
|
|
static |
Defines the logical layout of the C++ struct for GEP offset calculations. struct Image { i32, i32, ptr }
◆ getWidth()
| mlir::Value picceler::ImageAccessHelper::getWidth |
( |
| ) |
|
◆ builder
| mlir::OpBuilder& picceler::ImageAccessHelper::builder |
◆ loc
| mlir::Location picceler::ImageAccessHelper::loc |
◆ structPtr
| mlir::Value picceler::ImageAccessHelper::structPtr |
The documentation for this struct was generated from the following files: