summaryrefslogtreecommitdiff
path: root/Source/Core
diff options
context:
space:
mode:
authorRodolfo Osvaldo Bogado <rodolfoosvaldobogado@gmail.com>2010-12-04 03:44:56 +0000
committerRodolfo Osvaldo Bogado <rodolfoosvaldobogado@gmail.com>2010-12-04 03:44:56 +0000
commit97e3a3ea6fda441b2b342f795aa0afd9de2d8e14 (patch)
treed5793849b6c31bd6b73071249aeb1d31fc7a584c /Source/Core
parentf5a28aecb7edf3182e02c51f75c1c3a20d55e774 (diff)
remove fifowait flag, is not needed now as we execute all events that need to be executed even if the cpu is waiting for the fifo.
this way fifo will not avid other thread events to bi executed. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6514 8ced0084-cf51-0410-be5f-012b33b47a6e
Diffstat (limited to 'Source/Core')
-rw-r--r--Source/Core/Core/Src/CoreTiming.cpp17
-rw-r--r--Source/Core/Core/Src/CoreTiming.h2
-rw-r--r--Source/Core/VideoCommon/Src/CommandProcessor.cpp2
-rw-r--r--Source/Core/VideoCommon/Src/PixelEngine.cpp4
4 files changed, 10 insertions, 15 deletions
diff --git a/Source/Core/Core/Src/CoreTiming.cpp b/Source/Core/Core/Src/CoreTiming.cpp
index 35311f8154..3207112cbf 100644
--- a/Source/Core/Core/Src/CoreTiming.cpp
+++ b/Source/Core/Core/Src/CoreTiming.cpp
@@ -42,7 +42,6 @@ struct BaseEvent
s64 time;
u64 userdata;
int type;
- bool fifoWait;
// Event *next;
};
@@ -177,8 +176,7 @@ void DoState(PointerWrap &p)
prev->next = ev;
p.Do(ev->time);
p.Do(ev->type);
- p.Do(ev->userdata);
- p.Do(ev->fifoWait);
+ p.Do(ev->userdata);
ev->next = 0;
prev = ev;
ev = ev->next;
@@ -195,8 +193,7 @@ void DoState(PointerWrap &p)
p.Do(more_events);
p.Do(ev->time);
p.Do(ev->type);
- p.Do(ev->userdata);
- p.Do(ev->fifoWait);
+ p.Do(ev->userdata);
ev = ev->next;
}
more_events = 0;
@@ -219,7 +216,7 @@ u64 GetIdleTicks()
// This is to be called when outside threads, such as the graphics thread, wants to
// schedule things to be executed on the main thread.
-void ScheduleEvent_Threadsafe(int cyclesIntoFuture, int event_type, u64 userdata, bool fifoWait)
+void ScheduleEvent_Threadsafe(int cyclesIntoFuture, int event_type, u64 userdata)
{
externalEventSection.Enter();
Event *ne = GetNewTsEvent();
@@ -227,7 +224,6 @@ void ScheduleEvent_Threadsafe(int cyclesIntoFuture, int event_type, u64 userdata
ne->type = event_type;
ne->next = 0;
ne->userdata = userdata;
- ne->fifoWait = fifoWait;
if(!tsFirst)
tsFirst = ne;
if(tsLast)
@@ -247,7 +243,7 @@ void ScheduleEvent_Threadsafe_Immediate(int event_type, u64 userdata)
externalEventSection.Leave();
}
else
- ScheduleEvent_Threadsafe(0, event_type, userdata, false);
+ ScheduleEvent_Threadsafe(0, event_type, userdata);
}
void ClearPendingEvents()
@@ -287,7 +283,6 @@ void ScheduleEvent(int cyclesIntoFuture, int event_type, u64 userdata)
ne->userdata = userdata;
ne->type = event_type;
ne->time = globalTimer + cyclesIntoFuture;
- ne->fifoWait = false;
AddEventToQueue(ne);
}
@@ -403,7 +398,7 @@ void ProcessFifoWaitEvents()
if (!first)
return;
- if (first->time <= globalTimer && first->fifoWait)
+ if (first->time <= globalTimer)
{
Event *next = first->next;
event_types[first->type].callback(first->userdata, (int)(globalTimer - first->time));
@@ -418,7 +413,7 @@ void ProcessFifoWaitEvents()
Event *ptr = prev->next;
while (ptr)
{
- if (ptr->time <= globalTimer && ptr->fifoWait)
+ if (ptr->time <= globalTimer)
{
prev->next = ptr->next;
event_types[ptr->type].callback(ptr->userdata, (int)(globalTimer - ptr->time));
diff --git a/Source/Core/Core/Src/CoreTiming.h b/Source/Core/Core/Src/CoreTiming.h
index 7514727fc8..818c5a9e5f 100644
--- a/Source/Core/Core/Src/CoreTiming.h
+++ b/Source/Core/Core/Src/CoreTiming.h
@@ -57,7 +57,7 @@ void UnregisterAllEvents();
// userdata MAY NOT CONTAIN POINTERS. userdata might get written and reloaded from disk,
// when we implement state saves.
void ScheduleEvent(int cyclesIntoFuture, int event_type, u64 userdata=0);
-void ScheduleEvent_Threadsafe(int cyclesIntoFuture, int event_type, u64 userdata=0, bool fifoWait=true);
+void ScheduleEvent_Threadsafe(int cyclesIntoFuture, int event_type, u64 userdata=0);
void ScheduleEvent_Threadsafe_Immediate(int event_type, u64 userdata=0);
// We only permit one event of each type in the queue at a time.
diff --git a/Source/Core/VideoCommon/Src/CommandProcessor.cpp b/Source/Core/VideoCommon/Src/CommandProcessor.cpp
index 0dc3fc3b0b..8f9b621284 100644
--- a/Source/Core/VideoCommon/Src/CommandProcessor.cpp
+++ b/Source/Core/VideoCommon/Src/CommandProcessor.cpp
@@ -717,7 +717,7 @@ void UpdateInterrupts()
void UpdateInterruptsFromVideoPlugin()
{
- g_VideoInitialize.pScheduleEvent_Threadsafe(0, et_UpdateInterrupts, 0, true);
+ g_VideoInitialize.pScheduleEvent_Threadsafe(0, et_UpdateInterrupts, 0);
}
void SetFifoIdleFromVideoPlugin()
diff --git a/Source/Core/VideoCommon/Src/PixelEngine.cpp b/Source/Core/VideoCommon/Src/PixelEngine.cpp
index 580571b328..4913e21cfc 100644
--- a/Source/Core/VideoCommon/Src/PixelEngine.cpp
+++ b/Source/Core/VideoCommon/Src/PixelEngine.cpp
@@ -343,7 +343,7 @@ void SetToken(const u16 _token, const int _bSetTokenAcknowledge)
// This seems smelly...
CommandProcessor::IncrementGPWDToken(); // for DC watchdog hack since PEToken seems to be a frame-finish too
g_VideoInitialize.pScheduleEvent_Threadsafe(
- 0, et_SetTokenOnMainThread, _token | (_bSetTokenAcknowledge << 16), true);
+ 0, et_SetTokenOnMainThread, _token | (_bSetTokenAcknowledge << 16));
}
else // set token value
{
@@ -362,7 +362,7 @@ void SetFinish()
{
CommandProcessor::IncrementGPWDToken(); // for DC watchdog hack
g_VideoInitialize.pScheduleEvent_Threadsafe(
- 0, et_SetFinishOnMainThread, 0, true);
+ 0, et_SetFinishOnMainThread, 0);
INFO_LOG(PIXELENGINE, "VIDEO Set Finish");
}