How should wasi-libc handle `POLLPRI`?
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 25/100
- Tipo di issue
- Funzionalità
- Chiarezza
- Da chiarire
- Stato di attività
- Ferma
- Stack tecnologico
- c, wasm
- Ambito
- api, operating-systems
Direzione di ricerca
Inizia esaminando la PR #754 e la descrizione della issue relativa alla gestione di select, pselect e poll per POLLPRI. Raccogli opinioni sul fatto che POLLPRI debba essere esportato e che poll debba ignorarlo o restituire ENOSYS; il lavoro è completato quando il progetto raggiunge e documenta una decisione chiara sul comportamento.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
In https://github.com/WebAssembly/wasi-libc/pull/754 it was discovered that there are applications, such as vim, which set the exceptfds argument to the select and pselect functions. The man pages for these functions indicate that this argument corresponds to the POLLPRI argument to the poll function. Prior to #754 wasi-libc didn't define POLLPRI as a constant and also returned an ENOSYS error if exceptfds was set for either select or pselect. In #754 this behavior has now changed where POLLPRI is defined, select and pselect thread fds to poll with POLLPRI set, and poll has some handling now. Specifically in poll it effectively ignores POLLPRI unless everything is exclusively waiting on that event in which case ENOSYS is returned.
I'm opening this issue to have some further discussion of this and see if anyone else has thoughts on this as well. Specific questions I would have are:
-
Is anyone opposed to exposing
POLLPRIin wasi-libc? Personally I feel this is justified because we already can't statically rule out settingexceptfdsarguments inselectandpselect. We've also found additionally over time that it's easier to provide constants/functions than to not provide them at all and ask applications to work around the lack of posix/unix/etc functionality. (at least in some cases, not necessarily all). Nevertheless I wanted to pose the question here: does anyone feel strongly thatPOLLPRIshould not be exported by wasi-libc? -
Regardless of whether
POLLPRIis publicly exported or not, what should the behavior ofexceptfdsbe withselectandpselect? I still frame this in my head asPOLLPRIsinceselectandpselectare effectively justpollin a different veneer personally. In my opinion we should interpretPOLLPRIas effectively an event that never happens right now in wasi-libc since it's not hooked up to anything. The man page forPOLLPRIsays it's for things like TCP out-of-band data and some ioctl/tty things I don't know about, but nevertheless WASI has no concept of either of these. Given that I'd personally say that we should consider this as an event that basically never fires. -
If others agree with me that we should interpret
POLLPRIas an event that never fires (yet, there's an orthogonal open question of whether WASI should provide functionality to support this), then do others disagree with changing the behavior ofpoll? I'd say thatpollshould probably just ignorePOLLPRIentirely and it turns into a glorified version ofsleepif you happen to wait exclusively on things withPOLLPRI. Otherwise if you wait on a mixture ofPOLLPRIand other things it's just as-if thePOLLPRIthing never fired.
cc @paralin as the author of #754, and cc @sunfishcode as you might have thoughts on API-side of things here too.
- Lingua principale
- C
- Stelle
- 1k
- Fork
- 268
- Merge medio
- 1g 3h
- PR unite (30g)
- 20
Preparare l'ambiente
Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di WebAssembly/wasi-libc
-
wasip2: enabling O_APPEND with fcntl reuses the old positional output stream and overwrites the fileAperta
Difficoltà 3/5 1-2 giorni Idoneità per principianti 70/100
WebAssembly/wasi-libc#919 ·
I maintainer di solito rispondono entro 1 giorno
-
wasip2/wasip3: reads never see data appended to a file after reaching EOFForse già presa @libsmol l’ha presa 25 giorni fa. Aperta
Difficoltà 3/5 1-2 giorni Idoneità per principianti 61/100
WebAssembly/wasi-libc#889 ·
I maintainer di solito rispondono entro 1 giorno
-
Contradicting `SOL_TCP` and `SOL_UDP` definition for p1Forse di nuovo libera Una pull request per questa issue è stata chiusa senza essere unita. Aperta
Difficoltà 3/5 1-2 giorni Idoneità per principianti 45/100
WebAssembly/wasi-libc#855 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 55/100
WebAssembly/wasi-libc#815 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 45/100
WebAssembly/wasi-libc#809 · 2 commenti ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di WebAssembly/wasi-libc
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
OpenPrinting/cups#1826 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
389ds/389-ds-base#8152 ·
I maintainer di solito rispondono entro 2 giorni
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
RetroAchievements/rcheevos#580 · 1 commento ·
I maintainer di solito rispondono entro 5 giorni
-
meta:feature-request
Difficoltà 2/5 1-3 ore Idoneità per principianti 66/100
mpv-player/mpv#18855 · 2 commenti ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno