Skip to content

Fix maximum number of arenas in op_initialize()#1305

Merged
lukaszstolarczuk merged 1 commit into
oneapi-src:mainfrom
ldorau:Fix_maximum_number_of_arenas_in_op_initialize
May 13, 2025
Merged

Fix maximum number of arenas in op_initialize()#1305
lukaszstolarczuk merged 1 commit into
oneapi-src:mainfrom
ldorau:Fix_maximum_number_of_arenas_in_op_initialize

Conversation

@ldorau

@ldorau ldorau commented May 9, 2025

Copy link
Copy Markdown
Contributor

Description

Number of arenas greater than 253 causes
the "Resource temporarily unavailable" error
on a machine with 96 cores.

Checklist

  • Code compiles without errors locally
  • All tests pass locally
  • CI workflows execute properly

@ldorau ldorau requested a review from a team as a code owner May 9, 2025 09:26
@ldorau ldorau requested a review from lplewa May 12, 2025 06:36
@ldorau

ldorau commented May 12, 2025

Copy link
Copy Markdown
Contributor Author

@lplewa please review

Comment thread src/pool/pool_jemalloc.c Outdated
@ldorau ldorau force-pushed the Fix_maximum_number_of_arenas_in_op_initialize branch from 3596017 to 77bd1f6 Compare May 12, 2025 08:36
@ldorau ldorau requested a review from bratpiorka May 12, 2025 08:38
Comment thread src/pool/pool_jemalloc.c Outdated
LOG_ERR("Could not create arena.");
// EAGAIN - means that a memory allocation failure occurred
// (2 * utils_get_num_cores()) is the required minimum number of arenas
if (err == EAGAIN && (i >= (2 * utils_get_num_cores()))) {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

If user set arenas number param, we should create all of them or fail.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Done

Number of arenas greater than 253 causes
the "Resource temporarily unavailable" error
on a machine with 96 cores.

Signed-off-by: Lukasz Dorau <lukasz.dorau@intel.com>
@ldorau ldorau force-pushed the Fix_maximum_number_of_arenas_in_op_initialize branch from 77bd1f6 to fd7a862 Compare May 13, 2025 06:26
@lukaszstolarczuk

Copy link
Copy Markdown
Collaborator

👍

@ldorau ldorau requested a review from lplewa May 13, 2025 09:03
@lukaszstolarczuk lukaszstolarczuk merged commit 43d33c2 into oneapi-src:main May 13, 2025
166 of 170 checks passed
@ldorau ldorau deleted the Fix_maximum_number_of_arenas_in_op_initialize branch May 13, 2025 13:17
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.

4 participants