EM_MES(3ACK)

NAME
em_mes - EM-message generating routines

SYNOPSIS
#include <em.h>

C_ms_err()

C_ms_opt()

C_ms_emx(wsiz, psiz)
arith wsiz, psiz;

#include <em_reg.h>
C_ms_reg(offs, siz, class, prior)
arith offs, siz;
int class, prior;

C_ms_src(nlines, filnam)
int nlines;
char *filnam;

C_ms_flt()

C_ms_com(str)
char *str;

C_ms_par(nparams)
arith nparams;

#include <em_ego.h>
C_ms_ego(hint, offs, siz, regno)
int hint, regno;
arith offs, siz;

C_ms_gto()

DESCRIPTION
This set of routines forms a front end for the em_code(3L) module. The philosophy behind this package is to provide a single routine for each type of EM message that is generated by a front-end compiler. Each routine internally builds a message instruction by using the C_mes_begin, C_mes_end and the C_cstp routines from the em_code module. The actions taken by these functions depend on the type of em_code module that is loaded together with this module. The routines described here do not prevent the user from directly composing EM messages himself.

C_ms_err() generates a message that indicates some error during the compilation.

C_ms_opt() causes any optimization to be suppressed.

C_ms_emx() indicates the wordsize wsiz and pointersize psiz. This must be the first code generated, or the generated code is illegal.

C_ms_reg() can be used to indicate that a local variable, having offset offs and size (in bytes) siz, may be stored in a register. Class indicates the use of the variable. The following classes are allowed (the names are defined in em_reg.h):

    reg_any
        no specific type

    reg_loop
        loop control variable

    reg_pointer
        pointer variable

    reg_float
        floating point variable

Prior is taken to be the priority of the variable; higher numbers indicate better candidates.

C_ms_src() produces an indication of the number of source lines, nlines, in file filnam. This information can be used by a profiler.

C_ms_flt() produces an indication that floating-point operations are used.

C_ms_com() causes the string str to be inserted as comment in the resulting output. Note that this routine does not provide the full semantics of EM in this area, but the user himself can build a comment message with other types of comment if he likes.

C_ms_par() produces an indication that no more than nbytes of parameters are accessed, either directly or indirectly.

C_ms_ego() produces a hint from the EM global optimizer. The parameters needed are conform to the format of the message.

C_ms_gto() can be invoked to indicate that a procedure uses a non-local goto.

FILES
~em/modules/h/em.h
~em/h/em_reg.h
~em/h/em_ego.h
~em/modules/lib/libem_mes.a

MODULES
em_code(3)

SEE ALSO
em_code(3), read_em(3)

DIAGNOSTICS
None of the functions return a value.

BUGS
The C_ms_ext() routine has not yet been implemented, since this message uses a variable number of arguments.

Please report other bugs to the author.

AUTHOR
Erik Baalbergen <erikb@vu44.UUCP>