Skip to content

Commit 108e3cd

Browse files
authored
Fixes #152 (#158)
* Updated integer predicate names to include 'Than' for clarity and consistency
1 parent 6df21fa commit 108e3cd

File tree

2 files changed

+36
-21
lines changed

2 files changed

+36
-21
lines changed

docfx/ReleaseNotes.md

Lines changed: 20 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,15 @@
22
# v10.0.0-alpha
33

44
## Library name changes
5-
With the 10.* release the names of the assemblies, and therfore the packages, are all changed.
5+
With the 10.* release the names of the assemblies, and therefore the packages, are all changed.
66
This was done to unify them all under a common organization name to allow use of the facilities
7-
privided by Nuget for organizations and to help clarify these libraries from some other similar
7+
provided by NuGet for organizations and to help clarify these libraries from some other similar
88
projects no longer maintained.
99

10-
| Old Name | New Name |
11-
|------------------|--------------|
10+
| Old Name | New Name |
11+
|---------------------------|--------------|
1212
| Ubiquity.NET.Llvm.Interop | Ubiquity.Net.Llvm.Interop |
13-
| LibLLVM.dll | Ubiquity.Net.LibLLVM.dll |
13+
| LibLLVM.dll | Ubiquity.Net.LibLLVM.dll |
1414
| Ubiquity.NET.Llvm | Ubiquity.Net.Llvm |
1515

1616

@@ -23,6 +23,21 @@ to make nullability more explicit. This necessitated a few minor breaking change
2323
| DebugMemberInfo | Removed setters of non-nullable properties and added constructor to allow building the type with non-null values |
2424
| DIType | null is no longer used to represent a void type, instead a new singleton DITypeVoid.Instance is used.|
2525

