Commit Graph

63 Commits

Author SHA1 Message Date
flywind
70ec17eede use single backtick (#17133) 2021-02-21 00:27:39 -08:00
ee7
297c8e403d styleCheck: Fix some inconsistent identifiers (#16177) 2020-12-21 09:41:56 -08:00
flywind
b38f0403fd fix #12471 (#15901)
* fix #12471

* add testcase

* fix

* test nimdoc is tricky

* Delete t12471.nim
2020-11-10 13:15:16 +01:00
Andreas Rumpf
2671efab78 async: minor refactorings (#15354) 2020-09-18 11:22:34 +02:00
Jaremy Creechley
a76ae8f795 Changes for FreeRTOS/LwIP Port for the ESP32 (ESP-IDF) (#15250)
* Changes for FreeRTOS/LwIP Port for the ESP32 (ESP-IDF)

Adding FreeRTOS/LwIP to compiler:

* adding freertos option
* dyncalls for freertos
* add freertos to posix os list
* adding lwip option

Setting up networking FreeRTOS/LwIP Port:

* setting up lwip network for freertos
* fixing posix / networking for freertos
* disable setInheritable for freerots
* using lwip for net control items

* Fix builds by ignoring lib/posix/posix_freertos_consts.nim similar to lib/posix/posix_other_consts.nim
2020-08-31 11:48:54 +02:00
flywind
2d494f42f3 minor improvement (#15155) 2020-08-04 11:29:57 +02:00
Miran
e7f280bd26 Remove deprecated stuff from stdlib (#14699)
* update to the latest Jester

* remove deprecated procs from some stdlib modules

* 'criterion' is not maintained anymore and relies on obsolete stuff
2020-06-17 15:25:02 +02:00
Dominik Picheta
7361e2627b Emscripten: disable epoll (#14361)
Epoll is not supported by epoll.
2020-05-16 15:50:41 +02:00
hlaaftana
01523b2b58 change some Exceptions to CatchableError or Defect, fixes #10288 (#14069) 2020-04-22 16:49:41 +02:00
Timothee Cour
6e0c06f50e fix #13218: avoid some irrelevant warnings for nim doc,rst2html,--app:lib, + other fixes (#13550)
* fix #13218: avoid some irrelevant warnings for nim doc,rst2html
* suppress warnRedefinitionOfLabel for nim doc
* lots of fixes for UnusedImport warnings
2020-03-13 20:42:41 +01:00
Federico Ceratto
39290cf88c Fix spellings (#12277) [backport] 2019-09-27 07:02:54 +02:00
Araq
791abfbc16 selectors: exceptions are for errors, not for bugs 2019-05-15 18:19:17 +02:00
Dominik Picheta
d0b8724aa2 Fixes crashes when asyncdispatch.adjustTimeout returns a negative value. (#11231) 2019-05-15 18:15:10 +02:00
Ico Doornekamp
0229dfd199 epoll selector starts with reasonable fd set size (1024) and increases in powers of two when needed. This prevents the selector to allocate large amounts of memory at startup on systems with a high RLIMIT_NOFILE setting (#10194) 2019-01-09 10:46:22 +01:00
Yuriy Glukhov
34f398d010 Allow async stdin 2018-07-25 09:07:50 +03:00
Joey
559a7615ad Nintendo switch support (#8069)
* Add config section for Nintendo Switch
* Add compiler configuration for Nintendo Switch and it's CPU
* Add specific lib code for Nintendo Switch
* Add GC support for Nintendo Switch
* Update changelog for Nintendo Switch
* Update changelog with more info about fixed paths
* Cleaned up GC memory management a bit
* Relocate docs for Switch
* Rename aarch64NoneElfGcc to nintendoSwitchGCC
* Remove armv8a57
* Fix installer.ini
* Reuse code in linux and amd64
* Add posix defs for nintendo switch
* Add more defined sections for nintendo switch
* Remove old comment
* Add what's not supported for Nintendo Switch docs
* Make nintendoswitch == posix
* Remove DEVKITPRO references from nim.cfg
* Make PR extccomp changes
* Remove Result type alias
* Add separate switch consts file
* Update docs for nintendo switch
* Fix travis errors with undefined consts and add correct wait.h procs
2018-06-27 12:35:09 +02:00
Araq
bbb0fd4eb7 remove deprecated stuff from the stdlib; introduce better deprecation warnings 2018-05-05 21:45:07 +02:00
Dominik Picheta
1a2351f95f Fixes #4995. (#7157) 2018-02-13 11:08:37 +01:00
Andreas Rumpf
5e43e0d789 Merge branch 'devel' into async-improvements 2017-12-11 15:12:45 +01:00
Emery Hemingway
3181f3b04c favor 'select' over 'poll' on Genode (#6821)
The 'poll' of the Genode C runtime is a wrapper over 'select'.
2017-12-01 02:39:16 +01:00
Dominik Picheta
d6870f2e89 Multiple improvements to selectors.
* Added ``getFd`` procedure for retrieving the underlying
  selector's FD.
* Selectors module's procedures now accept an ``int`` as well as a
  ``SocketHandle``.
* ReadyKey now contains the error code for Event.Error events.
2017-11-24 16:25:03 +00:00
Dominik Picheta
d3394be555 Async upcoming (#6585)
* Merge upcoming async with current.
* Various improvements to selectors (mostly docs).

Two changes to highlight:

* Renamed ``setEvent`` to ``trigger``
* Reused setBlocking from nativesockets.
* Various changes/fixes to asyncdispatch after upcoming merge.
* Make some attempts to be compatible with older selectors.
* Reuse epoll module in ioselectors_epoll.
2017-11-22 15:43:10 +01:00
Andreas Rumpf
6a3288a60e more replacements for the deprecated '<' 2017-10-29 08:55:30 +01:00
Andreas Rumpf
0ca58120b7 docgen fixes for selectors.nim 2016-09-26 19:26:39 +02:00
Dominik Picheta
5bf16439e1 Fixes #4262. 2016-09-17 13:22:04 +02:00
cheatfate
efb4d97467 Resolve #4334 2016-06-14 17:22:34 +03:00
def
c50b5b62ef Fix a few deprecation warnings 2016-01-25 19:10:37 +01:00
Dominik Picheta
29a40e37d5 Use nanoseconds for timeouts less than 1 second on Mac OS X. 2015-11-01 11:28:11 +00:00
Dominik Picheta
ae48f26798 Fix poll's timeout for Mac OS X in the seletors module. 2015-11-01 10:37:04 +00:00
Adam Strzelecki
4c537bd1e5 selectors: Cleanup a bit epoll flavor
1. Remove select documentation that is duplicate of nimdoc section below

2. Simplify a bit register proc code
2015-09-29 19:28:10 +02:00
Adam Strzelecki
248f52fea7 Selectors using OS X & Free/Open/NetBSD kqueue API 2015-09-29 19:27:41 +02:00
Sergey Avseyev
7f03ad416e Fix nimdoc generation for lib/pure/selectors.nim 2015-07-09 18:36:47 +03:00
Araq
62cea4e29c prepared selectors module for multi threading 2015-06-30 13:39:14 +02:00
Araq
28de800d61 Merge branch 'more_concurrency' into devel
Conflicts:
	doc/tut1.txt
	lib/core/locks.nim
	lib/pure/collections/tables.nim
	lib/pure/selectors.nim
2015-06-30 12:50:24 +02:00
pdw
d18e18060e lib/pure/p-t - Dropped 'T' from types 2015-06-04 13:18:36 +02:00
Araq
21ea8e6913 some progress on making async multithreaded 2015-05-28 12:49:08 +02:00
Oleh Prypin
32109a7867 Don't run non-test code when defined(testing) 2015-04-21 14:37:29 +03:00
def
7898e91c32 Clean up selectors documentation a bit 2015-02-24 16:37:04 +01:00
Federico Ceratto
657dca5c3b Fix typos 2015-02-15 16:20:32 +00:00
Araq
41385f3aaf made a test green 2015-02-12 14:56:57 +01:00
Elie Zedeck
1845e05a34 Handle EPOLLHUP to avoid chaos/runaways when using certain file descriptors.
A concrete example is pipe file descriptors: they generate EPOLLHUP instead of a EPOLLIN (then 0 bytes read). The loop will run wild if this event is not handled.
2015-01-21 18:15:38 +03:00
def
519ec304e4 Fix: Only handle EPOLLERR as an error event
When an EPOLLRDHUP is received with epoll_ctl, there can still be data
to be read. So we shouldn't immediately close the socket and abort.
2015-01-13 00:45:17 +01:00
Guillaume Gelin
3119fe087d Happy new year! 2015-01-06 15:26:33 +01:00
def
f56dcd1505 Handle interrupt on epoll_wait graciously (allows strace to work) 2015-01-04 23:07:21 +01:00
def
d60d007281 Close async socket on error (instead of looping on epoll_wait with 100% CPU) 2015-01-04 22:59:41 +01:00
Araq
7333237be6 'nimfix' improvements; FdSet is TFdSet again 2014-09-08 08:46:35 +02:00
Araq
11b6958755 big rename 2014-08-27 23:42:51 +02:00
Dominik Picheta
cf5c8a204e Many async optimisations.
* Selectors implementation will now attempt to immediately execute an IO
  operation instead of waiting for a ready notification.
* Removed recursion in asynchttpserver.
* Improved buffered implementation of recvLine in asyncnet.
* Optimised ``respond`` in asynchttpserver removing a possible "Delayed ACK"
  situation.
2014-07-12 22:51:06 +01:00
Varriount
1d6c05edc3 Update selectors.nim 2014-05-25 12:20:24 -04:00
Varriount
f10f9c4b7e Update selectors.nim
Fixed selectors.nim on macosx
2014-05-25 11:35:10 -04:00