Open
Description
It appears this code has been copy-pasted 4 times:
- src/coreclr/gc/unix/cgroup.cpp
- src/coreclr/nativeaot/Runtime/unix/cgroupcpu.cpp
- src/coreclr/pal/src/misc/cgroup.cpp
- src/mono/mono/utils/mono-cgroup.c
I'm guessing a good place to put a consolidated implementation is in src/native/minipal/.
There is also a fifth copy written in C# at src/libraries/Common/src/Interop/Linux/cgroups/Interop.cgroups.cs. I'm not sure if it is worthwhile to change the C# code to delegated to a common unmanaged implementation.