diff options
Diffstat (limited to 'mlir/test/Interfaces/DataLayoutInterfaces/module.mlir')
-rw-r--r-- | mlir/test/Interfaces/DataLayoutInterfaces/module.mlir | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/mlir/test/Interfaces/DataLayoutInterfaces/module.mlir b/mlir/test/Interfaces/DataLayoutInterfaces/module.mlir new file mode 100644 index 000000000000..adabe560ffdf --- /dev/null +++ b/mlir/test/Interfaces/DataLayoutInterfaces/module.mlir @@ -0,0 +1,15 @@ +// RUN: mlir-opt --test-data-layout-query %s | FileCheck %s + +module attributes { dlti.dl_spec = #dlti.dl_spec< + #dlti.dl_entry<!test.test_type_with_layout<10>, ["size", 12]>, + #dlti.dl_entry<!test.test_type_with_layout<20>, ["alignment", 32]>>} { + // CHECK-LABEL: @module_level_layout + func @module_level_layout() { + // CHECK: alignment = 32 + // CHECK: bitsize = 12 + // CHECK: preferred = 1 + // CHECK: size = 2 + "test.data_layout_query"() : () -> !test.test_type_with_layout<10> + return + } +} |