}
if (spu.rvb->StartAddr) {
- if (do_rvb) {
- if (unlikely(spu.rvb->dirty))
- REVERBPrep();
-
+ if (do_rvb)
REVERBDo(spu.SSumLR, RVB, ns_to, spu.rvb->CurrAddr);
- }
spu.rvb->CurrAddr += ns_to / 2;
while (spu.rvb->CurrAddr >= 0x40000)
unsigned int i_ready;
unsigned int i_reaped;
unsigned int last_boot_cnt; // dsp
+ unsigned int ram_dirty;
};
// aligning for C64X_DSP
unsigned int _pad0[128/4];
work->rvb_addr = 0;
if (spu.rvb->StartAddr) {
- if (spu_config.iUseReverb) {
- if (unlikely(spu.rvb->dirty))
- REVERBPrep();
+ if (spu_config.iUseReverb)
work->rvb_addr = spu.rvb->CurrAddr;
- }
spu.rvb->CurrAddr += ns_to / 2;
while (spu.rvb->CurrAddr >= 0x40000)
{
unsigned int mask;
unsigned int decode_dirty_ch = 0;
+ const SPUCHAN *s_chan;
int *SB, sinc, spos, sbpos;
int d, ch, ns_to;
- SPUCHAN *s_chan;
ns_to = work->ns_to;
struct work_item *work;
int done, used_space;
+ // rvb offsets will change, thread may be using them
+ force |= spu.rvb->dirty && spu.rvb->StartAddr;
+
done = thread_get_i_done() - worker->i_reaped;
used_space = worker->i_ready - worker->i_reaped;
+
//printf("done: %d use: %d dsp: %u/%u\n", done, used_space,
// worker->boot_cnt, worker->i_done);
}
}
+ if (unlikely(spu.rvb->dirty))
+ REVERBPrep();
+
if (do_direct || worker == NULL || !spu_config.iUseThread) {
do_channels(ns_to);
do_samples_finish(spu.SSumLR, ns_to, silentch, spu.decode_pos);
void CALLBACK SPUasync(unsigned int cycle, unsigned int flags)
{
- do_samples(cycle, 0);
+ do_samples(cycle, spu_config.iUseFixedUpdates);
if (spu.spuCtrl & CTRL_IRQ)
schedule_next_irq();