mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-06-28 07:18:30 +00:00
Perform some code cleanup
This commit is contained in:
parent
174d288e66
commit
fe3216e961
14 changed files with 803 additions and 312 deletions
|
@ -488,13 +488,11 @@ static int CloneLinux(int (*func)(void *arg, int tid), char *stk, size_t stksz,
|
|||
// COSMOPOLITAN
|
||||
|
||||
/**
|
||||
* Creates thread without malloc being linked, e.g.
|
||||
* Creates thread without malloc being linked.
|
||||
*
|
||||
* int worker(void *arg) {
|
||||
* return 0;
|
||||
* }
|
||||
* If you use clone() you're on you're own, e.g.
|
||||
*
|
||||
* // NOTE: See _mktls() for _Thread_local support.
|
||||
* int worker(void *arg) { return 0; }
|
||||
* struct CosmoTib tib = {.tib_self = &tib, .tib_tid = -1};
|
||||
* char *stk = _mapstack();
|
||||
* tid = clone(worker, stk, GetStackSize() - 16,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue