mirror of
https://github.com/holub/mame
synced 2025-04-19 07:00:31 +03:00
Various cleanups:
* cpu/dsp56156: Removed vestigial (and excessively slow) "new" execution code. * apple/bandit.cpp: Got rid of unnecessary friend declaration. * nintendo/n64_v.cpp: More const. * Fixed a few "const qualifier has no effect" warnings.
This commit is contained in:
parent
6d72820d8d
commit
383ab43dbc
@ -53,7 +53,7 @@ newoption {
|
||||
description = "Set Android platform version (default: android-24).",
|
||||
}
|
||||
|
||||
local android = {};
|
||||
local android = {}
|
||||
|
||||
function androidToolchainRoot()
|
||||
if android.toolchainRoot == nil then
|
||||
@ -62,7 +62,7 @@ function androidToolchainRoot()
|
||||
linux = "linux-x86_64",
|
||||
macosx = "darwin-x86_64"
|
||||
}
|
||||
android.toolchainRoot = os.getenv("ANDROID_NDK_HOME") .. "/toolchains/llvm/prebuilt/" .. hostTags[os.get()]
|
||||
android.toolchainRoot = (os.getenv("ANDROID_NDK_HOME") or "") .. "/toolchains/llvm/prebuilt/" .. hostTags[os.get()]
|
||||
end
|
||||
|
||||
return android.toolchainRoot;
|
||||
|
@ -462,25 +462,6 @@ void dsp56156_device::device_reset()
|
||||
/***************************************************************************
|
||||
CORE EXECUTION LOOP
|
||||
***************************************************************************/
|
||||
// Execute a single opcode and return how many cycles it took.
|
||||
static size_t execute_one_new(dsp56156_core* cpustate)
|
||||
{
|
||||
// For MAME
|
||||
cpustate->ppc = PC;
|
||||
if (cpustate->device->machine().debug_flags & DEBUG_FLAG_CALL_HOOK) // FIXME: if this was a member, the helper would work
|
||||
cpustate->device->debug()->instruction_hook(PC);
|
||||
|
||||
cpustate->op = ROPCODE(PC);
|
||||
uint16_t w0 = ROPCODE(PC);
|
||||
uint16_t w1 = ROPCODE(PC + 1);
|
||||
|
||||
Opcode op(w0, w1);
|
||||
op.evaluate(cpustate);
|
||||
PC += op.evalSize(); // Special size function needed to handle jmps, etc.
|
||||
|
||||
// TODO: Currently all operations take up 4 cycles (inst->cycles()).
|
||||
return 4;
|
||||
}
|
||||
|
||||
void dsp56156_device::execute_run()
|
||||
{
|
||||
@ -504,7 +485,6 @@ void dsp56156_device::execute_run()
|
||||
while(m_core.icount > 0)
|
||||
{
|
||||
execute_one(&m_core);
|
||||
if (0) m_core.icount -= execute_one_new(&m_core);
|
||||
pcu_service_interrupts(&m_core); // TODO: Is it incorrect to service after each instruction?
|
||||
}
|
||||
}
|
||||
|
@ -31,7 +31,6 @@ public:
|
||||
|
||||
virtual bool decode(const uint16_t word0, const uint16_t word1) = 0;
|
||||
virtual std::string disassemble() const = 0;
|
||||
virtual void evaluate(dsp56156_core* cpustate) = 0;
|
||||
|
||||
virtual size_t size() const = 0;
|
||||
virtual size_t evalSize() const { return size(); }
|
||||
@ -82,7 +81,6 @@ public:
|
||||
{
|
||||
return "abs " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -105,7 +103,6 @@ public:
|
||||
{
|
||||
return "adc " + regIdAsString(m_source) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -128,7 +125,6 @@ public:
|
||||
{
|
||||
return "add " + regIdAsString(m_source) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -155,7 +151,6 @@ public:
|
||||
{
|
||||
return m_opcode + " " + regIdAsString(m_source) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -182,7 +177,6 @@ public:
|
||||
{
|
||||
return "and " + regIdAsString(m_source) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE; }
|
||||
};
|
||||
@ -206,7 +200,6 @@ public:
|
||||
{
|
||||
return util::string_format("andi #$%x,%s", m_immediate, regIdAsString(m_destination));
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -231,7 +224,6 @@ public:
|
||||
{
|
||||
return "asl " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -253,7 +245,6 @@ public:
|
||||
{
|
||||
return "asl4 " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -275,7 +266,6 @@ public:
|
||||
{
|
||||
return "asr " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -297,7 +287,6 @@ public:
|
||||
{
|
||||
return "asr4 " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -319,7 +308,6 @@ public:
|
||||
{
|
||||
return "asr16 " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -373,7 +361,6 @@ public:
|
||||
{
|
||||
return util::string_format("%s #$%x,%s", m_opcode, m_iVal, dString);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 2; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
private:
|
||||
@ -431,7 +418,6 @@ public:
|
||||
{
|
||||
return util::string_format("%s #$%x,X:(%s)", m_opcode, m_iVal, regIdAsString(m_r));
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 2; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -489,7 +475,6 @@ public:
|
||||
{
|
||||
return util::string_format("%s #$%x,%s", m_opcode, m_iVal, regIdAsString(m_destination));
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 2; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -518,7 +503,6 @@ public:
|
||||
{
|
||||
return util::string_format("b%s >*+$%x", opMnemonicAsString(m_mnem), 2 + m_immediate);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 2; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -550,7 +534,6 @@ public:
|
||||
else
|
||||
return util::string_format("b%s <*-$%x", opMnemonicAsString(m_mnem), 1 - m_immediate - 2);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -579,7 +562,6 @@ public:
|
||||
std::string opcode = "b" + opMnemonicAsString(m_mnem);
|
||||
return opcode + " " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -605,7 +587,6 @@ public:
|
||||
{
|
||||
return util::string_format("bra >*+$%x", 2 + m_immediate);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 2; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -634,7 +615,6 @@ public:
|
||||
else
|
||||
return util::string_format("bra <*-$%x", 1 - m_immediate - 2);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -659,7 +639,6 @@ public:
|
||||
{
|
||||
return "bra " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -682,7 +661,6 @@ public:
|
||||
{
|
||||
return "brk" + opMnemonicAsString(m_mnem);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -713,7 +691,6 @@ public:
|
||||
else
|
||||
return util::string_format("bs%s >*-$%x", opMnemonicAsString(m_mnem), 1 - m_immediate - 1 - 2);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 2; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
size_t flags() const override { return util::disasm_interface::STEP_OVER; }
|
||||
@ -743,7 +720,6 @@ public:
|
||||
std::string opcode = "bs" + opMnemonicAsString(m_mnem);
|
||||
return opcode + " " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
size_t flags() const override { return util::disasm_interface::STEP_OVER; }
|
||||
@ -773,7 +749,6 @@ public:
|
||||
else
|
||||
return util::string_format("bsr >*-$%x", 1 - m_immediate - 1 - 2);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 2; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
size_t flags() const override { return util::disasm_interface::STEP_OVER; }
|
||||
@ -799,7 +774,6 @@ public:
|
||||
{
|
||||
return "bsr " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
size_t flags() const override { return util::disasm_interface::STEP_OVER; }
|
||||
@ -821,7 +795,6 @@ public:
|
||||
{
|
||||
return "chkaau";
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -843,7 +816,6 @@ public:
|
||||
{
|
||||
return "clr " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -865,7 +837,6 @@ public:
|
||||
{
|
||||
return "clr24 " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE; }
|
||||
};
|
||||
@ -890,7 +861,6 @@ public:
|
||||
{
|
||||
return "cmp " + regIdAsString(m_source) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_NONE; }
|
||||
};
|
||||
@ -915,7 +885,6 @@ public:
|
||||
{
|
||||
return "cmpm " + regIdAsString(m_source) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_NONE; }
|
||||
};
|
||||
@ -936,7 +905,6 @@ public:
|
||||
{
|
||||
return "debug";
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -960,7 +928,6 @@ public:
|
||||
std::string opcode = "debug" + opMnemonicAsString(m_mnem);
|
||||
return opcode;
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -985,7 +952,6 @@ public:
|
||||
{
|
||||
return "dec " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -1007,7 +973,6 @@ public:
|
||||
{
|
||||
return "dec24 " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE; }
|
||||
};
|
||||
@ -1030,7 +995,6 @@ public:
|
||||
{
|
||||
return "div " + regIdAsString(m_source) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -1062,7 +1026,6 @@ public:
|
||||
regIdAsString(m_source) + "," +
|
||||
regIdAsString(m_source2) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -1090,7 +1053,6 @@ public:
|
||||
{
|
||||
return util::string_format("do X:(%s),*+$%x", regIdAsString(m_source), 2 + m_immediate);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 2; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -1118,7 +1080,6 @@ public:
|
||||
{
|
||||
return util::string_format("do #<$%x,*+$%x", m_immediate, 2 + m_displacement);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 2; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -1149,7 +1110,6 @@ public:
|
||||
{
|
||||
return util::string_format("do %s,*+$%x", regIdAsString(m_source), 2 + m_displacement);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 2; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -1175,7 +1135,6 @@ public:
|
||||
{
|
||||
return util::string_format("do forever, *+$%x", m_displacement + 2);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 2; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -1199,7 +1158,6 @@ public:
|
||||
{
|
||||
return "enddo";
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -1222,7 +1180,6 @@ public:
|
||||
{
|
||||
return "eor " + regIdAsString(m_source) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE; }
|
||||
};
|
||||
@ -1244,7 +1201,6 @@ public:
|
||||
{
|
||||
return "ext " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -1265,7 +1221,6 @@ public:
|
||||
{
|
||||
return "illegal";
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -1291,7 +1246,6 @@ public:
|
||||
regIdAsString(m_source) + "," +
|
||||
regIdAsString(m_source2) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -1320,7 +1274,6 @@ public:
|
||||
regIdAsString(m_source) + "," +
|
||||
regIdAsString(m_source2) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -1345,7 +1298,6 @@ public:
|
||||
{
|
||||
return "inc " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -1367,7 +1319,6 @@ public:
|
||||
{
|
||||
return "inc24 " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE; }
|
||||
};
|
||||
@ -1392,7 +1343,6 @@ public:
|
||||
{
|
||||
return util::string_format("j%s >$%x", opMnemonicAsString(m_mnem), m_displacement);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 2; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -1421,7 +1371,6 @@ public:
|
||||
std::string opcode = "j" + opMnemonicAsString(m_mnem);
|
||||
return opcode + " " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -1447,13 +1396,6 @@ public:
|
||||
{
|
||||
return util::string_format("jmp >$%x", m_displacement);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override
|
||||
{
|
||||
PC = m_displacement;
|
||||
|
||||
/* S L E U N Z V C */
|
||||
/* - - - - - - - - */
|
||||
}
|
||||
size_t size() const override { return 2; }
|
||||
size_t evalSize() const override { return 0; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
@ -1479,13 +1421,6 @@ public:
|
||||
{
|
||||
return "jmp " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override
|
||||
{
|
||||
PC = regValue16(cpustate, m_destination);
|
||||
|
||||
/* S L E U N Z V C */
|
||||
/* - - - - - - - - */
|
||||
}
|
||||
size_t size() const override { return 1; }
|
||||
size_t evalSize() const override { return 0; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
@ -1513,7 +1448,6 @@ public:
|
||||
{
|
||||
return util::string_format("js%s >$%x", opMnemonicAsString(m_mnem), m_displacement);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 2; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
size_t flags() const override { return util::disasm_interface::STEP_OVER; }
|
||||
@ -1543,7 +1477,6 @@ public:
|
||||
std::string opcode = "js" + opMnemonicAsString(m_mnem);
|
||||
return opcode + " " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
size_t flags() const override { return util::disasm_interface::STEP_OVER; }
|
||||
@ -1570,7 +1503,6 @@ public:
|
||||
{
|
||||
return util::string_format("jsr >$%x", m_displacement);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 2; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
size_t flags() const override { return util::disasm_interface::STEP_OVER; }
|
||||
@ -1597,7 +1529,6 @@ public:
|
||||
{
|
||||
return util::string_format("jsr <$%x", m_bAddr);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
size_t flags() const override { return util::disasm_interface::STEP_OVER; }
|
||||
@ -1623,7 +1554,6 @@ public:
|
||||
{
|
||||
return "jsr " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
size_t flags() const override { return util::disasm_interface::STEP_OVER; }
|
||||
@ -1654,7 +1584,6 @@ public:
|
||||
// HACK
|
||||
return "lea " + m_ea + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -1686,7 +1615,6 @@ public:
|
||||
// HACK
|
||||
return "lea " + m_ea + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -1711,7 +1639,6 @@ public:
|
||||
{
|
||||
return "lsl " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE; }
|
||||
};
|
||||
@ -1733,7 +1660,6 @@ public:
|
||||
{
|
||||
return "lsr " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE; }
|
||||
};
|
||||
@ -1765,7 +1691,6 @@ public:
|
||||
regIdAsString(m_source) + "," +
|
||||
regIdAsString(m_source2) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -1795,7 +1720,6 @@ public:
|
||||
regIdAsString(m_source) + "," +
|
||||
regIdAsString(m_source2) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -1824,7 +1748,6 @@ public:
|
||||
regIdAsString(m_source) + "," +
|
||||
regIdAsString(m_source2) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -1859,7 +1782,6 @@ public:
|
||||
regIdAsString(m_source) + "," +
|
||||
regIdAsString(m_source2) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -1889,7 +1811,6 @@ public:
|
||||
regIdAsString(m_source) + "," +
|
||||
regIdAsString(m_source2) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -1924,7 +1845,6 @@ public:
|
||||
regIdAsString(m_source) + "," +
|
||||
regIdAsString(m_source2) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -1967,7 +1887,6 @@ public:
|
||||
else
|
||||
return "move";
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_NONE; }
|
||||
|
||||
@ -1998,7 +1917,6 @@ public:
|
||||
{
|
||||
return "move";
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -2028,7 +1946,6 @@ public:
|
||||
assemble_reg_from_W_table(m_W, 'X', m_SD, m_b, source, destination);
|
||||
return "move " + source + "," + destination;
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 2; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -2066,7 +1983,6 @@ public:
|
||||
assemble_arguments_from_W_table(m_W, 'X', m_SD, m_ea, source, destination);
|
||||
return "move " + source + "," + destination;
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -2104,7 +2020,6 @@ public:
|
||||
assemble_arguments_from_W_table(m_W, 'X', m_SD, m_ea, source, destination);
|
||||
return "move " + source + "," + destination;
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -2141,7 +2056,6 @@ public:
|
||||
assemble_arguments_from_W_table(m_W, 'X', m_SD, m_ea, source, destination);
|
||||
return "move " + source + "," + destination;
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -2188,39 +2102,6 @@ public:
|
||||
|
||||
return retString;
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override
|
||||
{
|
||||
if (m_W)
|
||||
{
|
||||
if (m_t)
|
||||
{
|
||||
setReg16(cpustate, m_value, m_sd);
|
||||
}
|
||||
else
|
||||
{
|
||||
//uint16_t memValue = memory_read_word_16le(cpustate->data, ADDRESS(m_value));
|
||||
//setReg16(cpustate, memValue, m_sd);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (m_t)
|
||||
{
|
||||
osd_printf_error("DSP561xx|Movec_4: This sure seems like it can't happen.");
|
||||
}
|
||||
else
|
||||
{
|
||||
//uint16_t regValue = regValue16(cpustate, m_sd);
|
||||
//memory_write_word_16le(cpustate->data, m_value, regValue);
|
||||
}
|
||||
}
|
||||
|
||||
/* S L E U N Z V C */
|
||||
/* * ? ? ? ? ? ? ? */
|
||||
// All ? bits - If SR is specified as a destination operand, set according to the corresponding
|
||||
// bit of the source operand. If SR is not specified as a destination operand, L is set if data
|
||||
// limiting occurred. All ? bits are not affected otherwise.
|
||||
}
|
||||
size_t size() const override { return 2; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -2252,7 +2133,6 @@ public:
|
||||
{
|
||||
return "move " + regIdAsString(m_source) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -2283,7 +2163,6 @@ public:
|
||||
assemble_reg_from_W_table(m_W, 'X', m_SD, m_b, source, destination);
|
||||
return "move " + source + "," + destination;
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 2; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -2316,7 +2195,6 @@ public:
|
||||
else
|
||||
return util::string_format("move #<-$%x,%s", 1 - m_immediate - 1, regIdAsString(m_destination));
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -2351,7 +2229,6 @@ public:
|
||||
assemble_arguments_from_W_table(m_W, 'P', m_SD, m_ea, source, destination);
|
||||
return "move " + source + "," + destination;
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -2394,7 +2271,6 @@ public:
|
||||
}
|
||||
return "move " + source + "," + destination;
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -2429,7 +2305,6 @@ public:
|
||||
assemble_reg_from_W_table(m_W, 'P', m_SD, m_b, source, destination);
|
||||
return "move " + source + "," + destination;
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 2; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -2468,7 +2343,6 @@ public:
|
||||
assemble_arguments_from_W_table(m_W, 'X', m_SD, m_ea, source, destination);
|
||||
return "movep " + source + "," + destination;
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -2509,7 +2383,6 @@ public:
|
||||
assemble_arguments_from_W_table(m_W, 'X', m_SD, m_ea, source, destination);
|
||||
return "movep " + source + "," + destination;
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -2544,7 +2417,6 @@ public:
|
||||
assemble_arguments_from_W_table(m_W, 'X', m_SD, m_ea, source, destination);
|
||||
return "moves " + source + "," + destination;
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -2583,7 +2455,6 @@ public:
|
||||
regIdAsString(m_source) + "," +
|
||||
regIdAsString(m_source2) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -2613,7 +2484,6 @@ public:
|
||||
regIdAsString(m_source) + "," +
|
||||
regIdAsString(m_source2) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -2642,7 +2512,6 @@ public:
|
||||
regIdAsString(m_source) + "," +
|
||||
regIdAsString(m_source2) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -2679,7 +2548,6 @@ public:
|
||||
regIdAsString(m_source) + "," +
|
||||
regIdAsString(m_source2) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -2709,7 +2577,6 @@ public:
|
||||
regIdAsString(m_source) + "," +
|
||||
regIdAsString(m_source2) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -2743,7 +2610,6 @@ public:
|
||||
regIdAsString(m_source) + "," +
|
||||
regIdAsString(m_source2) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -2769,7 +2635,6 @@ public:
|
||||
{
|
||||
return "neg " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -2791,7 +2656,6 @@ public:
|
||||
{
|
||||
return "negc " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -2812,7 +2676,6 @@ public:
|
||||
{
|
||||
return "nop";
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -2836,7 +2699,6 @@ public:
|
||||
{
|
||||
return "norm " + regIdAsString(m_source) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -2858,7 +2720,6 @@ public:
|
||||
{
|
||||
return "not " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE; }
|
||||
};
|
||||
@ -2881,7 +2742,6 @@ public:
|
||||
{
|
||||
return "or " + regIdAsString(m_source) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE; }
|
||||
};
|
||||
@ -2905,7 +2765,6 @@ public:
|
||||
{
|
||||
return util::string_format("ori #$%x,%s", m_immediate, regIdAsString(m_destination));
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -2930,7 +2789,6 @@ public:
|
||||
{
|
||||
return util::string_format("rep X:(%s)", regIdAsString(m_source));
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -2953,7 +2811,6 @@ public:
|
||||
{
|
||||
return util::string_format("rep #$%x", m_immediate);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -2979,7 +2836,6 @@ public:
|
||||
{
|
||||
return "rep " + regIdAsString(m_source);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -3003,7 +2859,6 @@ public:
|
||||
std::string opcode = "rep" + opMnemonicAsString(m_mnem);
|
||||
return opcode;
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -3027,7 +2882,6 @@ public:
|
||||
{
|
||||
return "reset";
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -3049,7 +2903,6 @@ public:
|
||||
{
|
||||
return "rnd " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -3071,7 +2924,6 @@ public:
|
||||
{
|
||||
return "rol " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE; }
|
||||
};
|
||||
@ -3093,7 +2945,6 @@ public:
|
||||
{
|
||||
return "ror " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE; }
|
||||
};
|
||||
@ -3114,7 +2965,6 @@ public:
|
||||
{
|
||||
return "rti";
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
size_t flags() const override { return util::disasm_interface::STEP_OUT; }
|
||||
@ -3136,7 +2986,6 @@ public:
|
||||
{
|
||||
return "rts";
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
size_t flags() const override { return util::disasm_interface::STEP_OUT; }
|
||||
@ -3160,7 +3009,6 @@ public:
|
||||
{
|
||||
return "sbc " + regIdAsString(m_source) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -3181,7 +3029,6 @@ public:
|
||||
{
|
||||
return "stop";
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -3204,7 +3051,6 @@ public:
|
||||
{
|
||||
return "sub " + regIdAsString(m_source) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -3230,7 +3076,6 @@ public:
|
||||
{
|
||||
return m_opcode + " " + regIdAsString(m_source) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -3265,7 +3110,6 @@ public:
|
||||
{
|
||||
return "subl " + regIdAsString(m_source) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -3287,7 +3131,6 @@ public:
|
||||
{
|
||||
return "swap " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -3308,7 +3151,6 @@ public:
|
||||
{
|
||||
return "swi";
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -3349,7 +3191,6 @@ public:
|
||||
|
||||
return retString;
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -3376,7 +3217,6 @@ public:
|
||||
{
|
||||
return "tfr " + regIdAsString(m_source) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -3399,7 +3239,6 @@ public:
|
||||
{
|
||||
return "tfr " + regIdAsString(m_source) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -3422,7 +3261,6 @@ public:
|
||||
{
|
||||
return "tfr2 " + regIdAsString(m_source) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -3464,7 +3302,6 @@ public:
|
||||
regIdAsString(m_source) + "," + regIdAsString(m_destination) + " " +
|
||||
source2 + "," + destination2;
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -3493,7 +3330,6 @@ public:
|
||||
{
|
||||
return "tst " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_NONE; }
|
||||
};
|
||||
@ -3515,7 +3351,6 @@ public:
|
||||
{
|
||||
return "tst2 " + regIdAsString(m_source);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -3536,7 +3371,6 @@ public:
|
||||
{
|
||||
return "wait";
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -3558,7 +3392,6 @@ public:
|
||||
{
|
||||
return "zero " + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
};
|
||||
@ -3599,7 +3432,6 @@ public:
|
||||
regIdAsString(m_source) + "," +
|
||||
regIdAsString(m_source2) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
@ -3643,7 +3475,6 @@ public:
|
||||
regIdAsString(m_source) + "," +
|
||||
regIdAsString(m_source2) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate(dsp56156_core* cpustate) override {}
|
||||
size_t size() const override { return 1; }
|
||||
size_t accumulatorBitsModified() const override { return BM_HIGH | BM_MIDDLE | BM_LOW; }
|
||||
|
||||
|
@ -1,12 +1,13 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:Andrew Gardner
|
||||
#include "emu.h"
|
||||
#include <cstdio>
|
||||
|
||||
#include "opcode.h"
|
||||
|
||||
namespace DSP_56156
|
||||
{
|
||||
#include <cstdio>
|
||||
|
||||
|
||||
namespace DSP_56156 {
|
||||
|
||||
Opcode::Opcode(uint16_t w0, uint16_t w1) : m_word0(w0)/*, m_word1(w1)*/
|
||||
{
|
||||
m_instruction = Instruction::decodeInstruction(this, w0, w1);
|
||||
@ -39,13 +40,6 @@ std::string Opcode::disassemble() const
|
||||
}
|
||||
|
||||
|
||||
void Opcode::evaluate(dsp56156_core* cpustate) const
|
||||
{
|
||||
if (m_instruction) m_instruction->evaluate(cpustate);
|
||||
if (m_parallelMove) m_parallelMove->evaluate();
|
||||
}
|
||||
|
||||
|
||||
size_t Opcode::size() const
|
||||
{
|
||||
if (m_instruction && m_instruction->valid())
|
||||
@ -55,15 +49,6 @@ size_t Opcode::size() const
|
||||
return 1;
|
||||
}
|
||||
|
||||
size_t Opcode::evalSize() const
|
||||
{
|
||||
if (m_instruction && m_instruction->valid())
|
||||
return m_instruction->evalSize(); // Probably doesn't matter : + m_instruction->sizeIncrement();
|
||||
|
||||
// Opcode failed to decode, so push it past dc
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
||||
const reg_id& Opcode::instSource() const { return m_instruction->source(); }
|
||||
const reg_id& Opcode::instDestination() const { return m_instruction->destination(); }
|
||||
@ -74,4 +59,4 @@ std::string Opcode::dcString() const
|
||||
return util::string_format("dc $%x", m_word0);
|
||||
}
|
||||
|
||||
}
|
||||
} // namespace DSP_56156
|
||||
|
@ -11,8 +11,8 @@
|
||||
//
|
||||
// An Opcode contains an instruction and a parallel move operation.
|
||||
//
|
||||
namespace DSP_56156
|
||||
{
|
||||
namespace DSP_56156 {
|
||||
|
||||
class Instruction;
|
||||
class ParallelMove;
|
||||
|
||||
@ -23,9 +23,7 @@ public:
|
||||
virtual ~Opcode();
|
||||
|
||||
std::string disassemble() const;
|
||||
void evaluate(dsp56156_core* cpustate) const;
|
||||
size_t size() const;
|
||||
size_t evalSize() const;
|
||||
|
||||
// Peek through to the instruction
|
||||
const reg_id& instSource() const;
|
||||
@ -42,5 +40,6 @@ private:
|
||||
std::string dcString() const;
|
||||
};
|
||||
|
||||
}
|
||||
} // namespace DSP_56156
|
||||
|
||||
#endif
|
||||
|
@ -21,7 +21,6 @@ public:
|
||||
|
||||
virtual bool decode(const uint16_t word0, const uint16_t word1) = 0;
|
||||
virtual std::string disassemble() const = 0;
|
||||
virtual void evaluate() = 0;
|
||||
|
||||
static std::unique_ptr<ParallelMove> decodeParallelMove(const Opcode* opc, const uint16_t word0, const uint16_t word1);
|
||||
|
||||
@ -74,7 +73,6 @@ public:
|
||||
{
|
||||
return m_source + "," + m_destination;
|
||||
}
|
||||
void evaluate() override {}
|
||||
|
||||
private:
|
||||
std::string m_source;
|
||||
@ -116,7 +114,6 @@ public:
|
||||
{
|
||||
return m_source + "," + m_destination;
|
||||
}
|
||||
void evaluate() override {}
|
||||
|
||||
private:
|
||||
std::string m_source;
|
||||
@ -167,7 +164,6 @@ public:
|
||||
{
|
||||
return parallelMove + " " + parallelMove2;
|
||||
}
|
||||
void evaluate() override {}
|
||||
|
||||
private:
|
||||
std::string parallelMove;
|
||||
@ -218,7 +214,6 @@ public:
|
||||
else
|
||||
return regIdAsString(m_source) + "," + regIdAsString(m_destination);
|
||||
}
|
||||
void evaluate() override {}
|
||||
|
||||
private:
|
||||
reg_id m_source;
|
||||
@ -257,7 +252,6 @@ public:
|
||||
{
|
||||
return pms + " " + pms2;
|
||||
}
|
||||
void evaluate() override {}
|
||||
|
||||
private:
|
||||
std::string pms; // TODO
|
||||
@ -286,7 +280,6 @@ public:
|
||||
{
|
||||
return m_ea;
|
||||
}
|
||||
void evaluate() override {}
|
||||
|
||||
private:
|
||||
std::string m_ea;
|
||||
@ -317,7 +310,6 @@ public:
|
||||
{
|
||||
return m_source + "," + m_destination;
|
||||
}
|
||||
void evaluate() override {}
|
||||
|
||||
private:
|
||||
std::string m_source;
|
||||
|
@ -108,7 +108,7 @@ protected:
|
||||
// device-level overrides
|
||||
virtual void device_config_complete() override;
|
||||
virtual void device_start() override;
|
||||
virtual const bool use_software_list_file_extension_for_filetype() const override { return true; }
|
||||
virtual bool use_software_list_file_extension_for_filetype() const override { return true; }
|
||||
|
||||
// device_image_interface implementation
|
||||
virtual const software_list_loader &get_software_list_loader() const override;
|
||||
|
@ -220,11 +220,6 @@ floppy_connector::~floppy_connector()
|
||||
{
|
||||
}
|
||||
|
||||
void floppy_connector::set_formats(std::function<void (format_registration &fr)> _formats)
|
||||
{
|
||||
formats = _formats;
|
||||
}
|
||||
|
||||
void floppy_connector::device_start()
|
||||
{
|
||||
}
|
||||
|
@ -461,33 +461,38 @@ class floppy_connector: public device_t,
|
||||
public device_slot_interface
|
||||
{
|
||||
public:
|
||||
template <typename T>
|
||||
floppy_connector(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt, std::function<void (format_registration &fr)> formats, bool fixed = false)
|
||||
|
||||
template <typename T, typename U>
|
||||
floppy_connector(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt, U &&formats, bool fixed = false)
|
||||
: floppy_connector(mconfig, tag, owner, 0)
|
||||
{
|
||||
option_reset();
|
||||
opts(*this);
|
||||
set_default_option(dflt);
|
||||
set_fixed(fixed);
|
||||
set_formats(formats);
|
||||
set_formats(std::forward<U>(formats));
|
||||
}
|
||||
floppy_connector(const machine_config &mconfig, const char *tag, device_t *owner, const char *option, const device_type &devtype, bool is_default, std::function<void (format_registration &fr)> formats)
|
||||
|
||||
template <typename T>
|
||||
floppy_connector(const machine_config &mconfig, const char *tag, device_t *owner, const char *option, device_type drivetype, bool is_default, T &&formats)
|
||||
: floppy_connector(mconfig, tag, owner, 0)
|
||||
{
|
||||
option_reset();
|
||||
option_add(option, devtype);
|
||||
option_add(option, drivetype);
|
||||
if(is_default)
|
||||
set_default_option(option);
|
||||
set_fixed(false);
|
||||
set_formats(formats);
|
||||
set_formats(std::forward<T>(formats));
|
||||
}
|
||||
|
||||
floppy_connector(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0);
|
||||
virtual ~floppy_connector();
|
||||
|
||||
void set_formats(std::function<void (format_registration &fr)> formats);
|
||||
floppy_image_device *get_device();
|
||||
template <typename T> void set_formats(T &&_formats) { formats = std::forward<T>(_formats); }
|
||||
void enable_sound(bool doit) { m_enable_sound = doit; }
|
||||
|
||||
floppy_image_device *get_device();
|
||||
|
||||
protected:
|
||||
virtual void device_start() override;
|
||||
virtual void device_config_complete() override;
|
||||
|
@ -217,7 +217,7 @@ protected:
|
||||
virtual void interface_config_complete() override;
|
||||
|
||||
virtual const software_list_loader &get_software_list_loader() const;
|
||||
virtual const bool use_software_list_file_extension_for_filetype() const { return false; }
|
||||
virtual bool use_software_list_file_extension_for_filetype() const { return false; }
|
||||
|
||||
image_init_result load_internal(std::string_view path, bool is_create, int create_format, util::option_resolution *create_args);
|
||||
std::error_condition load_image_by_path(u32 open_flags, std::string_view path);
|
||||
|
@ -28,7 +28,7 @@ device_slot_interface::~device_slot_interface()
|
||||
}
|
||||
|
||||
|
||||
device_slot_interface::slot_option::slot_option(const char *name, const device_type &devtype, bool selectable) :
|
||||
device_slot_interface::slot_option::slot_option(const char *name, device_type devtype, bool selectable) :
|
||||
m_name(name),
|
||||
m_devtype(devtype),
|
||||
m_selectable(selectable),
|
||||
@ -47,7 +47,7 @@ void device_slot_interface::interface_validity_check(validity_checker &valid) co
|
||||
}
|
||||
|
||||
|
||||
device_slot_interface::slot_option &device_slot_interface::option_add(const char *name, const device_type &devtype)
|
||||
device_slot_interface::slot_option &device_slot_interface::option_add(const char *name, device_type devtype)
|
||||
{
|
||||
if (!name || !*name)
|
||||
throw emu_fatalerror("slot '%s' attempt to add option without name\n", device().tag());
|
||||
@ -60,7 +60,7 @@ device_slot_interface::slot_option &device_slot_interface::option_add(const char
|
||||
}
|
||||
|
||||
|
||||
device_slot_interface::slot_option &device_slot_interface::option_add_internal(const char *name, const device_type &devtype)
|
||||
device_slot_interface::slot_option &device_slot_interface::option_add_internal(const char *name, device_type devtype)
|
||||
{
|
||||
if (!name || !*name)
|
||||
throw emu_fatalerror("slot '%s' attempt to add option without name\n", device().tag());
|
||||
@ -73,7 +73,7 @@ device_slot_interface::slot_option &device_slot_interface::option_add_internal(c
|
||||
}
|
||||
|
||||
|
||||
device_slot_interface::slot_option &device_slot_interface::option_replace(const char *name, const device_type &devtype)
|
||||
device_slot_interface::slot_option &device_slot_interface::option_replace(const char *name, device_type devtype)
|
||||
{
|
||||
if (!name || !*name)
|
||||
throw emu_fatalerror("slot '%s' attempt to replace option without name\n", device().tag());
|
||||
@ -86,7 +86,7 @@ device_slot_interface::slot_option &device_slot_interface::option_replace(const
|
||||
}
|
||||
|
||||
|
||||
device_slot_interface::slot_option &device_slot_interface::option_replace_internal(const char *name, const device_type &devtype)
|
||||
device_slot_interface::slot_option &device_slot_interface::option_replace_internal(const char *name, device_type devtype)
|
||||
{
|
||||
if (!name || !*name)
|
||||
throw emu_fatalerror("slot '%s' attempt to replace option without name\n", device().tag());
|
||||
|
@ -46,10 +46,10 @@ public:
|
||||
class slot_option
|
||||
{
|
||||
public:
|
||||
slot_option(char const *name, device_type const &devtype, bool selectable);
|
||||
slot_option(char const *name, device_type devtype, bool selectable);
|
||||
|
||||
char const *name() const { return m_name; }
|
||||
device_type const &devtype() const { return m_devtype; }
|
||||
device_type devtype() const { return m_devtype; }
|
||||
bool selectable() const { return m_selectable; }
|
||||
char const *default_bios() const { return m_default_bios; }
|
||||
std::function<void (device_t *)> const &machine_config() const { return m_machine_config; }
|
||||
@ -116,7 +116,7 @@ public:
|
||||
/// description is used in the user interface.
|
||||
/// \return A reference to the added option for additional
|
||||
/// configuration.
|
||||
slot_option &option_add(char const *option, const device_type &devtype);
|
||||
slot_option &option_add(char const *option, device_type devtype);
|
||||
|
||||
/// \brief Add an internal option
|
||||
///
|
||||
@ -130,10 +130,10 @@ public:
|
||||
/// description is used in the user interface.
|
||||
/// \return A reference to the added option for additional
|
||||
/// configuration.
|
||||
slot_option &option_add_internal(const char *option, const device_type &devtype);
|
||||
slot_option &option_add_internal(const char *option, device_type devtype);
|
||||
|
||||
slot_option &option_replace(const char *option, const device_type &devtype);
|
||||
slot_option &option_replace_internal(const char *option, const device_type &devtype);
|
||||
slot_option &option_replace(const char *option, device_type devtype);
|
||||
slot_option &option_replace_internal(const char *option, device_type devtype);
|
||||
void option_remove(const char *option);
|
||||
|
||||
void set_option_default_bios(const char *option, const char *default_bios) { config_option(option)->default_bios(default_bios); }
|
||||
@ -166,7 +166,7 @@ public:
|
||||
device_t *get_card_device() const { return m_card_device; }
|
||||
void set_card_device(device_t *dev) { m_card_device = dev; }
|
||||
const char *slot_name() const { return device().tag() + 1; }
|
||||
slot_option &option_set(const char *tag, const device_type &devtype) { m_default_option = tag; m_fixed = true; return option_add_internal(tag, devtype); }
|
||||
slot_option &option_set(const char *tag, device_type devtype) { m_default_option = tag; m_fixed = true; return option_add_internal(tag, devtype); }
|
||||
|
||||
protected:
|
||||
device_slot_interface(machine_config const &mconfig, device_t &device);
|
||||
|
@ -164,8 +164,8 @@ protected:
|
||||
return (uintptr_t(selected_ref) > m_skip_main_items) ? selected_ref : m_prev_selected;
|
||||
}
|
||||
|
||||
u8 const right_panel() const { return m_right_panel; }
|
||||
u8 const right_image() const { return m_image_view; }
|
||||
u8 right_panel() const { return m_right_panel; }
|
||||
u8 right_image() const { return m_image_view; }
|
||||
char const *right_panel_config_string() const;
|
||||
char const *right_image_config_string() const;
|
||||
void set_right_panel(u8 index);
|
||||
|
@ -109,7 +109,7 @@ public:
|
||||
}
|
||||
|
||||
// accessors
|
||||
const option_type type() const { return m_type; }
|
||||
option_type type() const { return m_type; }
|
||||
int parameter() const { return m_parameter; }
|
||||
const char *identifier() const { return m_identifier; }
|
||||
const char *display_name() const { return m_display_name; }
|
||||
|
@ -14,7 +14,6 @@
|
||||
#include "machine/pci.h"
|
||||
|
||||
class bandit_host_device : public pci_host_device {
|
||||
friend class aspen_host_device;
|
||||
public:
|
||||
template <typename T>
|
||||
bandit_host_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, T &&cpu_tag)
|
||||
@ -22,13 +21,14 @@ public:
|
||||
{
|
||||
set_cpu_tag(std::forward<T>(cpu_tag));
|
||||
}
|
||||
bandit_host_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock);
|
||||
bandit_host_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock);
|
||||
|
||||
template <typename T> void set_cpu_tag(T &&tag) { m_cpu.set_tag(std::forward<T>(tag)); }
|
||||
void set_dev_offset(int devOffset) { m_dev_offset = devOffset; }
|
||||
|
||||
protected:
|
||||
bandit_host_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock);
|
||||
|
||||
virtual void device_start() override;
|
||||
virtual void device_reset() override;
|
||||
|
||||
@ -69,8 +69,6 @@ public:
|
||||
}
|
||||
aspen_host_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock);
|
||||
|
||||
protected:
|
||||
|
||||
private:
|
||||
virtual u32 be_config_address_r() override;
|
||||
virtual void be_config_address_w(offs_t offset, u32 data, u32 mem_mask = ~0) override;
|
||||
|
@ -237,9 +237,9 @@ void bsuprem_state::ay8910_w(offs_t offset, uint8_t data)
|
||||
// a10 -> ay8910_1 A8, ay8910_2 !A9
|
||||
// a9 -> ay8910_1 !A9, ay8910_2 A8
|
||||
// a8 -> ay8910 BC2
|
||||
if(BIT(offset, 10) != BIT(offset, 9))
|
||||
if (BIT(offset, 10) != BIT(offset, 9))
|
||||
{
|
||||
if(BIT(offset, 8))
|
||||
if (BIT(offset, 8))
|
||||
{
|
||||
m_psg[BIT(offset, 9)]->data_w(offset & 0xff);
|
||||
}
|
||||
@ -273,44 +273,36 @@ void bsuprem_state::ay8910_u1_portb_w(uint8_t data)
|
||||
|
||||
data = (data>>4) & 0x0f;
|
||||
|
||||
switch(data)
|
||||
switch (data)
|
||||
{
|
||||
case 0x00:
|
||||
case 0x01:
|
||||
case 0x02:
|
||||
case 0x03:
|
||||
case 0x04:
|
||||
for(int i = 0; i < 8 ; i++)
|
||||
{
|
||||
m_lamps[(data*8) + i] = BIT(m_u1_porta_data, i);
|
||||
}
|
||||
for (int i = 0; i < 8 ; i++)
|
||||
m_lamps[(data * 8) + i] = BIT(m_u1_porta_data, i);
|
||||
break;
|
||||
|
||||
case 0x05:
|
||||
for(int i = 0; i < 5 ; i++)
|
||||
{
|
||||
for (int i = 0; i < 5 ; i++)
|
||||
m_lamps[40 + i] = BIT(m_u1_porta_data, i);
|
||||
}
|
||||
break;
|
||||
|
||||
case 0x08:
|
||||
{
|
||||
m_nixie[0] = m_u1_porta_data & 0x07;
|
||||
m_nixie[1] = (m_u1_porta_data>>4) & 0x07;
|
||||
}
|
||||
m_nixie[0] = m_u1_porta_data & 0x07;
|
||||
m_nixie[1] = (m_u1_porta_data >> 4) & 0x07;
|
||||
break;
|
||||
|
||||
case 0x09:
|
||||
{
|
||||
m_nixie[2] = (m_u1_porta_data>>3) & 0x07;
|
||||
m_nixie[3] = m_u1_porta_data & 0x07;
|
||||
}
|
||||
m_nixie[2] = (m_u1_porta_data >> 3) & 0x07;
|
||||
m_nixie[3] = m_u1_porta_data & 0x07;
|
||||
break;
|
||||
|
||||
case 0x0a:
|
||||
case 0x0b:
|
||||
case 0x0c:
|
||||
m_digits[(0x0c - data) * 2] = patterns[(m_u1_porta_data>>4) & 0x0f];
|
||||
m_digits[(0x0c - data) * 2] = patterns[(m_u1_porta_data >> 4) & 0x0f];
|
||||
m_digits[((0x0c - data) * 2) + 1] = patterns[m_u1_porta_data & 0x0f];
|
||||
break;
|
||||
}
|
||||
@ -356,14 +348,7 @@ INTERRUPT_GEN_MEMBER(bsuprem_state::mains_irq)
|
||||
{
|
||||
m_irq_state = !m_irq_state;
|
||||
|
||||
if(m_irq_state)
|
||||
{
|
||||
m_maincpu->set_input_line(0, ASSERT_LINE);
|
||||
}
|
||||
else
|
||||
{
|
||||
m_maincpu->set_input_line(0, CLEAR_LINE);
|
||||
}
|
||||
m_maincpu->set_input_line(0, m_irq_state ? ASSERT_LINE : CLEAR_LINE);
|
||||
}
|
||||
|
||||
INPUT_CHANGED_MEMBER(bsuprem_state::test_pressed)
|
||||
|
@ -1328,85 +1328,86 @@ int32_t const n64_rdp::s_rdp_command_length[64] =
|
||||
8 // 0x3f, Set_Color_Image
|
||||
};
|
||||
|
||||
namespace
|
||||
namespace {
|
||||
|
||||
std::string disassemble_vertices(const std::string &op_name, int32_t lft, const uint64_t *cmd_buf)
|
||||
{
|
||||
std::string disassemble_vertices(const std::string &op_name, int32_t lft, const uint64_t *cmd_buf)
|
||||
{
|
||||
float yl = ((cmd_buf[0] >> 32) & 0x1fff) / 4.0f;
|
||||
float ym = ((cmd_buf[0] >> 16) & 0x1fff) / 4.0f;
|
||||
float yh = ((cmd_buf[0] >> 0) & 0x1fff) / 4.0f;
|
||||
const float yl = ((cmd_buf[0] >> 32) & 0x1fff) / 4.0f;
|
||||
const float ym = ((cmd_buf[0] >> 16) & 0x1fff) / 4.0f;
|
||||
const float yh = ((cmd_buf[0] >> 0) & 0x1fff) / 4.0f;
|
||||
|
||||
float xl = int32_t(cmd_buf[1] >> 32) / 65536.0f;
|
||||
float xh = int32_t(cmd_buf[2] >> 32) / 65536.0f;
|
||||
float xm = int32_t(cmd_buf[3] >> 32) / 65536.0f;
|
||||
const float xl = int32_t(cmd_buf[1] >> 32) / 65536.0f;
|
||||
const float xh = int32_t(cmd_buf[2] >> 32) / 65536.0f;
|
||||
const float xm = int32_t(cmd_buf[3] >> 32) / 65536.0f;
|
||||
|
||||
// (Currently?) not displayed
|
||||
// auto dxldy = int32_t(cmd_buf[1]) / 65536.0f;
|
||||
// auto dxhdy = int32_t(cmd_buf[2]) / 65536.0f;
|
||||
// auto dxmdy = int32_t(cmd_buf[3]) / 65536.0f;
|
||||
// (Currently?) not displayed
|
||||
[[maybe_unused]] const float dxldy = int32_t(cmd_buf[1]) / 65536.0f;
|
||||
[[maybe_unused]] const float dxhdy = int32_t(cmd_buf[2]) / 65536.0f;
|
||||
[[maybe_unused]] const float dxmdy = int32_t(cmd_buf[3]) / 65536.0f;
|
||||
|
||||
return util::string_format("%-20s %d, XL: %4.4f, XM: %4.4f, XH: %4.4f, YL: %4.4f, YM: %4.4f, YH: %4.4f\n", op_name, lft, xl, xm, xh, yl, ym, yh);
|
||||
}
|
||||
|
||||
std::string disassemble_rgb(const uint64_t *cmd_buf)
|
||||
{
|
||||
float rt = int32_t(((cmd_buf[4] >> 32) & 0xffff0000) | ((cmd_buf[6] >> 48) & 0xffff)) / 65536.0f;
|
||||
float gt = int32_t((((cmd_buf[4] >> 32) & 0x0000ffff) << 16) | ((cmd_buf[6] >> 32) & 0xffff)) / 65536.0f;
|
||||
float bt = int32_t((cmd_buf[4] & 0xffff0000) | ((cmd_buf[6] >> 16) & 0xffff)) / 65536.0f;
|
||||
float at = int32_t(((cmd_buf[4] & 0x0000ffff) << 16) | (cmd_buf[6] & 0xffff)) / 65536.0f;
|
||||
float drdx = int32_t(((cmd_buf[5] >> 32) & 0xffff0000) | ((cmd_buf[7] >> 48) & 0xffff)) / 65536.0f;
|
||||
float dgdx = int32_t((((cmd_buf[5] >> 32) & 0x0000ffff) << 16) | ((cmd_buf[7] >> 32) & 0xffff)) / 65536.0f;
|
||||
float dbdx = int32_t((cmd_buf[5] & 0xffff0000) | ((cmd_buf[7] >> 16) & 0xffff)) / 65536.0f;
|
||||
float dadx = int32_t(((cmd_buf[5] & 0x0000ffff) << 16) | (cmd_buf[7] & 0xffff)) / 65536.0f;
|
||||
float drde = int32_t(((cmd_buf[8] >> 32) & 0xffff0000) | ((cmd_buf[10] >> 48) & 0xffff)) / 65536.0f;
|
||||
float dgde = int32_t((((cmd_buf[8] >> 32) & 0x0000ffff) << 16) | ((cmd_buf[10] >> 32) & 0xffff)) / 65536.0f;
|
||||
float dbde = int32_t((cmd_buf[8] & 0xffff0000) | ((cmd_buf[10] >> 16) & 0xffff)) / 65536.0f;
|
||||
float dade = int32_t(((cmd_buf[8] & 0x0000ffff) << 16) | (cmd_buf[10] & 0xffff)) / 65536.0f;
|
||||
float drdy = int32_t(((cmd_buf[9] >> 32) & 0xffff0000) | ((cmd_buf[11] >> 48) & 0xffff)) / 65536.0f;
|
||||
float dgdy = int32_t((((cmd_buf[9] >> 32) & 0x0000ffff) << 16) | ((cmd_buf[11] >> 32) & 0xffff)) / 65536.0f;
|
||||
float dbdy = int32_t((cmd_buf[9] & 0xffff0000) | ((cmd_buf[11] >> 16) & 0xffff)) / 65536.0f;
|
||||
float dady = int32_t(((cmd_buf[9] & 0x0000ffff) << 16) | (cmd_buf[11] & 0xffff)) / 65536.0f;
|
||||
|
||||
std::ostringstream buffer;
|
||||
buffer << " ";
|
||||
util::stream_format(buffer, " R: %4.4f, G: %4.4f, B: %4.4f, A: %4.4f\n", rt, gt, bt, at);
|
||||
buffer << " ";
|
||||
util::stream_format(buffer, " DRDX: %4.4f, DGDX: %4.4f, DBDX: %4.4f, DADX: %4.4f\n", drdx, dgdx, dbdx, dadx);
|
||||
buffer << " ";
|
||||
util::stream_format(buffer, " DRDE: %4.4f, DGDE: %4.4f, DBDE: %4.4f, DADE: %4.4f\n", drde, dgde, dbde, dade);
|
||||
buffer << " ";
|
||||
util::stream_format(buffer, " DRDY: %4.4f, DGDY: %4.4f, DBDY: %4.4f, DADY: %4.4f\n", drdy, dgdy, dbdy, dady);
|
||||
return std::move(buffer).str();
|
||||
}
|
||||
|
||||
std::string disassemble_stw(const uint64_t *cmd_buf)
|
||||
{
|
||||
float s = int32_t(((cmd_buf[4] >> 32) & 0xffff0000) | ((cmd_buf[6] >> 48) & 0xffff)) / 65536.0f;
|
||||
float t = int32_t((((cmd_buf[4] >> 32) & 0x0000ffff) << 16) | ((cmd_buf[6] >> 32) & 0xffff)) / 65536.0f;
|
||||
float w = int32_t((cmd_buf[4] & 0xffff0000) | ((cmd_buf[6] >> 16) & 0xffff)) / 65536.0f;
|
||||
float dsdx = int32_t(((cmd_buf[5] >> 32) & 0xffff0000) | ((cmd_buf[7] >> 48) & 0xffff)) / 65536.0f;
|
||||
float dtdx = int32_t((((cmd_buf[5] >> 32) & 0x0000ffff) << 16) | ((cmd_buf[7] >> 32) & 0xffff)) / 65536.0f;
|
||||
float dwdx = int32_t((cmd_buf[5] & 0xffff0000) | ((cmd_buf[7] >> 16) & 0xffff)) / 65536.0f;
|
||||
float dsde = int32_t(((cmd_buf[8] >> 32) & 0xffff0000) | ((cmd_buf[10] >> 48) & 0xffff)) / 65536.0f;
|
||||
float dtde = int32_t((((cmd_buf[8] >> 32) & 0x0000ffff) << 16) | ((cmd_buf[10] >> 32) & 0xffff)) / 65536.0f;
|
||||
float dwde = int32_t((cmd_buf[8] & 0xffff0000) | ((cmd_buf[10] >> 16) & 0xffff)) / 65536.0f;
|
||||
float dsdy = int32_t(((cmd_buf[9] >> 32) & 0xffff0000) | ((cmd_buf[11] >> 48) & 0xffff)) / 65536.0f;
|
||||
float dtdy = int32_t((((cmd_buf[9] >> 32) & 0x0000ffff) << 16) | ((cmd_buf[11] >> 32) & 0xffff)) / 65536.0f;
|
||||
float dwdy = int32_t((cmd_buf[9] & 0xffff0000) | ((cmd_buf[11] >> 16) & 0xffff)) / 65536.0f;
|
||||
|
||||
std::ostringstream buffer;
|
||||
buffer << " ";
|
||||
util::stream_format(buffer, " S: %4.4f, T: %4.4f, W: %4.4f\n", s, t, w);
|
||||
buffer << " ";
|
||||
util::stream_format(buffer, " DSDX: %4.4f, DTDX: %4.4f, DWDX: %4.4f\n", dsdx, dtdx, dwdx);
|
||||
buffer << " ";
|
||||
util::stream_format(buffer, " DSDE: %4.4f, DTDE: %4.4f, DWDE: %4.4f\n", dsde, dtde, dwde);
|
||||
buffer << " ";
|
||||
util::stream_format(buffer, " DSDY: %4.4f, DTDY: %4.4f, DWDY: %4.4f\n", dsdy, dtdy, dwdy);
|
||||
return std::move(buffer).str();
|
||||
}
|
||||
return util::string_format("%-20s %d, XL: %4.4f, XM: %4.4f, XH: %4.4f, YL: %4.4f, YM: %4.4f, YH: %4.4f\n", op_name, lft, xl, xm, xh, yl, ym, yh);
|
||||
}
|
||||
|
||||
std::string disassemble_rgb(const uint64_t *cmd_buf)
|
||||
{
|
||||
const float rt = int32_t(((cmd_buf[4] >> 32) & 0xffff0000) | ((cmd_buf[6] >> 48) & 0xffff)) / 65536.0f;
|
||||
const float gt = int32_t((((cmd_buf[4] >> 32) & 0x0000ffff) << 16) | ((cmd_buf[6] >> 32) & 0xffff)) / 65536.0f;
|
||||
const float bt = int32_t((cmd_buf[4] & 0xffff0000) | ((cmd_buf[6] >> 16) & 0xffff)) / 65536.0f;
|
||||
const float at = int32_t(((cmd_buf[4] & 0x0000ffff) << 16) | (cmd_buf[6] & 0xffff)) / 65536.0f;
|
||||
const float drdx = int32_t(((cmd_buf[5] >> 32) & 0xffff0000) | ((cmd_buf[7] >> 48) & 0xffff)) / 65536.0f;
|
||||
const float dgdx = int32_t((((cmd_buf[5] >> 32) & 0x0000ffff) << 16) | ((cmd_buf[7] >> 32) & 0xffff)) / 65536.0f;
|
||||
const float dbdx = int32_t((cmd_buf[5] & 0xffff0000) | ((cmd_buf[7] >> 16) & 0xffff)) / 65536.0f;
|
||||
const float dadx = int32_t(((cmd_buf[5] & 0x0000ffff) << 16) | (cmd_buf[7] & 0xffff)) / 65536.0f;
|
||||
const float drde = int32_t(((cmd_buf[8] >> 32) & 0xffff0000) | ((cmd_buf[10] >> 48) & 0xffff)) / 65536.0f;
|
||||
const float dgde = int32_t((((cmd_buf[8] >> 32) & 0x0000ffff) << 16) | ((cmd_buf[10] >> 32) & 0xffff)) / 65536.0f;
|
||||
const float dbde = int32_t((cmd_buf[8] & 0xffff0000) | ((cmd_buf[10] >> 16) & 0xffff)) / 65536.0f;
|
||||
const float dade = int32_t(((cmd_buf[8] & 0x0000ffff) << 16) | (cmd_buf[10] & 0xffff)) / 65536.0f;
|
||||
const float drdy = int32_t(((cmd_buf[9] >> 32) & 0xffff0000) | ((cmd_buf[11] >> 48) & 0xffff)) / 65536.0f;
|
||||
const float dgdy = int32_t((((cmd_buf[9] >> 32) & 0x0000ffff) << 16) | ((cmd_buf[11] >> 32) & 0xffff)) / 65536.0f;
|
||||
const float dbdy = int32_t((cmd_buf[9] & 0xffff0000) | ((cmd_buf[11] >> 16) & 0xffff)) / 65536.0f;
|
||||
const float dady = int32_t(((cmd_buf[9] & 0x0000ffff) << 16) | (cmd_buf[11] & 0xffff)) / 65536.0f;
|
||||
|
||||
std::ostringstream buffer;
|
||||
buffer << " ";
|
||||
util::stream_format(buffer, " R: %4.4f, G: %4.4f, B: %4.4f, A: %4.4f\n", rt, gt, bt, at);
|
||||
buffer << " ";
|
||||
util::stream_format(buffer, " DRDX: %4.4f, DGDX: %4.4f, DBDX: %4.4f, DADX: %4.4f\n", drdx, dgdx, dbdx, dadx);
|
||||
buffer << " ";
|
||||
util::stream_format(buffer, " DRDE: %4.4f, DGDE: %4.4f, DBDE: %4.4f, DADE: %4.4f\n", drde, dgde, dbde, dade);
|
||||
buffer << " ";
|
||||
util::stream_format(buffer, " DRDY: %4.4f, DGDY: %4.4f, DBDY: %4.4f, DADY: %4.4f\n", drdy, dgdy, dbdy, dady);
|
||||
return std::move(buffer).str();
|
||||
}
|
||||
|
||||
std::string disassemble_stw(const uint64_t *cmd_buf)
|
||||
{
|
||||
const float s = int32_t(((cmd_buf[4] >> 32) & 0xffff0000) | ((cmd_buf[6] >> 48) & 0xffff)) / 65536.0f;
|
||||
const float t = int32_t((((cmd_buf[4] >> 32) & 0x0000ffff) << 16) | ((cmd_buf[6] >> 32) & 0xffff)) / 65536.0f;
|
||||
const float w = int32_t((cmd_buf[4] & 0xffff0000) | ((cmd_buf[6] >> 16) & 0xffff)) / 65536.0f;
|
||||
const float dsdx = int32_t(((cmd_buf[5] >> 32) & 0xffff0000) | ((cmd_buf[7] >> 48) & 0xffff)) / 65536.0f;
|
||||
const float dtdx = int32_t((((cmd_buf[5] >> 32) & 0x0000ffff) << 16) | ((cmd_buf[7] >> 32) & 0xffff)) / 65536.0f;
|
||||
const float dwdx = int32_t((cmd_buf[5] & 0xffff0000) | ((cmd_buf[7] >> 16) & 0xffff)) / 65536.0f;
|
||||
const float dsde = int32_t(((cmd_buf[8] >> 32) & 0xffff0000) | ((cmd_buf[10] >> 48) & 0xffff)) / 65536.0f;
|
||||
const float dtde = int32_t((((cmd_buf[8] >> 32) & 0x0000ffff) << 16) | ((cmd_buf[10] >> 32) & 0xffff)) / 65536.0f;
|
||||
const float dwde = int32_t((cmd_buf[8] & 0xffff0000) | ((cmd_buf[10] >> 16) & 0xffff)) / 65536.0f;
|
||||
const float dsdy = int32_t(((cmd_buf[9] >> 32) & 0xffff0000) | ((cmd_buf[11] >> 48) & 0xffff)) / 65536.0f;
|
||||
const float dtdy = int32_t((((cmd_buf[9] >> 32) & 0x0000ffff) << 16) | ((cmd_buf[11] >> 32) & 0xffff)) / 65536.0f;
|
||||
const float dwdy = int32_t((cmd_buf[9] & 0xffff0000) | ((cmd_buf[11] >> 16) & 0xffff)) / 65536.0f;
|
||||
|
||||
std::ostringstream buffer;
|
||||
buffer << " ";
|
||||
util::stream_format(buffer, " S: %4.4f, T: %4.4f, W: %4.4f\n", s, t, w);
|
||||
buffer << " ";
|
||||
util::stream_format(buffer, " DSDX: %4.4f, DTDX: %4.4f, DWDX: %4.4f\n", dsdx, dtdx, dwdx);
|
||||
buffer << " ";
|
||||
util::stream_format(buffer, " DSDE: %4.4f, DTDE: %4.4f, DWDE: %4.4f\n", dsde, dtde, dwde);
|
||||
buffer << " ";
|
||||
util::stream_format(buffer, " DSDY: %4.4f, DTDY: %4.4f, DWDY: %4.4f\n", dsdy, dtdy, dwdy);
|
||||
return std::move(buffer).str();
|
||||
}
|
||||
|
||||
} // anonymous namespace
|
||||
|
||||
std::string n64_rdp::disassemble(const uint64_t *cmd_buf)
|
||||
{
|
||||
std::ostringstream buffer;
|
||||
@ -1488,10 +1489,10 @@ std::string n64_rdp::disassemble(const uint64_t *cmd_buf)
|
||||
case 0x24:
|
||||
case 0x25:
|
||||
{
|
||||
float s = int16_t((cmd_buf[1] >> 48) & 0xffff) / 32.0f;
|
||||
float t = int16_t((cmd_buf[1] >> 32) & 0xffff) / 32.0f;
|
||||
float dsdx = int16_t((cmd_buf[1] >> 16) & 0xffff) / 1024.0f;
|
||||
float dtdy = int16_t((cmd_buf[1] >> 0) & 0xffff) / 1024.0f;
|
||||
const float s = int16_t((cmd_buf[1] >> 48) & 0xffff) / 32.0f;
|
||||
const float t = int16_t((cmd_buf[1] >> 32) & 0xffff) / 32.0f;
|
||||
const float dsdx = int16_t((cmd_buf[1] >> 16) & 0xffff) / 1024.0f;
|
||||
const float dtdy = int16_t((cmd_buf[1] >> 0) & 0xffff) / 1024.0f;
|
||||
|
||||
if (command == 0x24)
|
||||
util::stream_format(buffer, "Texture_Rectangle %d, %s, %s, %s, %s, %4.4f, %4.4f, %4.4f, %4.4f", tile, sh, th, sl, tl, s, t, dsdx, dtdy);
|
||||
|
@ -182,6 +182,8 @@ protected:
|
||||
class nws3410_state : public news_r3k_base_state
|
||||
{
|
||||
public:
|
||||
static constexpr feature_type unemulated_features() { return feature::GRAPHICS; }
|
||||
|
||||
nws3410_state(machine_config const &mconfig, device_type type, char const *tag)
|
||||
: news_r3k_base_state(mconfig, type, tag)
|
||||
{
|
||||
@ -189,8 +191,6 @@ public:
|
||||
|
||||
void nws3410(machine_config &config);
|
||||
|
||||
static constexpr feature_type unemulated_features() { return feature::GRAPHICS; }
|
||||
|
||||
protected:
|
||||
void nws3410_map(address_map &map);
|
||||
};
|
||||
|
@ -131,6 +131,8 @@ namespace {
|
||||
class news_r4k_state : public driver_device
|
||||
{
|
||||
public:
|
||||
static constexpr feature_type unemulated_features() { return feature::GRAPHICS; }
|
||||
|
||||
news_r4k_state(machine_config const &mconfig, device_type type, char const *tag) :
|
||||
driver_device(mconfig, type, tag),
|
||||
m_cpu(*this, "cpu"),
|
||||
@ -158,8 +160,6 @@ public:
|
||||
|
||||
void nws5000x(machine_config &config);
|
||||
|
||||
static constexpr feature_type unemulated_features() { return feature::GRAPHICS; }
|
||||
|
||||
protected:
|
||||
|
||||
enum irq0_number : uint32_t
|
||||
|
@ -183,7 +183,7 @@ public:
|
||||
// PortAudio options
|
||||
const char *pa_api() const { return value(OSDOPTION_PA_API); }
|
||||
const char *pa_device() const { return value(OSDOPTION_PA_DEVICE); }
|
||||
const float pa_latency() const { return float_value(OSDOPTION_PA_LATENCY); }
|
||||
float pa_latency() const { return float_value(OSDOPTION_PA_LATENCY); }
|
||||
|
||||
static const options_entry s_option_entries[];
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user