++coding-style.
git-svn-id: https://www4.informatik.uni-erlangen.de/i4svn/danceos/trunk/devel/fail@1388 8c4709b5-6ec9-48aa-a5cd-a96041d1645a
This commit is contained in:
@ -29,8 +29,7 @@ BochsController::BochsController()
|
|||||||
const std::string names[] = { "RAX", "RCX", "RDX", "RBX", "RSP", "RBP", "RSI",
|
const std::string names[] = { "RAX", "RCX", "RDX", "RBX", "RSP", "RBP", "RSI",
|
||||||
"RDI", "R8", "R9", "R10", "R11", "R12", "R13",
|
"RDI", "R8", "R9", "R10", "R11", "R12", "R13",
|
||||||
"R14", "R15" };
|
"R14", "R15" };
|
||||||
for(unsigned short i = 0; i < 16; i++)
|
for (unsigned short i = 0; i < 16; i++) {
|
||||||
{
|
|
||||||
BxGPReg* pReg = new BxGPReg(i, 64, &(BX_CPU(0)->gen_reg[i].rrx));
|
BxGPReg* pReg = new BxGPReg(i, 64, &(BX_CPU(0)->gen_reg[i].rrx));
|
||||||
pReg->setName(names[i]);
|
pReg->setName(names[i]);
|
||||||
m_Regs->add(pReg);
|
m_Regs->add(pReg);
|
||||||
@ -39,8 +38,7 @@ BochsController::BochsController()
|
|||||||
// -- 32 bit register --
|
// -- 32 bit register --
|
||||||
const std::string names[] = { "EAX", "ECX", "EDX", "EBX", "ESP", "EBP", "ESI",
|
const std::string names[] = { "EAX", "ECX", "EDX", "EBX", "ESP", "EBP", "ESI",
|
||||||
"EDI" };
|
"EDI" };
|
||||||
for(unsigned short i = 0; i < 8; i++)
|
for (unsigned short i = 0; i < 8; i++) {
|
||||||
{
|
|
||||||
BxGPReg* pReg = new BxGPReg(i, 32, &(BX_CPU(0)->gen_reg[i].dword.erx));
|
BxGPReg* pReg = new BxGPReg(i, 32, &(BX_CPU(0)->gen_reg[i].dword.erx));
|
||||||
pReg->setName(names[i]);
|
pReg->setName(names[i]);
|
||||||
m_Regs->add(pReg);
|
m_Regs->add(pReg);
|
||||||
@ -105,11 +103,9 @@ void BochsController::onInstrPtrChanged(address_t instrPtr, address_t address_sp
|
|||||||
// Check for active breakpoint-events:
|
// Check for active breakpoint-events:
|
||||||
bp_cache_t &buffer_cache = m_EvList.getBPBuffer();
|
bp_cache_t &buffer_cache = m_EvList.getBPBuffer();
|
||||||
bp_cache_t::iterator it = buffer_cache.begin();
|
bp_cache_t::iterator it = buffer_cache.begin();
|
||||||
while(it != buffer_cache.end())
|
while (it != buffer_cache.end()) {
|
||||||
{
|
|
||||||
BPEvent* pEvBreakpt = *it;
|
BPEvent* pEvBreakpt = *it;
|
||||||
if(pEvBreakpt->isMatching(instrPtr, address_space))
|
if (pEvBreakpt->isMatching(instrPtr, address_space)) {
|
||||||
{
|
|
||||||
pEvBreakpt->setTriggerInstructionPointer(instrPtr);
|
pEvBreakpt->setTriggerInstructionPointer(instrPtr);
|
||||||
it = buffer_cache.makeActive(m_EvList, it);
|
it = buffer_cache.makeActive(m_EvList, it);
|
||||||
do_fire = true;
|
do_fire = true;
|
||||||
@ -129,11 +125,9 @@ void BochsController::onIOPortEvent(unsigned char data, unsigned port, bool out)
|
|||||||
// Check for active breakpoint-events:
|
// Check for active breakpoint-events:
|
||||||
io_cache_t &buffer_cache = m_EvList.getIOBuffer();
|
io_cache_t &buffer_cache = m_EvList.getIOBuffer();
|
||||||
io_cache_t::iterator it = buffer_cache.begin();
|
io_cache_t::iterator it = buffer_cache.begin();
|
||||||
while(it != buffer_cache.end())
|
while (it != buffer_cache.end()) {
|
||||||
{
|
|
||||||
IOPortEvent* pIOPt = (*it);
|
IOPortEvent* pIOPt = (*it);
|
||||||
if(pIOPt->isMatching(port, out))
|
if (pIOPt->isMatching(port, out)) {
|
||||||
{
|
|
||||||
pIOPt->setData(data);
|
pIOPt->setData(data);
|
||||||
it = buffer_cache.makeActive(m_EvList, it);
|
it = buffer_cache.makeActive(m_EvList, it);
|
||||||
// "it" has already been set to the next element (by calling
|
// "it" has already been set to the next element (by calling
|
||||||
|
|||||||
Reference in New Issue
Block a user