From 606e660f898264ea75680532c076c56bbe855633 Mon Sep 17 00:00:00 2001 From: Lukas Larsson Date: Fri, 1 Jul 2016 17:32:51 +0200 Subject: erts: Review of documentation changes --- erts/doc/src/absform.xml | 24 +++++----- erts/doc/src/alt_dist.xml | 22 +++++----- erts/doc/src/crash_dump.xml | 24 +++------- erts/doc/src/driver.xml | 18 ++++---- erts/doc/src/epmd.xml | 6 +-- erts/doc/src/erl.xml | 39 +++++++++++++++-- erts/doc/src/erl_dist_protocol.xml | 22 +++++----- erts/doc/src/erl_driver.xml | 26 +++++------ erts/doc/src/erl_ext_dist.xml | 4 +- erts/doc/src/erl_nif.xml | 21 +++++---- erts/doc/src/erl_tracer.xml | 4 +- erts/doc/src/erlang.xml | 89 +++++++++++++++++++------------------- erts/doc/src/erts_alloc.xml | 25 +++-------- erts/doc/src/inet_cfg.xml | 26 +++++------ erts/doc/src/match_spec.xml | 16 +++---- erts/doc/src/ref_man.xml | 2 +- erts/doc/src/run_erl.xml | 6 +-- erts/doc/src/time_correction.xml | 6 +-- erts/doc/src/werl.xml | 2 +- 19 files changed, 194 insertions(+), 188 deletions(-) diff --git a/erts/doc/src/absform.xml b/erts/doc/src/absform.xml index c7f1285879..174ad9c640 100644 --- a/erts/doc/src/absform.xml +++ b/erts/doc/src/absform.xml @@ -32,7 +32,7 @@ A absform.xml -

This secion describes the standard representation of parse trees for Erlang +

This section describes the standard representation of parse trees for Erlang programs as Erlang terms. This representation is known as the abstract format. Functions dealing with such parse trees are @@ -41,21 +41,21 @@ - stdlib:epp + stdlib:epp(3) - stdlib:erl_eval + stdlib:erl_eval(3) - stdlib:erl_lint + stdlib:erl_lint(3) - sdlib:erl_parse + sdlib:erl_parse(3) - stdlib:erl_pp + stdlib:erl_pp(3) - stdlib:io + stdlib:io(3) -

The functions are also used as input and output for parse transforms (see - the compiler:compile +

The functions are also used as input and output for parse transforms, see + the compiler:compile(3) module.

We use the function Rep to denote the mapping from an Erlang source @@ -177,8 +177,8 @@ Representation of Parse Errors and End-of-File

In addition to the representations of forms, the list that represents a module declaration (as returned by functions in - stdlib:epp and - sdlib:erl_parse) + stdlib:epp(3) and + sdlib:erl_parse(3)) can contain the following:

@@ -216,7 +216,7 @@ -

Notice that negative integers and float literals do not occur as such; +

Notice that negative integer and float literals do not occur as such; they are parsed as an application of the unary negation operator.

diff --git a/erts/doc/src/alt_dist.xml b/erts/doc/src/alt_dist.xml index 67d30a03c2..f3e3260230 100644 --- a/erts/doc/src/alt_dist.xml +++ b/erts/doc/src/alt_dist.xml @@ -33,7 +33,7 @@ PA2 alt_dist.xml -

This section describes how to implement an own carrier +

This section describes how to implement an alternative carrier protocol for the Erlang distribution. The distribution is normally carried by TCP/IP. Here is explained a method for replacing TCP/IP with another protocol.

@@ -169,11 +169,10 @@ necessity.

The driver data types and the functions available to the driver - writer are defined in header file (there - is also a deprecated version called , do not - use that one) seated in Erlang's include directory (and in - $ERL_TOP/erts/emulator/beam in the source code - distribution). See that file for function prototypes, and so on.

+ writer are defined in header file + seated in Erlang's include directory. See the + erl_driver documentation + for details of which functions are available.

When writing a driver to make a communications protocol available to Erlang, one should know just about everything worth knowing @@ -440,9 +439,8 @@ uds_finish

Called when the driver is unloaded. A distribution driver will - actually (or hopefully) never be unloaded, but we include this for - completeness. To be able to clean up after oneself is always a good - thing.

+ never be unloaded, but we include this for completeness. To be + able to clean up after oneself is always a good thing.

uds_control @@ -465,9 +463,9 @@

While informs different subsystems that the connection is coming up, the port is to accept data to send. - However, the port receives no data, to avoid that data arrives from - another node before every kernel subsystem is prepared to handle it. - A third mode, named intermediate, is used for this + However, the port should not receive any data, to avoid that data + arrives from another node before every kernel subsystem is prepared + to handle it. A third mode, named intermediate, is used for this intermediate stage.

An enum is defined for the different types of ports:

diff --git a/erts/doc/src/crash_dump.xml b/erts/doc/src/crash_dump.xml index f143be87d6..d55ab222a7 100644 --- a/erts/doc/src/crash_dump.xml +++ b/erts/doc/src/crash_dump.xml @@ -37,11 +37,9 @@

