Skip to content

Commit

Permalink
Merge pull request #576 from hermit-os/sys_available_parallelism
Browse files Browse the repository at this point in the history
feat(abi): add `sys_available_parallelism`
  • Loading branch information
mkroening authored May 16, 2024
2 parents 7a238e0 + f8fc1d2 commit f3ad271
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions hermit-abi/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -507,6 +507,9 @@ extern "C" {
#[link_name = "sys_fstat"]
pub fn fstat(fd: i32, stat: *mut stat) -> i32;

#[link_name = "sys_available_parallelism"]
pub fn available_parallelism() -> usize;

/// determines the number of activated processors
#[link_name = "sys_get_processor_count"]
pub fn get_processor_count() -> usize;
Expand Down

0 comments on commit f3ad271

Please sign in to comment.