aboutsummaryrefslogtreecommitdiffstats
path: root/erts
AgeCommit message (Collapse)Author
2019-03-05[socket] Make use of official monitor to term functionMicael Karlberg
Remove own function to make monitor printable (was a hack) and make use of the new enif_make_monitor_term instead.
2019-03-04Merge branch 'bmk/20190304/openindiana_types' into ↵Micael Karlberg
bmk/20190301/cleanup_through_macro_abuse/OTP-15565
2019-03-04[socket] Fixed various type size and unused function warningsMicael Karlberg
Fixed some type size warnings (SCTP related). E.g: On Solaris 11 (OpenIndiana Hipster) long and int is size 4, but the way Sint32 def works it first "tests" for long size and if that is correct, that is chosen (which it is on Solaris 11). On linux long is size 8, so Sint32 will be defined as int. ... On Solaris 11 the flags TCP_CONGESTION and SO_BINDTODEVICE does not exist, so the function(s) n[set|get]opt_str_opt is never used. So, in order to keep the compiler quiet, we add some if-def to exclude these functions in this case.
2019-03-04[socket] Some minor cleanup and commentsMicael Karlberg
2019-03-04[socket] Macro abuse for requestor queue func defMicael Karlberg
The requestor (acceptor, writer and reader) functions are virtually identical, so to ensure quality and not having to write the exact same functions three times, we make use of some macro magic for their declaration. OTP-15565
2019-03-04[net] Macro abuse for func defMicael Karlberg
Some more macro abuse for nif API callback functions. OTP-15565
2019-03-04[socket] Macro abuse for more func defMicael Karlberg
Some more macro abuse for nif API callback functions and the operator (acceptor, writer and reader) queue wrapper functions (search4pid, push, pop and unqueue). OTP-15565
2019-03-04[socket] Macro abuse for setopt(otp) and getopt(otp)Micael Karlberg
2019-03-04[socket|net] Macro abuseMicael Karlberg
Make use of macro concat magic to simplify declarations. OTP-15565
2019-03-04Merge branch 'bmk/20190301/socket_test_cleanup'Micael Karlberg
2019-03-04Merge branch 'maint'Siri Hansen
2019-03-04Merge branch 'siri/logger/os-timestamp/OTP-15625' into maintSiri Hansen
* siri/logger/os-timestamp/OTP-15625: Update preloaded [logger] Change timestamp from erlang:system_time to os:system_time
2019-03-04Merge branch 'bmk/20190301/net_test/OTP-15635'Micael Karlberg
2019-03-04Merge pull request #2167 from bjorng/bjorn/tune-beamBjörn Gustavsson
Tune BEAM instructions for the new compiler (part 1)
2019-03-01Add a howto for counting instructionsBjörn Gustavsson
2019-03-01Combine is_nonempty_list with get_hd/get_tlBjörn Gustavsson
The is_nonempty_list test is very frequently followed by get_tl, and frequently followed by get_hd.
2019-03-01Remove the combined instruction is_nonempty_list_test_heapBjörn Gustavsson
It turns out that the combination of is_nonempty_list and test_heap is no longer frequent.
2019-03-01Combine more init instructionsBjörn Gustavsson
2019-03-01Combine test_arity with get_tuple_elementBjörn Gustavsson
The test_arity instruction is often followed by get_tuple_element.
2019-03-01Combine get_tuple_element when destinations are not consecutiveBjörn Gustavsson
2019-03-01[socket|test] Quiet logger and ttest improvementsMicael Karlberg
Add a quiet logger mode (default) which limits the printouts in the (erlang) shell (the web log will be as verbose as usual). Also added a way to configure the runtime of the ttest cases.
2019-03-01[socket|test] Moved old test modulesMicael Karlberg
Moved the old socket test modules into its own (temporary?) directory.
2019-03-01[net] Fixed name_and_addr_info test caseMicael Karlberg
The test case did not consider that the machine might have both IPv4 (inet) and IPv6 (inet6) domain interfaces. OTP-15635
2019-03-01[net] Fixed getnameinfo functionMicael Karlberg
The getnameinfo function has been fixed: 1) Faulty sockaddr decode success check 2) Incorrect (name info) return value OTP-15636
2019-03-01[net|test] Add "proper" test suiteMicael Karlberg
Add a (basically) placeholder test suite for the net module. OTP-15635
2019-02-28Remove rarely used swap instructionsBjörn Gustavsson
`swap x y` is rarely or never used. I found a single use of `swap_temp x y x` in the sample of modules compiled by `scripts/diffable`.
2019-02-28Tune move instructionsBjörn Gustavsson
Of the `move_dup` instructions, only `move_dup x x x` was frequently used. Remove the other register combinations. With those instruction `move_dup` instructions removed, it is necessary to add new predicates to avoid unsafe translation to `move_shift` and `move2_par`. Also add additional transformations to transform more `move` instructions into `move2_par`. The existing transformation would require the `move` instructions to be in the "right" order in order to be transformed. Remove `move3 x y x y x y` because it turns out to be rarely executed.
2019-02-28erts: Fix erl_printf on SolarisJohn Högberg
flockfile(3c) and friends are hidden behind the __EXTENSIONS__ feature macro.
2019-02-28erts: Stop using madvise(2) on SolarisJohn Högberg
inet_drv adds some arcane #defines to get SCTP working, which may end up disabling madvise(2) locally in that file, breaking the build in the process. This commit disables madvise(2) altogether on Solaris as it's far simpler than undoing the define dance in erl_mmap.h.
2019-02-27beam_validator: Tolerate the 'receive' hack in prim_evalJohn Högberg
2019-02-25Merge branch 'siri/rsh-ssh/PR-1787'Hans Bolinder
OTP-15633 * siri/rsh-ssh/PR-1787: Fix some missed comments about rsh Document the restrictions on the -rsh command Use ssh as the default remote shell
2019-02-25erts: Fix broken link in documentationSverker Eriksson
2019-02-25Merge pull request #2124 from kjellwinblad/kjell/stdlib/iolist_size_trapKjell Winblad
Make iolist_size/1 yield OTP-15631
2019-02-25Make iolist_size/1 yieldKjell Winblad
The iolist_size/1 function did not yield even if the input list was very long and a call to the function did only consume a single reduction. This commit fixes these problems.
2019-02-25Merge branch 'rickard/deprecations-removals'Rickard Green
OTP-15621 OTP-15622 * rickard/deprecations-removals: Document deprecations and removals
2019-02-25Document deprecations and removalsRickard Green
2019-02-23Merge branch 'maint'Rickard Green
* maint: erts: Fix macro redefinition
2019-02-22erts: Fix macro redefinitionBjörn-Egil Dahlberg
LIST_NEXT and LIST_PREV causes macro redefinitions from other include files. beam/erl_ao_firstfit_alloc.c:103:9: warning: 'LIST_NEXT' macro redefined [-Wmacro-redefined] ^ /usr/include/sys/queue.h:507:9: note: previous definition is here ^ 1 warning generated. beam/erl_bestfit_alloc.c:125:9: warning: 'LIST_NEXT' macro redefined [-Wmacro-redefined] ^ /usr/include/sys/queue.h:507:9: note: previous definition is here ^
2019-02-22Merge branch 'bmk/20190204/socket_as_nif/OTP-14831'Micael Karlberg
2019-02-22[socket] Cleanup and accept restructureMicael Karlberg
Some cleanup (of open, bind, connect) and rewrote the accept code (moved the code into smaller functions). OTP-14831
2019-02-22[socket] More fixes to socket closeMicael Karlberg
Better handling of socket close. The 'closeRef' needed its own environment to make if work in both cases (both called and scheduled). Also Introduced the enif select wrapper functions (read, write, stop and cancel). Also add error handling at every time one of these functions are called. OTP-14831
2019-02-22[socket|doc] Improve the examplesMicael Karlberg
2019-02-22[socket|net|doc] Add 'since' tagMicael Karlberg
Add 'since' tag to the module and func elements. OTP-14831
2019-02-22[socket|doc] Fixed IPv6 PKTINFO typeMicael Karlberg
Another broken anchor fixed. The type 'ipv6_pktinfo' was not exported nor was it part of the doc. OTP-14831
2019-02-22[spocket|net] Updated preloaded app fileMicael Karlberg
Had for some reason forgot to update the (erts) preloaded app-file. OTP-14831
2019-02-22[socket|net|doc] Fixed broken anchorsMicael Karlberg
Fixed broken links to types and functions. OTP-14831
2019-02-22[socket] Fixed socket close bugMicael Karlberg
Fixed a raise condition bug in the socket_stop (callback) function that could result in the socket actually *not* beeing closed. OTP-14831
2019-02-22[net] Deprecated functions needs attributeMicael Karlberg
Add the 'depricated' attribute for the old (and decrepit) functions from the old net module. OTP-14831
2019-02-22[socket|doc] Forgot to run xmllint (again)Micael Karlberg
2019-02-22[socket|doc] Fixed links and stuffMicael Karlberg
Corrected linking references (links) to functions. Also added links from getopt/setopt functions to the users guide. Also added some comments to the socket module regarding open with (ready made) descriptor (which is not yet supported). OTP-14831