Files
Lauri Vasama be8351a17d Split up Clift PrimitiveType
* PrimitiveType is now an interface.
* VoidKind is now VoidType.
* FloatKind is now FloatType.
* The integer kinds are now IntegerType with IntegerKind.
2026-04-08 12:18:10 +03:00

42 lines
1.2 KiB
MLIR

//
// This file is distributed under the MIT License. See LICENSE.md for details.
//
// RUN: %revngpipe import-descriptive-info %S/model.yml %s /dev/stdout | %revngcliftopt | FileCheck %s
!void = !clift.void
!uint8_t = !clift.int<unsigned 1>
// CHECK: !f = !clift.func<"/type-definition/1001-CABIFunctionDefinition" as "f" :
// CHECK: !void(!uint8_t)
// CHECK: [
// CHECK: #clift.c_attribute<"_ABI" : "/macro/_ABI"
// CHECK: [
// CHECK: #clift.identifier<"SystemV_x86_64">
// CHECK: ]>
// CHECK: ]
// CHECK: >
!f = !clift.func<
"/type-definition/1001-CABIFunctionDefinition"
: !void(!uint8_t)
[
#clift.c_attribute<"_ABI" : "/macro/_ABI" [#clift.identifier<"SystemV_x86_64">]>
]
>
module attributes { clift.module } {
// CHECK: clift.func @fun_0x40001001<!f>(
// CHECK: %arg0: !uint8_t {
// CHECK: clift.handle = "/cabi-argument/1001-CABIFunctionDefinition/0"
// CHECK: clift.name = "a"
// CHECK: }
// CHECK: ) -> !void
// CHECK: attributes {
// CHECK: handle = "/function/0x40001001:Code_x86_64"
// CHECK: }
clift.func @f<!f>(%arg0 : !uint8_t { clift.handle = "/cabi-argument/1001-CABIFunctionDefinition/0" }) attributes {
handle = "/function/0x40001001:Code_x86_64"
} {
}
}