From: lkcl Date: Sat, 2 Apr 2022 11:59:33 +0000 (+0100) Subject: (no commit message) X-Git-Tag: opf_rfc_ls005_v1~2931 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=9da904332fea61eb1fc629f49b5f7a31a6ceb333;p=libreriscv.git --- diff --git a/openpower/sv/branches.mdwn b/openpower/sv/branches.mdwn index b5411a95b..aa8d79343 100644 --- a/openpower/sv/branches.mdwn +++ b/openpower/sv/branches.mdwn @@ -514,7 +514,7 @@ for srcstep in range(VL): else if not SVRMmode.sz: # inverted CTR test skip mode if ¬BO[2] & CTRtest & ¬CTI then - CTR = CTR - 1 + CTR = CTR - 1 continue else testbit = SVRMmode.SNZ @@ -541,6 +541,14 @@ for srcstep in range(VL): break if SVCRf.scalar: break +# loop finally done, now test if branch (and update LR) +lr_ok <- SVRMmode.LRu +if cond_ok then + if AA then NIA <-iea EXTS(BD || 0b00) + else NIA <-iea CIA + EXTS(BD || 0b00) + lr_ok <- 0b1 +if LK & lr_ok then LR <-iea CIA + 4 + ``` Pseudocode for Vertical-First Mode: