resolving old and new behaviour for lookup of SPRs
authorLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Wed, 8 Jul 2020 19:24:45 +0000 (20:24 +0100)
committerLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Wed, 8 Jul 2020 19:24:45 +0000 (20:24 +0100)
src/soc/simple/test/test_core.py

index 04108cdc4a1e7cd1bd7418cda04c0c65d63070a1..7cec69cedd91f0c0c56a2733da9dcbe19532313c 100644 (file)
@@ -85,7 +85,7 @@ def setup_regs(core, test):
     sregs = core.regs.spr
     for sprname, val in test.sprs.items():
         if isinstance(sprname, int):
-            sprname = spr_dict[sprname].name
+            sprname = spr_dict[sprname].SPR
         if sprname == 'XER':
             continue
         fast = spr_to_fast_reg(sprname)