Skip to content

Commit 4a42c68

Browse files
committed
address reviewer comments
1 parent 108501e commit 4a42c68

File tree

3 files changed

+6
-10
lines changed

3 files changed

+6
-10
lines changed

mlir/include/mlir/Dialect/Ptr/IR/PtrDialect.td

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ def Ptr_PtrType : Ptr_Type<"Ptr", "ptr", [
4343
let summary = "pointer type";
4444
let description = [{
4545
The `ptr` type is an opaque pointer type. This type typically represents
46-
a reference to an object in memory. Pointers are optionally parameterized
46+
a handle to an object in memory. Pointers are optionally parameterized
4747
by a memory space.
4848
Syntax:
4949

@@ -57,10 +57,6 @@ def Ptr_PtrType : Ptr_Type<"Ptr", "ptr", [
5757
let builders = [
5858
TypeBuilder<(ins CArg<"Attribute", "nullptr">:$memorySpace), [{
5959
return $_get($_ctxt, memorySpace);
60-
}]>,
61-
TypeBuilder<(ins CArg<"unsigned">:$addressSpace), [{
62-
return $_get($_ctxt, IntegerAttr::get(IntegerType::get($_ctxt, 32),
63-
addressSpace));
6460
}]>
6561
];
6662
let skipDefaultBuilders = 1;

mlir/lib/Dialect/Ptr/IR/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@ add_mlir_dialect_library(
33
PtrAttrs.cpp
44
PtrTypes.cpp
55
PtrDialect.cpp
6-
ADDITIONAL_HEADER_DIRS
7-
${PROJECT_SOURCE_DIR}/mlir/Dialect/Pointer
6+
87
DEPENDS
98
MLIRPtrOpsAttributesIncGen
109
MLIRPtrOpsIncGen
10+
1111
LINK_LIBS
1212
PUBLIC
1313
MLIRIR

mlir/lib/Dialect/Ptr/IR/PtrAttrs.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,11 +27,11 @@ LogicalResult SpecAttr::verify(function_ref<InFlightDiagnostic()> emitError,
2727
uint32_t index) {
2828
if (size % kBitsInByte != 0)
2929
return emitError() << "size entry must be divisible by 8";
30-
else if (abi % kBitsInByte != 0)
30+
if (abi % kBitsInByte != 0)
3131
return emitError() << "abi entry must be divisible by 8";
32-
else if (preferred % kBitsInByte != 0)
32+
if (preferred % kBitsInByte != 0)
3333
return emitError() << "preferred entry must be divisible by 8";
34-
else if (index != kOptionalSpecValue && index % kBitsInByte != 0)
34+
if (index != kOptionalSpecValue && index % kBitsInByte != 0)
3535
return emitError() << "index entry must be divisible by 8";
3636
if (abi > preferred)
3737
return emitError() << "preferred alignment is expected to be at least "

0 commit comments

Comments
 (0)