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

Performance issue with FieldList::clear (and UpdateMsg::clear) #224

Closed
maciek-gc opened this issue Dec 8, 2022 · 1 comment
Closed

Performance issue with FieldList::clear (and UpdateMsg::clear) #224

maciek-gc opened this issue Dec 8, 2022 · 1 comment

Comments

@maciek-gc
Copy link

Full context here: https://community.developers.refinitiv.com/questions/100431/emac-fieldlistupdatemsg-performance-with-multithre.html?childToView=100441#answer-100441

In short, consider this:
fieldList.clear().addReal(123);

FieldList::clear ends up calling Encoder::releaseEncIterator, which requires locking. This is immediately followed by Encoder::acquireEncIterator when encoding new data on cleared FieldList, again requiring locking. This whole release/acquire cycle doesn't seem to do anything except clearing EncIterator on acquisition.

I think the call to Encoder::releaseEncIterator could be replaced with Encoder::clear (https://github.com/Refinitiv/Real-Time-SDK/blob/master/Cpp-C/Ema/Src/Access/Impl/FieldListEncoder.cpp#L51)

Similar scenario applies to UpdateMsg (and possibly other messages, it's just Update is gross majority of what I'm generating).

@L-Karchevska
Copy link
Contributor

@maciek-gc Thank you for reporting this observation! We've created an internal Jira to look into this issue and decide whether anything can be done about it.

vlevendel pushed a commit that referenced this issue Oct 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants