View source code
Display the source code in dmd/backend/cgen.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.cgen

Compiler implementation of the D programming language.

Functions

NameDescription
addtofixlist(s, offset, seg, val, flags) Add to the fix list.
cat(c1, c2) Concatenate two code lists together. Return pointer to result.
cgen_prelinnum(pc, srcpos) Prepend line number to existing code.
code_last(c) Find last code in list.
code_orflag(c, flag) Set flag bits on last code in list.
code_orrex(c, rex) Set rex bits on last code in list.
gen(c, cs) Add code to end of linked list. Note that unused operands are garbage. gen1() and gen2() are shortcut routines.
genadjfpu(c, offset) Generate 'instruction' which tells the scheduler that the fpu stack has changed.
genc(c, op, ea, FL1, EV1, FL2, EV2) Generate code.
gencodelem(cdb, e, pretregs, constflag) Clean stack after call to codelem().
genlinnum(c, srcpos) Generate 'instruction' which is actually a line number.
gennop(c) Generate 'nop'
outfixlist() End of module. Output fixups as references to external Symbols.
reghasvalue(regm, value, preg) Determine if one of the registers in regm has value in it. If so, return !=0 and set *preg to which register it is.
regwithvalue(cdb, regm, value, preg, flags) Load a register from the mask regm with value.

Structs

NameDescription
Fixup When we don't know whether a function symbol is defined or not within this module, we stuff it in an array of references to be fixed up later.

Authors

Walter Bright

License

Boost License 1.0