/usr/share/tkgate/primitives/demux.v is in tkgate-data 2.0~b10-4.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 | module demux #(.Dez(1), .Dfz(1), .Dsz(1)) (F, S, E, $${NUMOUT:, :Z%});
input ${F_RANGE} F;
input ${S_RANGE} S;
input E;
output ${F_RANGE} $${NUMOUT:, :Z%};
wire ${F_RANGE} X;
specify
$${NUMOUT:\n: (E *> Z%) = Dez; }
$${NUMOUT:\n: (F *> Z%) = Dfz; }
$${NUMOUT:\n: (S *> Z%) = Dsz; }
endspecify
assign X = E ? F : ${F_BITS}'h0;
$${NUMOUT:\n: assign Z% = (S == ${S_BITS}'d%) ? X : ${F_BITS}'h0;}
endmodule // demux
|