-
Notifications
You must be signed in to change notification settings - Fork 242
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add in more generalized support for casting nested types #3162
Conversation
build |
Signed-off-by: Robert (Bobby) Evans <[email protected]>
build |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor typos but otherwise lgtm.
shims/spark311/src/main/scala/com/nvidia/spark/rapids/shims/spark311/Spark311Shims.scala
Outdated
Show resolved
Hide resolved
sql-plugin/src/main/scala/com/nvidia/spark/rapids/TypeChecks.scala
Outdated
Show resolved
Hide resolved
shims/spark311/src/main/scala/com/nvidia/spark/rapids/shims/spark311/Spark311Shims.scala
Outdated
Show resolved
Hide resolved
sql-plugin/src/main/scala/com/nvidia/spark/rapids/TypeChecks.scala
Outdated
Show resolved
Hide resolved
build |
build |
Got some scary test failures. Looking into it more. |
build |
There was a small bug in the existing cast code where it was using the member value |
This fixes #3156
This does not depend on rapidsai/cudf#8985, but it does help a lot with reducing unneeded data movement.
This adds support for casting structs to structs and maps to maps. It also generalizes support for casting arrays to arrays so that more types are supported. It also fixed a number of bugs in casting nested types.
I also added in an optimization from the original Spark cast code that checks to see if the types are structurally the same, meaning only the names of the fields in the struct changed, and if they are then it does not need to actually bother with the cast.