gramine icon indicating copy to clipboard operation
gramine copied to clipboard

[LibOS] Add support for `getcpu` syscall

Open vijaydhanraj opened this issue 3 years ago • 2 comments

Description of the changes

This PR was dependent on sysfs rewrite. Now that it is done, reviving this PR.

This commit adds an approx. implementation of getcpu syscall that returns a random set bit from cpu affinity mask associated with calling thread and its corresponding NUMA node.

pthread_set_get_affinity regression test is extended to validate this implementation. This commit also enables the getcpu01 ltp test for non-SGX case.

Closes https://github.com/gramineproject/graphene/pull/2331

How to test this PR?

Please run pthread_set_get_affinity LibOS regression test.


This change is Reviewable

vijaydhanraj avatar May 26 '22 02:05 vijaydhanraj

@vijaydhanraj We should rebase this PR, right?

dimakuv avatar Aug 02 '22 17:08 dimakuv

@dimakuv Yes correct. Working on it.

vijaydhanraj avatar Aug 02 '22 18:08 vijaydhanraj

Jenkins, test this please

boryspoplawski avatar Aug 25 '22 11:08 boryspoplawski

Jenkins, test this please

boryspoplawski avatar Aug 25 '22 19:08 boryspoplawski

Jenkins, test this please

dimakuv avatar Sep 06 '22 14:09 dimakuv

Jenkins, test this please

dimakuv avatar Sep 06 '22 18:09 dimakuv