The Erlang crash dump had a major facelift in Erlang/OTP R9C. The - information - in this section is therefore not directly applicable for older dumps. - However, if you use the - crashdump_viewer tool in the Observer application - on older dumps, + information in this section is therefore not directly applicable for + older dumps. However, if you use + observer:crashdump_viewer(3) on older dumps, the crash dumps are translated into a format similar to this.

@@ -94,8 +92,7 @@
 Slogan: <reason>
-

(The word "slogan" has historical roots.) - If the system is halted by the BIF +

If the system is halted by the BIF , the slogan is the string parameter passed to the BIF, otherwise it is a description generated by the emulator or the (Erlang) kernel. Normally the message @@ -221,7 +218,7 @@ Slogan: <reason> Scheduler Information

Under the tag =scheduler is shown information about the current state and statistics of the schedulers in the runtime system. On - operating systems that allow instant suspension of other threads, the + operating systems that allow suspension of other threads, the data within this section reflects what the runtime system looks like when a crash occurs.

@@ -438,13 +435,6 @@ Slogan: <reason>

The amount of unused memory on each heap. This information is usually useless.

- Stack - -

If the system uses shared heap, the fields - Stack+heap, OldHeap, Heap unused, - and OldHeap unused do not exist. Instead this field - shows the size of the process stack.

-
Memory

The total memory used by this process. This includes call stack, @@ -532,8 +522,8 @@ Slogan: <reason> Fixed

If the table is fixed using - - ets:safe_fixtable or some internal mechanism.

+ + ets:safe_fixtable/2 or some internal mechanism.

Objects diff --git a/erts/doc/src/driver.xml b/erts/doc/src/driver.xml index 2dae01b143..8f31df4cad 100644 --- a/erts/doc/src/driver.xml +++ b/erts/doc/src/driver.xml @@ -114,7 +114,7 @@

The entry is called from the emulator when the Erlang code calls , to do the actual work. We have defined a simple set of - commands: to log on to the database, + commands: to log in to the database, to log out, and to send a SQL-query and get the result. All results are returned through . @@ -127,7 +127,7 @@ directory of .

The driver entry contains the functions that - will be called by the emulator. In this simple example, + will be called by the emulator. In this example, only , , and are provided:

@@ -179,7 +179,7 @@ typedef struct our_data_s { #define DRV_SELECT 'S' ]]> -

This only returns the driver structure. The macro +

This returns the driver structure. The macro defines the only exported function. All the other functions are static, and will not be exported from the library.

@@ -274,9 +274,9 @@ static int control(ErlDrvData drv_data, unsigned int command, char *buf, } ]]> -

is where we log on to the database. If the +

is where we log in to the database. If the connection was successful, we store the connection handle in the driver - data, and return OK. Otherwise, we return the error message + data, and return 'ok'. Otherwise, we return the error message from postgres and store in the driver data.

If we are connected (and if the connection handle is not ), we log out from the database. We need to check if we should - encode an OK, as we can get here from function , - which does not return data to the emulator:

+ encode an 'ok', as we can get here from function + , which does not return data to the emulator:

Here we check the result from postgres. If it is data, we encode it as lists of lists with column data. Everything from postgres is C strings, - so we only use to send + so we use to send the result as strings to Erlang. (The head of the list contains the column names.)

@@ -391,7 +391,7 @@ void encode_result(ei_x_buff* x, PGresult* res, PGconn* conn)

Before a driver can be called from Erlang, it must be loaded and opened. Loading is done using the module (the driver that loads dynamic - driver is actually a driver itself). If loading is OK, + driver is actually a driver itself). If loading is successfull, the port can be opened with . The port name must match the name of the shared library and the name in the driver entry structure.

diff --git a/erts/doc/src/epmd.xml b/erts/doc/src/epmd.xml index 7b026e17f8..120ffb6860 100644 --- a/erts/doc/src/epmd.xml +++ b/erts/doc/src/epmd.xml @@ -77,7 +77,7 @@ Starting the port mapper daemon

The daemon is started automatically by command - erl + erl(1) if the node is to be distributed and no running instance is present. If automatically launched environment variables must be used to change the behavior @@ -108,7 +108,7 @@ Regular Options

These options are available when starting the name server. The name server is normally started automatically by command - erl (if not already available), + erl(1) (if not already available), but it can also be started at system startup.

@@ -157,7 +157,7 @@

Command epmd -stop (and the corresponding messages to epmd, as can be specified using erl_interface:ei) is + marker="erl_interface:ei">erl_interface:ei(3)) is normally always ignored. This because it can cause a strange situation where two nodes of the same name can be alive at the same time. A node unregisters itself by only closing the diff --git a/erts/doc/src/erl.xml b/erts/doc/src/erl.xml index 5559aec30e..1578d40ef8 100644 --- a/erts/doc/src/erl.xml +++ b/erts/doc/src/erl.xml @@ -128,7 +128,7 @@ which the values can be retrieved by calling . Notice that the list of user flags is not exhaustive, there can be more application-specific - flags that instead are doscribed in the corresponding + flags that instead are described in the corresponding application documentation.

(init flag) @@ -580,7 +580,7 @@

