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 @@ -19,7 +19,6 @@ package org.apache.gluten.config
import org.apache.spark.network.util.{ByteUnit, JavaUtils}

import java.util.concurrent.TimeUnit
import java.util.regex.Pattern

object BackendType extends Enumeration {
type BackendType = Value
Expand Down Expand Up @@ -141,8 +140,6 @@ private object ConfigHelpers {
}
}

private val TIME_STRING_PATTERN = Pattern.compile("(-?[0-9]+)([a-z]+)?")

def timeFromString(str: String, unit: TimeUnit): Long = JavaUtils.timeStringAs(str, unit)

def timeToString(v: Long, unit: TimeUnit): String = s"${TimeUnit.MILLISECONDS.convert(v, unit)}ms"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -89,12 +89,10 @@ object FloydWarshallGraph {
private object Builder {
private class Impl[V <: AnyRef, E <: AnyRef]() extends Builder[V, E] {
private val pathTable: mutable.Map[V, mutable.Map[V, Path[E]]] = mutable.Map()
private var graph: Option[FloydWarshallGraph[V, E]] = None

override def addVertex(v: V): Builder[V, E] = {
assert(!pathTable.contains(v), s"Vertex $v already exists in graph")
pathTable.getOrElseUpdate(v, mutable.Map()).getOrElseUpdate(v, Path(Nil))
graph = None
this
}

Expand All @@ -104,7 +102,6 @@ object FloydWarshallGraph {
assert(pathTable.contains(to), s"Vertex $to not exists in graph")
assert(!hasPath(from, to), s"Path from $from to $to already exists in graph")
pathTable(from) += to -> Path(Seq(edge))
graph = None
this
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,11 @@ package object transition {
//
// Extend this list in shim layer once Spark has more.
def canPropagateConvention(plan: SparkPlan): Boolean = plan match {
case p: DebugExec => true
case p: UnionExec => true
case p: AQEShuffleReadExec => true
case p: InputAdapter => true
case p: WholeStageCodegenExec => true
case _: DebugExec => true
case _: UnionExec => true
case _: AQEShuffleReadExec => true
case _: InputAdapter => true
case _: WholeStageCodegenExec => true
case _ => false
}

Expand Down
Loading