View source code
Display the source code in dmd/backend/elem.d from which this page was generated on github.
Report a bug
If you spot a problem with this page, click here to create a Bugzilla issue.
Improve this page
Quickly fork, edit online, and submit a pull request for this page. Requires a signed-in GitHub account. This works well for small changes. If you'd like to make larger changes you may want to consider using local clone.

Module dmd.backend.elem

Compiler implementation of the D programming language.

Functions

NameDescription
el_alignsize(e)
el_alignsize(e)
el_allbits(e, bit) Determine if constant e is all ones or all zeros.
el_allbits(e, bit) Determine if constant e is all ones or all zeros.
el_alloc_localgot() Allocate localgot symbol.
el_alloc_localgot() Allocate localgot symbol.
el_alloctmp(ty) Allocate a temporary, and return temporary elem.
el_alloctmp(ty) Allocate a temporary, and return temporary elem.
el_anydef(ed, e) Does any definition of lvalue ed appear in e?
el_anydef(ed, e) Does any definition of lvalue ed appear in e?
el_anydef(ed, e) Does any definition of lvalue ed appear in e?
el_anydef(ed, e) Does any definition of lvalue ed appear in e?
el_appears(e, s) Does symbol s appear in tree e?
el_appears(e, s) Does symbol s appear in tree e?
el_basesym(e) Look for symbol that is a base of addressing mode e.
el_basesym(e) Look for symbol that is a base of addressing mode e.
el_basesym(e) Look for symbol that is a base of addressing mode e.
el_basesym(e) Look for symbol that is a base of addressing mode e.
el_bint(op, t, e1, e2) Make a binary operator node.
el_bint(op, t, e1, e2) Make a binary operator node.
el_calloc() Allocate an element.
el_calloc() Allocate an element.
el_check(e) Check for errors in a tree.
el_check(e) Check for errors in a tree.
el_combine(e1, e2) Combine e1 and e2 with a comma-expression. Be careful about either or both being null.
el_combine(e1, e2) Combine e1 and e2 with a comma-expression. Be careful about either or both being null.
el_combines(args, length) Do an array of parameters as a balanced binary tree.
el_combines(args, length) Do an array of parameters as a balanced binary tree.
el_const(ty, pconst) Make a constant elem. ty = type of elem *pconst = union of constant data
el_const(ty, pconst) Make a constant elem. ty = type of elem *pconst = union of constant data
el_convert(e) Run through a tree converting it to CODGEN.
el_convert(e) Run through a tree converting it to CODGEN.
el_convfloat(e) Convert floating point constant to a read-only symbol. Needed iff floating point code can't load immediate constants.
el_convfloat(e) Convert floating point constant to a read-only symbol. Needed iff floating point code can't load immediate constants.
el_convstring(e) Convert reference to a string to reference to a symbol stored in the static data segment.
el_convstring(e) Convert reference to a string to reference to a symbol stored in the static data segment.
el_convxmm(e) Convert vector constant to a read-only symbol. Needed iff vector code can't load immediate constants.
el_convxmm(e) Convert vector constant to a read-only symbol. Needed iff vector code can't load immediate constants.
el_copy(to, from) Copy an element (not the tree!).
el_copy(to, from) Copy an element (not the tree!).
el_copytotmp(pe) Thin wrapper of exp2_copytotemp. Different from el_same, always makes a temporary.
el_copytotmp(pe) Thin wrapper of exp2_copytotemp. Different from el_same, always makes a temporary.
el_copytree(e) Create and return a duplicate of e, including its leaves. No CSEs.
el_copytree(e) Create and return a duplicate of e, including its leaves. No CSEs.
el_countCommas(e) Count number of commas in the expression.
el_countCommas(e) Count number of commas in the expression.
el_ctor(ector, e, sdtor) Insert constructor information into tree. ector pointer to object being constructed e code to construct the object sdtor function to destruct the object
el_ctor(ector, e, sdtor) Insert constructor information into tree. ector pointer to object being constructed e code to construct the object sdtor function to destruct the object
el_ctor_dtor(ec, ed, pedtor) Create constructor/destructor pair of elems.
el_ctor_dtor(ec, ed, pedtor) Create constructor/destructor pair of elems.
el_dctor(e, decl) Insert constructor information into tree. A corresponding el_ddtor() must be called later.
el_dctor(e, decl) Insert constructor information into tree. A corresponding el_ddtor() must be called later.
el_ddtor(e, decl) Insert destructor information into tree. e code to destruct the object decl VarDeclaration of variable being destructed (must match decl for corresponding OPctor)
el_ddtor(e, decl) Insert destructor information into tree. e code to destruct the object decl VarDeclaration of variable being destructed (must match decl for corresponding OPctor)
el_dehydrate(pe) Dehydrate an elem.
el_dehydrate(pe) Dehydrate an elem.
el_depends(ea, eb)
el_depends(ea, eb)
el_dtor(edtor, e) Insert destructor information into tree. edtor pointer to object being destructed e code to do the destruction
el_dtor(edtor, e) Insert destructor information into tree. edtor pointer to object being destructed e code to do the destruction
el_free(e) Free element
el_free(e) Free element
el_funcsideeff(e)
el_funcsideeff(e)
el_hydrate(pe) Hydrate an elem.
el_hydrate(pe) Hydrate an elem.
el_init() Initialize el package.
el_init() Initialize el package.
el_isdependent(e) Is elem type-dependent or value-dependent?
el_isdependent(e) Is elem type-dependent or value-dependent?
el_longt(t, val) Make a constant node out of integral type.
el_longt(t, val) Make a constant node out of integral type.
el_match(n1, n2)
el_match(n1, n2)
el_match2(n1, n2) Kludge on el_match(). Same, but ignore differences in OPconst.
el_match2(n1, n2) Kludge on el_match(). Same, but ignore differences in OPconst.
el_match3(n1, n2) Kludge on el_match(). Same, but ignore differences in type modifiers.
el_match3(n1, n2) Kludge on el_match(). Same, but ignore differences in type modifiers.
el_match4(n1, n2) Kludge on el_match(). Same, but ignore differences in spelling of var's.
el_match4(n1, n2) Kludge on el_match(). Same, but ignore differences in spelling of var's.
el_match5(n1, n2) Kludge on el_match(). Same, but regard signed/unsigned as equivalent.
el_match5(n1, n2) Kludge on el_match(). Same, but regard signed/unsigned as equivalent.
el_nelems(t) Return an elem that evaluates to the number of elems in a type (if it is an array). Returns null if t is not an array.
el_nelems(t) Return an elem that evaluates to the number of elems in a type (if it is an array). Returns null if t is not an array.
el_nparams(e) Return a list of the parameters.
el_nparams(e) Return a list of the parameters.
el_opArray(parray, e, op) Fill an array with the ops.
el_opArray(parray, e, op) Fill an array with the ops.
el_opCombine(args, length, op, ty) Do an array of parameters as a tree
el_opCombine(args, length, op, ty) Do an array of parameters as a tree
el_opN(e, op) Return number of op nodes
el_opN(e, op) Return number of op nodes
el_pair(tym, lo, hi) Create a quad word out of two dwords.
el_pair(tym, lo, hi) Create a quad word out of two dwords.
el_param(e1, e2) Combine e1 and e2 as parameters to a function. Be careful about either or both being null.
el_param(e1, e2) Combine e1 and e2 as parameters to a function. Be careful about either or both being null.
el_paramArray(parray, e) Fill an array with the parameters.
el_paramArray(parray, e) Fill an array with the parameters.
el_params(e1) Create parameter list, terminated by a null.
el_params(args, length) Do an array of parameters as a balanced binary tree.
el_params(args, length) Do an array of parameters as a balanced binary tree.
el_params(e1) Create parameter list, terminated by a null.
el_parent(e, pe) Find and return pointer to parent of e starting at *pe. Return null if can't find it.
el_parent(e, pe) Find and return pointer to parent of e starting at *pe. Return null if can't find it.
el_picvar(s) Make an elem out of a symbol, PIC style.
el_picvar(s) Make an elem out of a symbol, PIC style.
el_ptr(s) Make a pointer to an elem out of a symbol.
el_ptr(s) Make a pointer to an elem out of a symbol.
el_ptr_offset(s, offset) Make a pointer to an elem out of a symbol at offset.
el_ptr_offset(s, offset) Make a pointer to an elem out of a symbol at offset.
el_replace_sym(e, s1, s2) Replace symbol s1 with s2 in tree.
el_replace_sym(e, s1, s2) Replace symbol s1 with s2 in tree.
el_replacesym(e, s1, s2) Walk tree, replacing symbol s1 with s2.
el_replacesym(e, s1, s2) Walk tree, replacing symbol s1 with s2.
el_reset() Initialize for another run through.
el_reset() Initialize for another run through.
el_returns(e) Determine if expression may return. Does not detect all cases, errs on the side of saying it returns.
el_returns(e) Determine if expression may return. Does not detect all cases, errs on the side of saying it returns.
el_same(pe) Similar to el_copytree(e). But if e has any side effects, it's replaced with (tmp = e) and tmp is returned.
el_same(pe) Similar to el_copytree(e). But if e has any side effects, it's replaced with (tmp = e) and tmp is returned.
el_scancommas(e) Scan down commas and return the controlling elem.
el_scancommas(e) Scan down commas and return the controlling elem.
el_selecte1(e) Select the e1 child of e.
el_selecte1(e) Select the e1 child of e.
el_selecte2(e) Select the e2 child of e.
el_selecte2(e) Select the e2 child of e.
el_settype(e, t) Set new type for elem.
el_settype(e, t) Set new type for elem.
el_sideeffect(e)
el_sideeffect(e)
el_signx32(e) Determine if constant e is a 32 bit or less value, or is a 32 bit value sign extended to 64 bits.
el_signx32(e) Determine if constant e is a 32 bit or less value, or is a 32 bit value sign extended to 64 bits.
el_term() Terminate el package.
el_term() Terminate el package.
el_toconst(e) If elem is a const that can be converted to an OPconst, do the conversion.
el_toconst(e) If elem is a const that can be converted to an OPconst, do the conversion.
el_toldouble(e) Extract long double value from constant elem. Silently ignore types which are not floating point values.
el_toldouble(e) Extract long double value from constant elem. Silently ignore types which are not floating point values.
el_toldouble(e) Extract long double value from constant elem. Silently ignore types which are not floating point values.
el_tolong(e) Extract long value from constant elem.
el_tolong(e) Extract long value from constant elem.
el_tolongt(e) Extract long value from constant parser elem.
el_tolongt(e) Extract long value from constant parser elem.
el_typesize(t) Create elem that is the size of a type.
el_typesize(t) Create elem that is the size of a type.
el_unat(op, t, e1) Make a unary operator node.
el_unat(op, t, e1) Make a unary operator node.
el_var(s) Make an elem out of a symbol.
el_var(s) Make an elem out of a symbol.
el_zero(t) Create an elem of the constant 0, of the type t.
el_zero(t) Create an elem of the constant 0, of the type t.
elem_print(e, nestlevel) Write out expression elem.
elem_print(e, nestlevel) Write out expression elem.
ERTOL(e)
ERTOL(e)
exp2_copytotemp(e) Replace (e) with ((stmp = e),stmp)
exp2_copytotemp(e) Replace (e) with ((stmp = e),stmp)
shrinkLongDoubleConstantIfPossible(e) If e is a long double constant, and it is perfectly representable as a double constant, convert it to a double constant. Note that this must NOT be done in contexts where there are no further operations, since then it could change the type (eg, in the function call printf("%La", 2.0L); the 2.0 must stay as a long double).
shrinkLongDoubleConstantIfPossible(e) If e is a long double constant, and it is perfectly representable as a double constant, convert it to a double constant. Note that this must NOT be done in contexts where there are no further operations, since then it could change the type (eg, in the function call printf("%La", 2.0L); the 2.0 must stay as a long double).
shrinkLongDoubleConstantIfPossible(e) If e is a long double constant, and it is perfectly representable as a double constant, convert it to a double constant. Note that this must NOT be done in contexts where there are no further operations, since then it could change the type (eg, in the function call printf("%La", 2.0L); the 2.0 must stay as a long double).

Structs

NameDescription
STAB
STAB

Global variables

NameTypeDescription
elmax int Do our own storage allocation of elems.
elmax int Do our own storage allocation of elems.

Authors

Walter Bright

License

Boost License 1.0