For backward compatibility, the boolean value can be omitted. This is interpreted as +c false.

- erlang:now()ime_warp | single_time_warp | +

Sets time warp @@ -785,6 +785,39 @@

See also io:printable_range/0 in STDLIB.

+ + +

Sets the maximum number of simultaneously existing processes for this + system if a Number is passed as value. Valid range for + Number is [1024-134217727]

+

NOTE: The actual maximum chosen may be much larger than + the Number passed. Currently the runtime system often, + but not always, chooses a value that is a power of 2. This might, + however, be changed in the future. The actual value chosen can be + checked by calling + erlang:system_info(process_limit).

+

The default value is 262144

+
+ + +

Sets the maximum number of simultaneously existing ports for this + system if a Number is passed as value. Valid range for Number + is [1024-134217727]

+

NOTE: The actual maximum chosen may be much larger than + the actual Number passed. Currently the runtime system often, + but not always, chooses a value that is a power of 2. This might, + however, be changed in the future. The actual value chosen can be + checked by calling + erlang:system_info(port_limit).

+

The default value used is normally 65536. However, if + the runtime system is able to determine maximum amount of file + descriptors that it is allowed to open and this value is larger + than 65536, the chosen value will increased to a value + larger or equal to the maximum amount of file descriptors that + can be opened.

+

On Windows the default value is set to 8196 because the + normal OS limitations are set higher than most machines can handle.

+

Sets the compatibility mode.

@@ -1482,7 +1515,7 @@ , the runtime system waits indefinitely for the crash dump file to be written.

This variable is used with - kernel:heart if heart is running:

+ kernel:heart(3) if heart is running:

Suppresses the writing a crash dump file entirely, thus diff --git a/erts/doc/src/erl_dist_protocol.xml b/erts/doc/src/erl_dist_protocol.xml index f1979ac23f..a5949ce15f 100644 --- a/erts/doc/src/erl_dist_protocol.xml +++ b/erts/doc/src/erl_dist_protocol.xml @@ -48,7 +48,7 @@

Authentication (done by - kernel:net_kernel) (3)

+ kernel:net_kernel(3)) (3)

Connected (4)

@@ -573,7 +573,7 @@ io:format("old/unused name ~ts at port ~p, fd = ~p ~n",

Every message in the handshake starts with a 16-bit big-endian integer, which contains the message length (not counting the two initial bytes). In Erlang this corresponds to option {packet, 2} in - kernel:gen_tcp. + kernel:gen_tcp(3). Notice that after the handshake, the distribution switches to 4 byte packet headers.

@@ -716,18 +716,18 @@ TCP connect ------------------------------------> send_name --------------------------------------> recv_name -<---------------------------------------------- send_status + <---------------------------------------------- send_status recv_status (if status was 'alive' send_status - - - - - - - - - - - - - - - - - -> recv_status) ChB = gen_challenge() (ChB) -<---------------------------------------------- send_challenge + <---------------------------------------------- send_challenge recv_challenge ChA = gen_challenge(), OCA = out_cookie(B), -DiA = gen_digest(ChB,OCA) +DiA = gen_digest(ChB, OCA) (ChA, DiA) send_challenge_reply ---------------------------> recv_challenge_reply @@ -738,11 +738,11 @@ send_challenge_reply ---------------------------> OCB = out_cookie(A), DiB = gen_digest (ChA, OCB) (DiB) -<----------------------------------------------- send_challenge_ack + <----------------------------------------------- send_challenge_ack recv_challenge_ack DONE ICA = in_cookie(B), - else: check: CLOSE -DiB == gen_digest(ChA,ICA)? +DiB == gen_digest(ChA, ICA)? - if OK: DONE - else: @@ -754,20 +754,20 @@ DiB == gen_digest(ChA,ICA)? Distribution Flags

The following capability flags are defined:

- -define(DFLAG_PUBLISHED,1). + -define(DFLAG_PUBLISHED,16#1).

The node is to be published and part of the global namespace.

- -define(DFLAG_ATOM_CACHE,2). + -define(DFLAG_ATOM_CACHE,16#2).

The node implements an atom cache (obsolete).

- -define(DFLAG_EXTENDED_REFERENCES,4). + -define(DFLAG_EXTENDED_REFERENCES,16#4).

The node implements extended (3 × 32 bits) references. This is required today. If not present, the connection is refused.

- -define(DFLAG_DIST_MONITOR,8). + -define(DFLAG_DIST_MONITOR,16#8).

The node implements distributed process monitoring.

diff --git a/erts/doc/src/erl_driver.xml b/erts/doc/src/erl_driver.xml index 69c3375858..8e83b74986 100644 --- a/erts/doc/src/erl_driver.xml +++ b/erts/doc/src/erl_driver.xml @@ -111,11 +111,10 @@ sent. This is convenient when matching on messages received from the port. (Although in the latest Erlang versions there is the binary syntax, which enables you to match on the beginning of - a binary.) - -

-

In the runtime system with SMP support, drivers are locked either - on driver level or port level (driver instance level). By default + a binary.)

+

In the runtime system with + SMP support, drivers are locked either on driver level + or port level (driver instance level). By default driver level locking will be used, that is, only one emulator thread will execute code in the driver at a time. If port level locking is used, multiple emulator threads can execute code in the driver @@ -979,7 +978,8 @@ int suggested_stack_size; memory, in which case NULL is returned. (This is most often a wrapper for malloc).

Memory allocated must be explicitly freed with a corresponding - call to driver_free (unless otherwise stated).

+ call to driver_free + (unless otherwise stated).

This function is thread-safe.

@@ -1008,7 +1008,7 @@ int suggested_stack_size;
- longdriver_async (ErlDrvPort port, unsigned + longdriver_async(ErlDrvPort port, unsigned int* key, void (*async_invoke)(void*), void* async_data, void (*async_free)(void*)) Perform an asynchronous call within a driver. @@ -1076,7 +1076,7 @@ r = driver_async(myPort, &myKey, myData, myFunc); ]]> - unsigned intdriver_async_port_key (ErlDrvPort + unsigned intdriver_async_port_key(ErlDrvPort port) Calculate an async key from an ErlDrvPort. @@ -2215,7 +2215,7 @@ r = driver_async(myPort, &myKey, myData, myFunc); ]]> how to use this information. Implementations on some platforms can use other means to determine the consumed fraction of the time-slice. Lengthy driver callbacks should, regardless of - this frequently, call this function to determine if it is allowed + this, frequently call this function to determine if it is allowed to continue execution or not.

This function returns a non-zero value if the time-slice has been exhausted, and zero if the callback is @@ -2433,7 +2433,7 @@ r = driver_async(myPort, &myKey, myData, myFunc); ]]> Try lock a mutex. -

Tries to lock a mutex. A thred that has currently locked the mutex +

Tries to lock a mutex. A thread that has currently locked the mutex cannot try to lock the same mutex again.

mtx is a pointer to a mutex to try to lock.

Returns 0 on success, otherwise EBUSY.

@@ -2562,7 +2562,7 @@ erl_drv_output_term(driver_mk_port(drvport), spec, sizeof(spec) / sizeof(spec[0] works. ERL_DRV_STRING_CONS builds a string list in reverse order (as opposed to how ERL_DRV_LIST works), concatenating the strings added to a list. The tail - must be specifed before ERL_DRV_STRING_CONS.

+ must be specified before ERL_DRV_STRING_CONS.

ERL_DRV_STRING constructs a string, and ends it. (So it is the same as ERL_DRV_NIL followed by ERL_DRV_STRING_CONS.)

@@ -2590,7 +2590,7 @@ erl_drv_output_term(driver_mk_port(drvport), spec, sizeof(spec) / sizeof(spec[0] that is, a term that has been encoded by erlang:term_to_binary, - erl_interface, + erl_interface:ei(3), and so on. For example, if binp is a pointer to an ErlDrvBinary that contains term {17, 4711} encoded with the @@ -2803,7 +2803,7 @@ erl_drv_output_term(driver_mk_port(drvport), spec, sizeof(spec) / sizeof(spec[0] A thread that currently has read or read/write locked the rwlock cannot try to lock the same rwlock again.

rwlckis pointer to an rwlock to try to read/write lock.

-

Returns 0 om success, otherwise EBUSY.

+

Returns 0 on success, otherwise EBUSY.

If you leave an rwlock locked in an emulator thread when you let the thread out of your control, you will diff --git a/erts/doc/src/erl_ext_dist.xml b/erts/doc/src/erl_ext_dist.xml index 2ff0f39a3f..fed41098f8 100644 --- a/erts/doc/src/erl_ext_dist.xml +++ b/erts/doc/src/erl_ext_dist.xml @@ -131,7 +131,7 @@ undefined.

When distribution flag DFLAG_UTF8_ATOMS has been exchanged between both nodes - in th + in the distribution handshake, all atoms in the distribution header are encoded in UTF-8, otherwise in Latin-1. The two new tags ATOM_UTF8_EXT @@ -364,7 +364,7 @@ INTEGER_EXT

- Signed 32-bit integer in big-endian format (that is, MSB first). + Signed 32-bit integer in big-endian format.

diff --git a/erts/doc/src/erl_nif.xml b/erts/doc/src/erl_nif.xml index d154a1bd21..2b627281fe 100644 --- a/erts/doc/src/erl_nif.xml +++ b/erts/doc/src/erl_nif.xml @@ -422,6 +422,7 @@ return term; on a dirty scheduler does not have the same duration restriction as a normal NIF.

+

It is important to classify the dirty job correct. An I/O bound job should be classified as such, and a CPU bound job should be @@ -451,7 +452,7 @@ return term; reclassified and rescheduled using enif_schedule_nif so that it executes on the correct type of dirty scheduler at all times. For more information see the documentation of the - erl command line arguments + erl(1) command line arguments +SDcpu, and +SDio.

While a process executes a dirty NIF, some operations that @@ -1133,8 +1134,8 @@ typedef enum {

If term is the pid of a node local process, this function initializes the pid variable *pid from it and returns - true. Otherwise returns false. No check is done if the - process is alive.

+ true. Otherwise returns false. No check is done to see + if the process is alive.

@@ -1145,8 +1146,8 @@ typedef enum {

If term identifies a node local port, this function initializes the port variable *port_id from it and returns - true. Otherwise returns false. No check is done if the - port is alive.

+ true. Otherwise returns false. No check is done to see + if the port is alive.

@@ -1157,8 +1158,8 @@ typedef enum { Get head and tail from a list.

Sets *head and *tail from list list.

-

Returns true on success, or false if the list is - empty.

+

Returns true on success, or false if it is + not a list or the list is empty.

@@ -2198,7 +2199,8 @@ enif_map_iterator_destroy(env, &iter); - int + + int enif_mutex_trylock(ErlNifMutex *mtx) @@ -2625,7 +2627,8 @@ enif_map_iterator_destroy(env, &iter); - intenif_thread_create(char *name,ErlNifTid + int + enif_thread_create(char *name,ErlNifTid *tid,void * (*func)(void *),void *args,ErlNifThreadOpts *opts) diff --git a/erts/doc/src/erl_tracer.xml b/erts/doc/src/erl_tracer.xml index a2cfed684b..131157eef8 100644 --- a/erts/doc/src/erl_tracer.xml +++ b/erts/doc/src/erl_tracer.xml @@ -248,7 +248,7 @@ Check if a trace event is to be generated. TraceTag = - trace_tag_garbage_collection() + trace_tag_gc() TracerState = term() Tracee = tracee() Result = trace | discard | remove @@ -434,7 +434,7 @@ specified.

For more information on what Label and SeqTraceInfo can be, see - kernel:seq_trace.

+ kernel:seq_trace(3).

diff --git a/erts/doc/src/erlang.xml b/erts/doc/src/erlang.xml index 3356447168..e402ce448f 100644 --- a/erts/doc/src/erlang.xml +++ b/erts/doc/src/erlang.xml @@ -147,7 +147,7 @@ as the native time unit. That is, it can differ between runtime restarts. To get values of this type, call - os:perf_counter().

+ os:perf_counter/0.

The time_unit/0 type can be extended. @@ -252,7 +252,7 @@ Z = erlang:adler32_combine(X,Y,iolist_size(Data2)). compile time, the call is better written as Fun(Arg1, Arg2, ... ArgN).

-

Earlier, Fun could also be speciifed as +

Earlier, Fun could also be specified as {Module, Function}, equivalent to apply(Module, Function, Args). This use is deprecated and will stop working in a future release.

@@ -352,7 +352,7 @@ Z = erlang:adler32_combine(X,Y,iolist_size(Data2)). 2> binary_part(Bin,{0,2}). <<1,2>>

For details about the PosLen semantics, see - stdlib:binary.

+ stdlib:binary(3).

Allowed in guard tests.

@@ -643,13 +643,13 @@ Z = erlang:adler32_combine(X,Y,iolist_size(Data2)). is given.

-

When the operation is performed synchronously: +

When Async is false: if Info is true, the Result is returned by erlang:cancel_timer(). otherwise ok is returned.

-

When the operation is performed asynchronously: +

When Async is true: if Info is true, a message on the form {cancel_timer, TimerRef, Result} is sent to the @@ -1928,7 +1928,7 @@ os_prompt% using proc_lib (also indirectly, such as gen_server processes), are to use - proc_lib:hibernate/3 in STDLIB + proc_lib:hibernate/3 instead, to ensure that the exception handler continues to work when the process wakes up.

@@ -2492,9 +2492,12 @@ os_prompt% implemented functions (NIFs) for a module. Path is a file path to the shareable object/dynamic library file minus the OS-dependent file extension (.so for Unix and - .dll for Windows). For information on how to + .dll for Windows). Notice that on most OSs the library has + to have a different name on disc when an upgrade of the nif is + done. If the name is the same, but the contents differ, the + old library may be loaded instead. For information on how to implement a NIF library, see - erl_nif.

+ erl_nif(3).

LoadInfo can be any term. It is passed on to the library as part of the initialization. A good practice is to include a module version number to support future code @@ -2689,8 +2692,7 @@ os_prompt%

This is a useful debugging and test tool, especially when writing complicated match specifications.

See also - ets:test_ms/2 - in STDLIB.

+ ets:test_ms/2.

@@ -2900,7 +2902,7 @@ RealSystem = system + MissedSystem

Returns the memory size in bytes allocated for memory of type - Type. The argument can also be specifed as a list + Type. The argument can also be specified as a list of memory_type() atoms, in which case a corresponding list of {memory_type(), Size :: integer >= 0} tuples is returned.

@@ -2987,7 +2989,7 @@ RealSystem = system + MissedSystem the monitored entity. Monitors are fired when the monitored process or port terminates, does not exist at the moment of creation, or if the connection to it is lost. If the connection to it is lost, - we do not know if it still exixts. The monitoring is also turned off + we do not know if it still exists. The monitoring is also turned off when demonitor/1 is called.

@@ -3063,7 +3065,7 @@ RealSystem = system + MissedSystem
Monitoring a - time_offset + time_offset

Monitors changes in time offset @@ -3243,7 +3245,7 @@ RealSystem = system + MissedSystem - Stop execution with a specifed reason. + Stop execution with a specified reason.

Works exactly like error/1, but @@ -3333,9 +3335,7 @@ RealSystem = system + MissedSystem this garbage collection can be delayed. For more information, see - delayed_node_table_gc in - - erlang:system_info/1.

+ erlang:system_info(delayed_node_table_gc).

Some equalities: [node()] = nodes(this), @@ -3387,11 +3387,11 @@ RealSystem = system + MissedSystem translation or to force, for example UTF-8, supply the executable and/or arguments as a binary in the correct encoding. For details, see the module - kernel:file, the + kernel:file(3), the function file:native_name_encoding/0 in Kernel, and - the STDLIB - User's Guide.

+ the + Using Unicode in Erlang User's Guide.

The characters in the name (if specified as a list) can only be > 255 if the Erlang virtual machine is started @@ -3544,7 +3544,7 @@ RealSystem = system + MissedSystem means that file wildcard expansion does not occur. To expand wildcards for the arguments, use - filelib:wildcard/1 in STDLIB. + filelib:wildcard/1. Notice that even if the program is a Unix shell script, meaning that the shell ultimately is invoked, wildcard expansion @@ -4404,10 +4404,10 @@ RealSystem = system + MissedSystem as code auto-loading depends on the correct operation of the error handling module.

Returns the old value of the flag.

- + Set process flag min_heap_size for the calling process. @@ -5884,7 +5884,7 @@ true

Sets the max_heap_size process flag. The default max_heap_size is determined by command-line argument +hmax - in erl/1. For more information, see the + in erl(1). For more information, see the documentation of process_flag(max_heap_size, Size).

@@ -5896,7 +5896,7 @@ true or on_heap. The default message_queue_data process flag is determined by command-line argument - +hmqd in erl/1. + +hmqd in erl(1). For more information, see the documentation of process_flag(message_queue_data, @@ -6128,7 +6128,7 @@ true type => scheduler}|...]

The time unit is the same as returned by - os:perf_counter/0 in Kernel. + os:perf_counter/0. So, to convert it to milliseconds, you can do something like this:

 lists:map(
@@ -6213,9 +6213,8 @@ lists:map(
             part of the other state.
         
         

The utility module - msacc in the - runtime_tools spplication can be used to more easily analyse - these statistics.

+ runtime_tools:msacc(3) + can be used to more easily analyse these statistics.

Returns undefined if system flag microstate_accounting is turned off.

@@ -6654,8 +6653,8 @@ ok Set system flag microstate_accounting.

- Turns on/off microstate accounting measurements. By passing reset, - all counters can be reset to 0.

+ Turns on/off microstate accounting measurements. When passing reset, + all counters are reset to 0.

For more information see statistics(microstate_accounting).

@@ -6685,10 +6684,10 @@ ok processes. The size is specified in words. The new min_bin_vhheap_size effects only processes spawned after the change of - min_bin_vhheap_size has been made. + min_bin_vheap_size has been made. min_bin_vheap_size can be set for individual processes by using - spawn_opt/4 or + spawn_opt/2,3,4 or process_flag/2.

Returns the old value of the flag.

@@ -6705,7 +6704,7 @@ ok The size is specified in words. The new max_heap_size effects only processes spawned efter the change has been made. max_heap_size can be set for individual processes using - spawn_opt/4 or + spawn_opt/2,3,4 or process_flag/2.

Returns the old value of the flag.

@@ -7253,7 +7252,7 @@ ok changed by using erlang:system_flag/2. - spawn_opt/4 + spawn_opt/2,3,4 can spawn a process that does not use the default settings.

@@ -7266,7 +7265,7 @@ ok +hmax, +hmaxk and +hmaxel in - erl/1. It can also be changed at runtime using + erl(1). It can also be changed at runtime using erlang:system_flag(max_heap_size, MaxHeapSize). For more details about the max_heap_size process flag, @@ -7286,7 +7285,7 @@ ok process flag, which is either off_heap or on_heap. This default is set by command-line argument +hmqd in - erl/1. For more information on the + erl(1). For more information on the message_queue_data process flag, see documentation of process_flag(message_queue_data, MQD).

@@ -7434,7 +7433,7 @@ ok of an entry in a node table is delayed. This limit can be set on startup by passing command-line flag +zdntgc - to erl/1. For more information, see the documentation of + to erl(1). For more information, see the documentation of the command-line flag.

dirty_cpu_schedulers @@ -7537,7 +7536,7 @@ ok in bytes. This limit can be set at startup by passing command-line flag +zdbbl - to erl.

+ to erl(1).

dist_ctrl @@ -7568,7 +7567,7 @@ ok (for example, ./configure --with-dynamic-trace=dtrace). For more information about dynamic tracing, see - runtime_tools:dyntrace manual page and the + runtime_tools:dyntrace(3) manual page and the README.dtrace/README.systemtap files in the Erlang source code top directory.

@@ -7602,7 +7601,7 @@ ok

Returns the value of command-line flag +secio in - erl/1, which is either true or false. + erl(1), which is either true or false. For information about the different values, see the documentation of the command-line flag.

@@ -8106,7 +8105,7 @@ ok

Returns the number of async threads in the async thread pool used for asynchronous driver calls ( - driver_async()). + erl_driver:driver_async()). The value is given as an integer.

time_correction @@ -8492,8 +8491,8 @@ ok -

erlang:system_profile is considered experimental - and its behavior can change in a future release.

+

erlang:system_profile behavior can change + in a future release.

@@ -9043,7 +9042,7 @@ timestamp() -> instead of sending a trace message. The tracer module can then ignore or change the trace message. For more details on how to write a tracer module, see - erl_tracer.

+ erl_tracer(3).

If no tracer is specified, the calling process @@ -9400,7 +9399,7 @@ timestamp() ->

The delivery of trace messages (generated by erlang:trace/3, - kernel:seq_trace, + kernel:seq_trace(3), or erlang:system_profile/2) is dislocated on the time-line diff --git a/erts/doc/src/erts_alloc.xml b/erts/doc/src/erts_alloc.xml index c1706806fe..a43f51b10a 100644 --- a/erts/doc/src/erts_alloc.xml +++ b/erts/doc/src/erts_alloc.xml @@ -35,7 +35,7 @@

erts_alloc is an Erlang runtime system internal memory allocator library. erts_alloc provides the Erlang - runtiime system with a number of memory allocators.

+ runtime system with a number of memory allocators.

@@ -67,7 +67,7 @@ A fast allocator used for some frequently used fixed size data types. exec_alloc - Allocator used by the HiPE + Allocator used by the HiPE application for native executable code on specific architectures (x86_64). std_alloc @@ -330,14 +330,9 @@ the flag is false, mseg_alloc tries to create carriers outside of the super carrier when the super carrier is full.

-

Setting this flag to false is possibly not supported +

Setting this flag to false is not supported on all systems. The flag is then ignored.

- -

The super carrier cannot be enabled or - disabled on halfword heap systems. This flag is - ignored on halfword heap systems.

-
]]> @@ -372,11 +367,6 @@

Setting this flag to false is possibly not supported on all systems. The flag is then ignored.

- -

The super carrier cannot be enabled or - disabled on halfword heap systems. This flag is - ignored on halfword heap systems.

-
]]> @@ -387,11 +377,6 @@ carrier if it exists. Notice that the alloc_util framework can create sys_alloc carriers. For more information, see +MMsco.

- -

The super carrier cannot be enabled or - disabled on halfword heap systems. This flag is - ignored on halfword heap systems.

-
]]> @@ -476,7 +461,7 @@ utilization value used. Once a carrier is abandoned, no new allocations are made in it. When an allocator instance gets an increased multiblock carrier need, it first tries to fetch an - abandoned carrier from an allocator instances of the same + abandoned carrier from an allocator instance of the same allocator type. If no abandoned carrier can be fetched, it creates a new empty carrier. When an abandoned carrier has been fetched, it will function as an ordinary carrier. This feature has @@ -689,7 +674,7 @@

exec_alloc super carrier size (in MB). The amount of virtual address space reserved for native executable code - used by the HiPE application + used by the HiPE application on specific architectures (x86_64). Defaults to 512.

diff --git a/erts/doc/src/inet_cfg.xml b/erts/doc/src/inet_cfg.xml index 37653a08e9..3b104a0032 100644 --- a/erts/doc/src/inet_cfg.xml +++ b/erts/doc/src/inet_cfg.xml @@ -68,7 +68,7 @@ /etc/host.conf and /etc/nsswitch.conf) in these modes, except for /etc/resolv.conf and /etc/hosts that is read and monitored for changes on Unix platforms for the internal DNS client - kernel:inet_res.

+ kernel:inet_res(3).

If Erlang is started in long name distributed mode, it needs to get the domain name from somewhere and reads system inet @@ -138,7 +138,7 @@

Specify a system file that Erlang is to read resolver configuration from for the internal DNS client - kernel:inet_res, + kernel:inet_res(3), and monitor for changes, even if it does not exist. The path must be absolute.

This can override the configuration parameters @@ -200,7 +200,7 @@

Add address (and port, if other than default) of the primary nameserver to use for - kernel:inet_res. + kernel:inet_res(3).

@@ -209,14 +209,14 @@

Add address (and port, if other than default) of the secondary nameserver for - kernel:inet_res. + kernel:inet_res(3).

Add search domains for - kernel:inet_res. + kernel:inet_res(3).

@@ -229,7 +229,7 @@ (use host data retrieved from system configuration files and/or the user configuration file) (use the Erlang DNS client - kernel:inet_res + kernel:inet_res(3) for nameserver queries)

The lookup method tries to @@ -249,7 +249,7 @@

Set how often (in milliseconds) the resolver cache for - kernel:inet_res + kernel:inet_res(3) is refreshed (that is, expired DNS records are deleted). Defaults to 1 hour.

@@ -258,28 +258,28 @@

Set the time to wait until retry (in milliseconds) for DNS queries made by - kernel;inet_res. + kernel:inet_res(3). Defaults to 2 seconds.

Set the number of DNS queries - kernel:inet_res + kernel:inet_res(3) will try before giving up. Defaults to 3.

Tells the DNS client - kernel:inet_res + kernel:inet_res(3) to look up IPv6 addresses. Defaults to false.

Tells the DNS client - kernel:inet_res + kernel:inet_res(3) to use TCP (Virtual Circuit) instead of UDP. Defaults to false.

@@ -287,7 +287,7 @@

Sets the EDNS version that - kernel:inet_res + kernel:inet_res(3) will use. The only allowed version is zero. Defaults to false, which means not to use EDNS.

@@ -295,7 +295,7 @@

Sets the allowed UDP payload size - kernel:inet_res + kernel:inet_res(3) will advertise in EDNS queries. Also sets the limit when the DNS query will be deemed too large for UDP forcing a TCP query instead; this is not entirely diff --git a/erts/doc/src/match_spec.xml b/erts/doc/src/match_spec.xml index ee50815fde..1b297c5d29 100644 --- a/erts/doc/src/match_spec.xml +++ b/erts/doc/src/match_spec.xml @@ -142,7 +142,7 @@

A match specification used in - stdlib:ets + stdlib:ets(3) can be described in the following informal grammar:

@@ -436,9 +436,8 @@ Erlang term on stdout, which is seldom what is wanted. Returns and can only be used in the part when tracing.

-
- get_tcw + get_tcw

Takes no argument and returns the value of the node's trace control word. The same is done by @@ -447,9 +446,8 @@ generic trace control. The trace control word can be tested and set both from within trace match specifications and with BIFs. This call is only allowed when tracing.

-
- set_tcw + set_tcw

Takes one unsigned integer argument, sets the value of the node's trace control word to the value of the argument, @@ -481,7 +479,7 @@

All "function calls" must be tuples, even if they take no arguments. - The value of is the atom() + The value of is the atom() , but the value of is the pid() of the current process.

@@ -770,7 +768,7 @@ {'_', [], [{set_seq_token, label, 4711}]}] ]]> -

