MCPcopy Create free account
hub / github.com/danoon2/Boxedwine / gen08e

Function gen08e

source/emulation/cpu/srcgen.cpp:1958–1986  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1956void OPCALL movs16e16_16(struct CPU* cpu, struct Op* op);
1957void OPCALL movs16e16_32(struct CPU* cpu, struct Op* op);
1958void gen08e(struct GenData* data, struct Op* op) {
1959 if (op->func == movs16r16) {
1960 out(data, "cpu->segValue[");
1961 out(data, getBase(op->r2));
1962 out(data, "] = ");
1963 out(data, r16(op->r1));
1964 out(data, "; cpu->segAddress[");
1965 out(data, getBase(op->r2));
1966 out(data, "] = cpu->ldt[cpu->segValue[");
1967 out(data, getBase(op->r2));
1968 out(data, "] >> 3].base_addr; CYCLES(2);");
1969 } else {
1970 out(data, "cpu->segValue[");
1971 out(data, getBase(op->r2));
1972 out(data, "] = readw(cpu->thread, ");
1973 if (op->func == movs16e16_16) {
1974 out(data, getEaa16(op));
1975 } else if (op->func == movs16e16_32) {
1976 out(data, getEaa32(op));
1977 } else {
1978 kpanic("gen08e");
1979 }
1980 out(data, "); cpu->segAddress[");
1981 out(data, getBase(op->r2));
1982 out(data, "] = cpu->ldt[cpu->segValue[");
1983 out(data, getBase(op->r2));
1984 out(data, "] >> 3].base_addr; CYCLES(3);");
1985 }
1986}
1987
1988void OPCALL popReg16(struct CPU* cpu, struct Op* op);
1989void OPCALL pope16_16(struct CPU* cpu, struct Op* op);

Callers

nothing calls this directly

Calls 6

getBaseFunction · 0.85
r16Function · 0.85
getEaa16Function · 0.85
getEaa32Function · 0.85
kpanicFunction · 0.85
outFunction · 0.70

Tested by

no test coverage detected