Skip to content
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

[C#] There's no need to create multiple TimeType or IntervalType objects #36816

Closed
CurtHagenlocher opened this issue Jul 21, 2023 · 0 comments · Fixed by #36817
Closed

[C#] There's no need to create multiple TimeType or IntervalType objects #36816

CurtHagenlocher opened this issue Jul 21, 2023 · 0 comments · Fixed by #36817

Comments

@CurtHagenlocher
Copy link
Contributor

Describe the enhancement requested

There are only four different types of TimeType possible and two different types of IntervalType[*]. Instead of creating new ones from imported or deserialized values, these can just be interned -- reducing GC pressure ever-so-slightly.

(It would also be possible in principle to TimestampType but the timezone complicates that a little.)

*Well, there could also be MONTH_DAY_NANO once a newer version of the FlatBuffers is imported... .

Component(s)

C#

lidavidm pushed a commit that referenced this issue Aug 18, 2023
### What changes are included in this PR?

A small refactoring to make a small improvement in memory utilization.

### Are these changes tested?

Existing test coverage should be sufficient.

* Closes: #36816

Authored-by: Curt Hagenlocher <curt@hagenlocher.org>
Signed-off-by: David Li <li.davidm96@gmail.com>
@lidavidm lidavidm added this to the 14.0.0 milestone Aug 18, 2023
loicalleyne pushed a commit to loicalleyne/arrow that referenced this issue Nov 13, 2023
### What changes are included in this PR?

A small refactoring to make a small improvement in memory utilization.

### Are these changes tested?

Existing test coverage should be sufficient.

* Closes: apache#36816

Authored-by: Curt Hagenlocher <curt@hagenlocher.org>
Signed-off-by: David Li <li.davidm96@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants