Skip to content

第4章(2):特质 | Inside Compiler #60

@fiking

Description

@fiking

https://inside-compiler.github.io/2024/06/15/mlir-traits/

特质(Trait)是一种抽象机制的实现,针对属性、操作和类型进行修饰,主要有两个作用: 1)提供不同属性之间或者不同操作之间,或者不同类型之间的通用机制的实现; 2)对属性、操作和类型提供约束。 根据特质的用途,目前MLIR主要提供了以下4种特质: NativeTrait:提供一种方式,将C++的声明和定义封装为一个特质,然后用于TD中修饰对象。 ParamNativeTrait:继

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions