OpenCores
URL https://opencores.org/ocsvn/idea/idea/trunk

Subversion Repositories idea

[/] [idea/] [trunk/] [behavioral/] [idea_machine/] [comp2.vbe] - Blame information for rev 9

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 6 marta
--   File Name    : comp2.vbe                                            --
2
--   Description  : The special comparator resulting                     --
3
--                  an integer 2^16+1 or an integer 0 on the 16-bit data --
4
--   Purpose      : To be used by ASIMUT and SCMAP                       --
5
--   Date         : Aug 22, 2001                                         --
6
--   Version      : 1.1                                                  --
7
--   Author       : Martadinata A.                                       --
8
--   Address      : VLSI RG, Dept. of Electrical Engineering             --
9
--                  ITB, Bandung, Indonesia                              --
10
--   E-mail       : marta@vlsi.itb.ac.id                                 --
11
 
12
entity com2 is
13
port(
14
  p       : in    bit_vector(15 downto 0);
15
  q       : in    bit_vector(15 downto 0);
16
  kout2   : out   bit_vector(15 downto 0);
17
  vdd     : in    bit;
18
  vss     : in    bit
19
  );
20
end com2;
21
 
22
architecture vbe of com2 is
23
signal less, equal  : bit;
24
begin
25
  assert ((vdd and not (vss)) = '1')
26
    report "power supply is missing on com2"
27
    severity warning;
28
 
