From: Luke Kenneth Casson Leighton Date: Tue, 19 May 2020 21:54:44 +0000 (+0100) Subject: use field AA directly X-Git-Tag: div_pipeline~1057 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=20e3e5b60cf2877a25920140304ae3674b7f8888;p=soc.git use field AA directly --- diff --git a/src/soc/fu/branch/main_stage.py b/src/soc/fu/branch/main_stage.py index 6efc5745..df1b34cd 100644 --- a/src/soc/fu/branch/main_stage.py +++ b/src/soc/fu/branch/main_stage.py @@ -50,17 +50,16 @@ class BranchMainStage(PipeModBase): lk = op.lk # see PowerDecode2 as to why this is done nia_o, lr_o = self.o.nia, self.o.lr - # obtain relevant instruction fields + # obtain relevant instruction field AA, "Absolute Address" mode i_fields = self.fields.FormI - aa = Signal(i_fields.AA[0:-1].shape()) - comb += aa.eq(i_fields.AA[0:-1]) + AA = i_fields.AA[0:-1] br_imm_addr = Signal(64, reset_less=True) br_addr = Signal(64, reset_less=True) br_taken = Signal(reset_less=True) # Handle absolute or relative branches - with m.If(aa): + with m.If(AA): comb += br_addr.eq(br_imm_addr) with m.Else(): comb += br_addr.eq(br_imm_addr + self.i.cia)