diff --git a/src/ComputeSharp.SourceGenerators/Extensions/IncrementalValuesProviderExtensions.cs b/src/ComputeSharp.SourceGenerators/Extensions/IncrementalValuesProviderExtensions.cs
new file mode 100644
index 00000000..571ef354
--- /dev/null
+++ b/src/ComputeSharp.SourceGenerators/Extensions/IncrementalValuesProviderExtensions.cs
@@ -0,0 +1,71 @@
+using System;
+using System.Collections.Generic;
+using Microsoft.CodeAnalysis;
+
+namespace ComputeSharp.SourceGenerators.Extensions;
+
+///
+/// Extension methods for .
+///
+internal static class IncrementalValuesProviderExtensions
+{
+ ///
+ /// Creates a new instance with a gven pair of comparers.
+ ///
+ /// The type of left items in each tuple.
+ /// The type of right items in each tuple.
+ /// The input instance.
+ /// An instance for items.
+ /// An instance for items.
+ /// An with the specified comparers applied to each item.
+ public static IncrementalValuesProvider<(TLeft Left, TRight Right)> WithComparers(
+ this IncrementalValuesProvider<(TLeft Left, TRight Right)> source,
+ IEqualityComparer comparerLeft,
+ IEqualityComparer comparerRight)
+ {
+ return source.WithComparer(new Comparer(comparerLeft, comparerRight));
+ }
+
+ ///
+ /// An implementation for a value tuple.
+ ///
+ public sealed class Comparer : IEqualityComparer<(TLeft Left, TRight Right)>
+ {
+ ///
+ /// The comparer.
+ ///
+ private readonly IEqualityComparer comparerLeft;
+
+ ///
+ /// The comparer.
+ ///
+ private readonly IEqualityComparer comparerRight;
+
+ ///
+ /// Creates a new instance with the specified parameters.
+ ///
+ /// The comparer.
+ /// The comparer.
+ public Comparer(IEqualityComparer comparerLeft, IEqualityComparer comparerRight)
+ {
+ this.comparerLeft = comparerLeft;
+ this.comparerRight = comparerRight;
+ }
+
+ ///
+ public bool Equals((TLeft Left, TRight Right) x, (TLeft Left, TRight Right) y)
+ {
+ return
+ this.comparerLeft.Equals(x.Left, y.Left) &&
+ this.comparerRight.Equals(x.Right, y.Right);
+ }
+
+ ///
+ public int GetHashCode((TLeft Left, TRight Right) obj)
+ {
+ return HashCode.Combine(
+ this.comparerLeft.GetHashCode(obj.Left),
+ this.comparerRight.GetHashCode(obj.Right));
+ }
+ }
+}