From bc3b330d8862d3371d48d653dd87d3c909dd45d5 Mon Sep 17 00:00:00 2001 From: hneemann Date: Thu, 7 Jan 2021 20:05:37 +0100 Subject: [PATCH] minor layout changes --- .../generic/barrelShifter/barrelShifter2.dig | 20 +++++++++---------- 1 file changed, 9 insertions(+), 11 deletions(-) diff --git a/src/main/dig/generic/barrelShifter/barrelShifter2.dig b/src/main/dig/generic/barrelShifter/barrelShifter2.dig index 56f4d3c1d..783b8e6fb 100644 --- a/src/main/dig/generic/barrelShifter/barrelShifter2.dig +++ b/src/main/dig/generic/barrelShifter/barrelShifter2.dig @@ -35,34 +35,32 @@ direction:="left"; - + GenericCode generic - sh:=bitsNeededFor(args.dataBits)-1; - -circuit:=""; + shiftCircuit:=""; if (args.direction="right") { - circuit="shift-fixed-right-inc.dig"; + shiftCircuit="shift-fixed-right-inc.dig"; } else { if (args.direction="arith") { - circuit="shift-fixed-arith-right-inc.dig"; + shiftCircuit="shift-fixed-arith-right-inc.dig"; } else { if (args.direction="left") { - circuit="shift-fixed-left-inc.dig"; + shiftCircuit="shift-fixed-left-inc.dig"; } else { panic("only \"left\", \"right\" or \"arith\" is allowed as direction, not \""+args.direction+"\"!"); } } } - +sh:=bitsNeededFor(args.dataBits)-1; for (i:=0;i<sh;i++) { x:= i*5+2; - s:=addComponent(circuit,x,0); + s:=addComponent(shiftCircuit,x,0); s.shift:=1<<i; addWire(x+3,1,x+5,0); @@ -77,7 +75,7 @@ o.Bits=args.dataBits; o.Label="Out"; - + In @@ -122,7 +120,7 @@ this.'Output Splitting'="1*"+sh; {{de Ein BarrelShifter implementiert durch Bauteilerzeugung.}} - +