As can be noted above, the parameter list can be matched aginst a +

As can be noted above, the parameter list can be matched against a single or an . To replace the whole parameter list with a single variable is a special case. In all other cases the must be a @@ -864,8 +862,8 @@ ['$_']}] ]]> -

Function can be useful for testing - complicated ets matches.

+

Function ets:test_ms/2> + can be useful for testing complicated ets matches.

diff --git a/erts/doc/src/ref_man.xml b/erts/doc/src/ref_man.xml index e3f7b1692b..0617463a7b 100644 --- a/erts/doc/src/ref_man.xml +++ b/erts/doc/src/ref_man.xml @@ -32,7 +32,6 @@ - @@ -49,5 +48,6 @@ + diff --git a/erts/doc/src/run_erl.xml b/erts/doc/src/run_erl.xml index 21a7f86011..4780c00ea4 100644 --- a/erts/doc/src/run_erl.xml +++ b/erts/doc/src/run_erl.xml @@ -33,9 +33,9 @@ run_erl.xml run_erl - Redirect Erlang input and output streams on Solaris. + Redirect Erlang input and output streams on Unix systems. -

The program is specific to Solaris/Linux. +

The program is specific to Unix systems. This program redirects the standard input and standard output streams so that all output can be logged. It also lets the program connect to the Erlang console, making @@ -85,7 +85,7 @@ of the standard streams from and to the command. (Both the number of logs and sizes can be changed by environment variables, see section Environment Variables + marker="#environment_variables">Environment Variables below.)

