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

testing: imagebuf_test add benchmarks for iterator traversal #4007

Merged
merged 1 commit into from
Oct 19, 2023

Conversation

lgritz
Copy link
Collaborator

@lgritz lgritz commented Oct 8, 2023

To help with some other investigation I'm doing, amend imagebuf_test with benchmarks to compare the relative speeds of traversing a big ImageBuf with Iterator, ConstIterator, or just using pointers on an equivalently large array.

To help with some other investigation I'm doing, amend imagebuf_test
with benchmarks to compare the relative speeds of traversing a big
ImageBuf with Iterator, ConstIterator, or just using pointers on
an equivalently large array.

Signed-off-by: Larry Gritz <lg@larrygritz.com>
@lgritz
Copy link
Collaborator Author

lgritz commented Oct 19, 2023

No objections, right?

Copy link
Contributor

@grdanny grdanny left a comment

Choose a reason for hiding this comment

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

lgtm
for my own curiosity - why is this test under /src and not /testsuite ?

@lgritz
Copy link
Collaborator Author

lgritz commented Oct 19, 2023

for my own curiosity - why is this test under /src and not /testsuite ?

Historical precedent?

When dinosaurs roamed the earth, major classes got unit compiled unit tests that live in the same directory as the library containing the class (imagebuf.cpp also has imagebuf_test.cpp, etc.). They are run as part of the testsuite, but they are built along with the library (but they are not "installed", just an artifact of the build that's used for testing).

It would have been an equally reasonable choice, I guess, to make that source code itself live in the testsuite and only build when the testsuite is run. But that's not the way I did it at the time.

@lgritz lgritz merged commit a55d05c into AcademySoftwareFoundation:master Oct 19, 2023
26 checks passed
@grdanny
Copy link
Contributor

grdanny commented Oct 20, 2023

got it, thanks for explaining.

lgritz added a commit to lgritz/OpenImageIO that referenced this pull request Oct 20, 2023
…SoftwareFoundation#4007)

To help with some other investigation I'm doing, amend imagebuf_test
with benchmarks to compare the relative speeds of traversing a big
ImageBuf with Iterator, ConstIterator, or just using pointers on an
equivalently large array.

Signed-off-by: Larry Gritz <lg@larrygritz.com>
@lgritz lgritz deleted the lg-ibitertime branch October 20, 2023 19:57
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

Successfully merging this pull request may close these issues.

2 participants