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 lag? #228

Open
VaradRengaraj opened this issue Dec 24, 2024 · 0 comments
Open

Performance lag? #228

VaradRengaraj opened this issue Dec 24, 2024 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@VaradRengaraj
Copy link

Hi,

(for the linux environment)

In the function _duma_allocate(), during the loop where we try to find the free slot, even after finding the free slot and 2 empty slots, we run through all the slot structures. If I am correct, by design, the empty slots come after the free slot, so after we find the 2 empty slots, shouldn't we break the loop?

    } else
#endif
        if (DUMAST_EMPTY == slot->state) {
      if (!emptySlots[0])
        emptySlots[0] = slot;
      else if (!emptySlots[1])
        emptySlots[1] = slot;
     **else
       break;**

For example,
test program tstheap with a test duration of 10000 runs for 160 seconds without breaking the for loop, and runs 120 seconds with breaking the loop.

@johnsonjh johnsonjh self-assigned this Dec 27, 2024
@johnsonjh johnsonjh added the enhancement New feature or request label Dec 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants