Skip to content

optimize(concat): concat map implementation#10048

Open
mapleFU wants to merge 1 commit into
apache:mainfrom
mapleFU:concat-map
Open

optimize(concat): concat map implementation#10048
mapleFU wants to merge 1 commit into
apache:mainfrom
mapleFU:concat-map

Conversation

@mapleFU
Copy link
Copy Markdown
Member

@mapleFU mapleFU commented Jun 2, 2026

Which issue does this PR close?

Rationale for this change

Implement concat for map

What changes are included in this PR?

Implement concat for map

Are these changes tested?

Yes

Are there any user-facing changes?

No

@github-actions github-actions Bot added the arrow Changes to the arrow crate label Jun 2, 2026
Ok(Arc::new(array))
}

fn concat_maps(
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This copy the logic for List, I don't know can we share a offset based template impl here

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds a native concat implementation for Arrow MapArray in arrow-select, avoiding the generic concat_fallback path and bringing Map in line with the existing optimized handling for List and Struct.

Changes:

  • Added concat_maps to efficiently concatenate MapArray instances, including correct handling of sliced inputs and null buffers.
  • Updated concat dispatch to route DataType::Map to the new implementation.
  • Added unit tests covering basic concatenation, sliced maps, null maps, and empty maps.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

arrow Changes to the arrow crate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat: native concat for map type

2 participants