29
less <= (
30
((not p(0)) and q(0)) and (not(p(1) xor q(1))) and  (not(p(2) xor q(2))) and
31
(not(p(3) xor q(3))) and  (not(p(4) xor q(4))) and  (not(p(5) xor q(5))) and
32
(not(p(6) xor q(6))) and  (not(p(7) xor q(7))) and  (not(p(8) xor q(8))) and
33
(not(p(9) xor q(9))) and  (not(p(10) xor q(10))) and (not(p(11) xor q(11)))
34
and  (not(p(12) xor q(12))) and  (not(p(13) xor q(13))) and  (not(p(14) xor
35
q(14))) and  (not(p(15) xor q(15)))
36
)or(
37
((not p(1)) and q(1)) and  (not(p(2) xor q(2))) and
38
(not(p(3) xor q(3))) and  (not(p(4) xor q(4))) and  (not(p(5) xor q(5))) and
39
(not(p(6) xor q(6))) and  (not(p(7) xor q(7))) and  (not(p(8) xor q(8))) and
40
(not(p(9) xor q(9))) and  (not(p(10) xor q(10))) and (not(p(11) xor q(11)))
41
and  (not(p(12) xor q(12))) and  (not(p(13) xor q(13))) and  (not(p(14) xor
42
q(14))) and  (not(p(15) xor q(15)))
43
)or(
44
((not p(2)) and q(2)) and (not(p(3) xor q(3))) and  (not(p(4) xor q(4))) and
45
(not(p(5) xor q(5))) and  (not(p(6) xor q(6))) and  (not(p(7) xor q(7))) and
46
(not(p(8) xor q(8))) and  (not(p(9) xor q(9))) and  (not(p(10) xor q(10))) and
47
(not(p(11) xor q(11))) and  (not(p(12) xor q(12))) and  (not(p(13) xor q(13)))
48
and  (not(p(14) xor q(14))) and  (not(p(15) xor q(15)))
49
)or(
50
((not p(3)) and q(3)) and  (not(p(4) xor q(4))) and
51
(not(p(5) xor q(5))) and  (not(p(6) xor q(6))) and  (not(p(7) xor q(7))) and
52
(not(p(8) xor q(8))) and  (not(p(9) xor q(9))) and  (not(p(10) xor q(10))) and
53
(not(p(11) xor q(11))) and  (not(p(12) xor q(12))) and  (not(p(13) xor q(13)))
54
and  (not(p(14) xor q(14))) and  (not(p(15) xor q(15)))
55
)or(
56
((not p(4)) and q(4)) and (not(p(5) xor q(5))) and  (not(p(6) xor q(6))) and
57
(not(p(7) xor q(7))) and (not(p(8) xor q(8))) and  (not(p(9) xor q(9))) and
58
(not(p(10) xor q(10))) and (not(p(11) xor q(11))) and  (not(p(12) xor q(12)))
59
and  (not(p(13) xor q(13))) and  (not(p(14) xor q(14))) and  (not(p(15) xor
60
q(15)))
61
)or(
62
((not p(5)) and q(5)) and  (not(p(6) xor q(6))) and
63
(not(p(7) xor q(7))) and (not(p(8) xor q(8))) and  (not(p(9) xor q(9))) and
64
(not(p(10) xor q(10))) and (not(p(11) xor q(11))) and  (not(p(12) xor q(12)))
65
and  (not(p(13) xor q(13))) and  (not(p(14) xor q(14))) and  (not(p(15) xor
66
q(15)))
67
)or(
68
((not p(6)) and q(6)) and  (not(p(7) xor q(7))) and (not(p(8) xor q(8))) and
69
(not(p(9) xor q(9))) and  (not(p(10) xor q(10))) and (not(p(11) xor q(11))) and
70
(not(p(12) xor q(12))) and  (not(p(13) xor q(13))) and  (not(p(14) xor
71
q(14))) and  (not(p(15) xor q(15)))
72
)or(
73
((not p(7)) and q(7)) and (not(p(8) xor q(8))) and
74
(not(p(9) xor q(9))) and  (not(p(10) xor q(10))) and (not(p(11) xor q(11))) and
75
(not(p(12) xor q(12))) and  (not(p(13) xor q(13))) and  (not(p(14) xor
76
q(14))) and  (not(p(15) xor q(15)))
77
)or(
78
((not p(8)) and q(8)) and  (not(p(9) xor q(9))) and  (not(p(10) xor q(10))) and
79
(not(p(11) xor q(11))) and  (not(p(12) xor q(12))) and  (not(p(13) xor q(13))) and
80
(not(p(14) xor q(14))) and  (not(p(15) xor q(15)))
81
)or(
82
((not p(9)) and q(9)) and  (not(p(10) xor q(10))) and
83
(not(p(11) xor q(11))) and  (not(p(12) xor q(12))) and  (not(p(13) xor q(13))) and
84
(not(p(14) xor q(14))) and  (not(p(15) xor q(15)))
85
)or(
86
((not p(10)) and q(10)) and (not(p(11) xor q(11))) and  (not(p(12) xor q(12))) and
87
(not(p(13) xor q(13))) and  (not(p(14) xor q(14))) and  (not(p(15) xor q(15)))
88
)or(
89
((not p(11)) and q(11)) and  (not(p(12) xor q(12))) and
90
(not(p(13) xor q(13))) and  (not(p(14) xor q(14))) and  (not(p(15) xor q(15)))
91
)or(
92
((not p(12)) and q(12)) and (not(p(13) xor q(13))) and  (not(p(14) xor q(14))) and
93
(not(p(15) xor q(15)))
94
)or(
95
((not p(13)) and q(13)) and  (not(p(14) xor q(14))) and  (not(p(15) xor q(15)))
96
)or(
97
((not p(14)) and q(14)) and  (not(p(15) xor q(15)))
98
)or
99
((not p(15)) and q(15));
100
 
101
equal <=
102
(not(p(0) xor q(0))) and (not(p(1) xor q(1))) and  (not(p(2) xor q(2))) and
103
(not(p(3) xor q(3))) and  (not(p(4) xor q(4))) and  (not(p(5) xor q(5))) and
104
(not(p(6) xor q(6))) and  (not(p(7) xor q(7))) and  (not(p(8) xor q(8))) and
105
(not(p(9) xor q(9))) and  (not(p(10) xor q(10))) and (not(p(11) xor q(11)))
106
and  (not(p(12) xor q(12))) and  (not(p(13) xor q(13))) and  (not(p(14) xor
107
q(14))) and  (not(p(15) xor q(15)));
108
 
109
 
110
kout2 <= "0000000000000001" when ((less = '1') or (equal ='1'))
111
          else "0000000000000000";
112
end;

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.