26+
The comparison instruction predicates `Ubiquity.NET.Llvm.Instructions.[Predicate|IntPredicate]`were renamed for greater consistency
27+
and clarity (Some of the float predicates had 'Than' in the name while the integer counterparts did not. (See:
28+
[Bug #152](https://github.com/UbiquityDotNET/Llvm.NET/issues/152) for details.)
29+
30+
| Old Name | New Name |
31+
|------------------------|--------------|
32+
| UnsignedGreater | UnsignedGreaterThan |
33+
| UnsignedGreaterOrEqual | UnsignedGreaterThanOrEqual |
34+
| UnsignedLess | UnsignedLessThan |
35+
| UnsignedLessOrEqual | UnsignedLessThanOrEqual |
36+
| SignedGreater | SignedGreaterThan |
37+
| SignedGreaterOrEqual | SignedGreaterThanOrEqual |
38+
| SignedLess | SignedLessThan |
39+
| SignedLessOrEqual | SignedLessThanOrEqual |
40+
2641
## Removed redundant APIs
2742
LLVM has made additional APIs available in the standard LLVM-C library that are either identical to or functionaly equivalent to
2843
APIs that were custom in previous versions of the Ubiquity.NET.Llvm DLLs. This is only observable at the interop library layer where some

src/Ubiquity.NET.Llvm/Instructions/Predicates.cs

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -82,34 +82,34 @@ public enum Predicate
8282
NotEqual = LLVMIntPredicate.LLVMIntNE,
8383

8484
/// <summary>Integer unsigned greater than comparison</summary>
85-
UnsignedGreater = LLVMIntPredicate.LLVMIntUGT,
85+
UnsignedGreaterThan = LLVMIntPredicate.LLVMIntUGT,
8686

8787
/// <summary>Integer unsigned greater than or equal comparison</summary>
88-
UnsignedGreaterOrEqual = LLVMIntPredicate.LLVMIntUGE,
88+
UnsignedGreaterThanOrEqual = LLVMIntPredicate.LLVMIntUGE,
8989

9090
/// <summary>Integer unsigned less than comparison</summary>
91-
UnsignedLess = LLVMIntPredicate.LLVMIntULT,
91+
UnsignedLessThan = LLVMIntPredicate.LLVMIntULT,
9292

9393
/// <summary>Integer unsigned less than or equal comparison</summary>
94-
UnsignedLessOrEqual = LLVMIntPredicate.LLVMIntULE,
94+
UnsignedLessThanOrEqual = LLVMIntPredicate.LLVMIntULE,
9595

9696
/// <summary>Integer signed greater than comparison</summary>
97-
SignedGreater = LLVMIntPredicate.LLVMIntSGT,
97+
SignedGreaterThan = LLVMIntPredicate.LLVMIntSGT,
9898

9999
/// <summary>Integer signed greater than or equal comparison</summary>
100-
SignedGreaterOrEqual = LLVMIntPredicate.LLVMIntSGE,
100+
SignedGreaterThanOrEqual = LLVMIntPredicate.LLVMIntSGE,
101101

102102
/// <summary>Integer signed less than comparison</summary>
103-
SignedLess = LLVMIntPredicate.LLVMIntSLT,
103+
SignedLessThan = LLVMIntPredicate.LLVMIntSLT,
104104

105105
/// <summary>Integer signed less than or equal comparison</summary>
106-
SignedLessOrEqual = LLVMIntPredicate.LLVMIntSLE,
106+
SignedLessThanOrEqual = LLVMIntPredicate.LLVMIntSLE,
107107

108108
/// <summary>Tag for the first integer compare predicate, all integer predicates are greater than or equal to this value</summary>
109109
FirstIcmpPredicate = Equal,
110110

111111
/// <summary>Tag for the last integer compare predicate, all integer predicates are less than or equal to this value</summary>
112-
LastIcmpPredicate = SignedLessOrEqual,
112+
LastIcmpPredicate = SignedLessThanOrEqual,
113113

114114
/// <summary>Any value Greater than or equal to this is not valid for cmp operations</summary>
115115
BadIcmpPredicate = LastIcmpPredicate + 1
@@ -186,28 +186,28 @@ public enum IntPredicate
186186
NotEqual = LLVMIntPredicate.LLVMIntNE,
187187

188188
/// <summary>Integer unsigned greater than comparison</summary>
189-
UnsignedGreater = LLVMIntPredicate.LLVMIntUGT,
189+
UnsignedGreaterThan = LLVMIntPredicate.LLVMIntUGT,
190190

191191
/// <summary>Integer unsigned greater than or equal comparison</summary>
192192
UnsignedGreaterOrEqual = LLVMIntPredicate.LLVMIntUGE,
193193

194194
/// <summary>Integer unsigned less than comparison</summary>
195-
UnsignedLess = LLVMIntPredicate.LLVMIntULT,
195+
UnsignedLessThan = LLVMIntPredicate.LLVMIntULT,
196196

197197
/// <summary>Integer unsigned less than or equal comparison</summary>
198-
UnsignedLessOrEqual = LLVMIntPredicate.LLVMIntULE,
198+
UnsignedLessThanOrEqual = LLVMIntPredicate.LLVMIntULE,
199199

200200
/// <summary>Integer signed greater than comparison</summary>
201-
SignedGreater = LLVMIntPredicate.LLVMIntSGT,
201+
SignedGreaterThan = LLVMIntPredicate.LLVMIntSGT,
202202

203203
/// <summary>Integer signed greater than or equal comparison</summary>
204-
SignedGreaterOrEqual = LLVMIntPredicate.LLVMIntSGE,
204+
SignedGreaterThanOrEqual = LLVMIntPredicate.LLVMIntSGE,
205205

206206
/// <summary>Integer signed less than comparison</summary>
207-
SignedLess = LLVMIntPredicate.LLVMIntSLT,
207+
SignedLessThan = LLVMIntPredicate.LLVMIntSLT,
208208

209209
/// <summary>Integer signed less than or equal comparison</summary>
210-
SignedLessOrEqual = LLVMIntPredicate.LLVMIntSLE
210+
SignedLessThanOrEqual = LLVMIntPredicate.LLVMIntSLE
211211
}
212212

213213
/// <summary>Predicate enumeration for floating point comparison</summary>

0 commit comments

Comments
 (0)