-- FIXME: run at 512MHz not core freq ctrl_tmp.tb <= std_ulogic_vector(unsigned(ctrl.tb) + 1); ctrl_tmp.dec <= std_ulogic_vector(unsigned(ctrl.dec) - 1);
interrupt when dec reaches -1 if ctrl.msr(MSR_EE) = '1' then if ctrl.dec(63) = '1' then v.f.redirect_nia := std_logic_vector(to_unsigned(16#900#, 64)); report "IRQ valid: DEC"; irq_valid := '1';
commit a645950fa2d3c64b63b187485034dbafd115a16d (HEAD -> master) Author: Luke Kenneth Casson Leighton <lkcl@lkcl.net> Date: Sun Sep 6 12:13:16 2020 +0100 add DEC SPR to CoreState and PowerDecoder, activate 0x900 interrupt commit ee491651861ed89c44ced180189656b8a80fbee0 (HEAD -> master) Author: Luke Kenneth Casson Leighton <lkcl@lkcl.net> Date: Sun Sep 6 12:50:47 2020 +0100 move DEC and TB from StateRegs to FastRegs for several reasons first: SPR pipeline already has fast1 read/write second: a new DecodeStateIn/Out object would be needed instead just add FastRegs.DEC/TB to DecodeA/Out third: there is probably a third somewhere commit 0df522b99d98618d9ff5f95f622dbd79267ae728 (HEAD -> master) Author: Luke Kenneth Casson Leighton <lkcl@lkcl.net> Date: Sun Sep 6 12:56:48 2020 +0100 add a DEC/TB FSM to TestIssuer this operates on alternative cycles, because it reads/writes from the Fast Regfile directly
litex sim running microwatt tests/decrementer/decrementer.bin passes [clocker] sys_clk: freq_hz=1000000, phase_deg=0 Test 01:PASS Test 02:PASS Test 03:PASS