Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -3501,6 +3501,34 @@ object GpuOverrides extends Logging {
("src", TypeSig.STRING, TypeSig.STRING),
("search", TypeSig.lit(TypeEnum.STRING), TypeSig.STRING)),
(a, conf, p, r) => new BinaryExprMeta[Like](a, conf, p, r) {
override def tagExprForGpu(): Unit = {
a.right match {
case Literal(v: UTF8String, _) =>
val pattern = v.toString
val esc = a.escapeChar
var i = 0
while (i < pattern.length) {
if (pattern.charAt(i) == esc) {
val j = i + 1
if (j >= pattern.length) {
willNotWorkOnGpu(
"invalid LIKE escape pattern")
return
}
val c = pattern.charAt(j)
if (c != '_' && c != '%' && c != esc) {
willNotWorkOnGpu(
"invalid LIKE escape pattern")
return
}
i = j + 1
} else {
i += 1
}
}
case _ =>
}
}
override def convertToGpu(lhs: Expression, rhs: Expression): GpuExpression =
GpuLike(lhs, rhs, a.escapeChar)
}),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,6 @@ class RapidsTestSettings extends BackendTestSettings {
.exclude("SPARK-19650: An action on a Command should not trigger a Spark job", KNOWN_ISSUE("https://github.com/NVIDIA/spark-rapids/issues/14110"))
.exclude("SPARK-31594: Do not display the seed of rand/randn with no argument in output schema", ADJUST_UT("Replaced by testRapids version with a correct regex expression to match the projectExplainOutput, randn isn't supported now. See https://github.com/NVIDIA/spark-rapids/issues/11613"))
.exclude("normalize special floating numbers in subquery", KNOWN_ISSUE("https://github.com/NVIDIA/spark-rapids/issues/14116"))
.exclude("SPARK-33677: LikeSimplification should be skipped if pattern contains any escapeChar", KNOWN_ISSUE("https://github.com/NVIDIA/spark-rapids/issues/14117"))
.exclude("SPARK-33593: Vector reader got incorrect data with binary partition value", KNOWN_ISSUE("https://github.com/NVIDIA/spark-rapids/issues/14118"))
.exclude("SPARK-33084: Add jar support Ivy URI in SQL -- jar contains udf class", ADJUST_UT("Replaced by testRapids version that uses testFile() to access Spark test resources instead of getContextClassLoader"))
.exclude("SPARK-33482: Fix FileScan canonicalization", KNOWN_ISSUE("https://github.com/NVIDIA/spark-rapids/issues/14122"))
Expand Down
Loading