14 ms·
On Solaris/Illumos `putenv()` and `getenv()` are lock-less and really fast. Basically, if you `putenv()`, you commit to never freeing that memory.
by cryptonector 3y ago
On Solaris/Illumos `putenv()` and `getenv()` are lock-less and really fast.
Basically, if you `putenv()`, you commit to never freeing that memory.
- xy2_ 3y agoputenv is not lock free: https://github.com/illumos/illumos-gate/blob/master/usr/src/lib/libc/port/gen/getenv.c#L222C2-L222C13 https://github.com/illumos/illumos-gate/blob/master/usr/src/...
- cryptonector 3y agoAy, yes. Though it could be made lock-less.