When the logs are full, deletes and reuses the oldest log file.

diff --git a/erts/doc/src/time_correction.xml b/erts/doc/src/time_correction.xml index dbaae4d852..8042ad3b99 100644 --- a/erts/doc/src/time_correction.xml +++ b/erts/doc/src/time_correction.xml @@ -247,7 +247,7 @@ everything that has anything to do with time. All timers, regardless of it is a receive ... after timer, BIF timer, or a timer in the - stdlib:timer + stdlib:timer(3) module, are triggered relative Erlang monotonic time. Even Erlang system time is based on Erlang monotonic time. @@ -769,7 +769,7 @@ Take time stamps with erlang:now/0 and calculate the difference in time with - timer:now_diff/2 in STDLIB. + timer:now_diff/2.

@@ -915,7 +915,7 @@ EventTag = {Time, UMI}

It can be required that your code must run on a variety of OTP installations of different OTP releases. If so, you cannot use the new API out of the box, as it will - not be available on old pre-OTP 18 releases. The solution + not be available on releases before OTP 18. The solution is not to avoid using the new API, as your code would then not benefit from the scalability and accuracy improvements made. Instead, use the diff --git a/erts/doc/src/werl.xml b/erts/doc/src/werl.xml index 995095c0d8..792fe204e8 100644 --- a/erts/doc/src/werl.xml +++ b/erts/doc/src/werl.xml @@ -43,7 +43,7 @@

This starts Erlang in its own window, with fully functioning command-line editing and scrollbars. All flags except work as they do for - command erl.

+ erl(1).

-- cgit v1.2.3