--- VHDL generated by LogSynth framework (c) Petr Fiser
Library IEEE;
use IEEE.std_logic_1164.all;

entity prio_encode is 
  Port (
    pi0,pi1,pi2,pi3,pi4,pi5: in std_logic;
    po0,po1,po2: inout std_logic
  );
end prio_encode;

architecture prio_encode_behav of prio_encode is
signal n9,n10,n11,n12,n13,n14,n15,n16,n17,n18,n19,n20,n21,n22,n23,n24,n25,n26,n27,n28,n29,n30,n31,n32,n33,n34,n35,n36,n37,n38,n39,n40,n41,n42,n43,n44,n45,n46,n47,n48,n49,n50,n51,n52,n53,n54,n55,n56,n57,n58,n59,n60,n61,n62,n63,n64,n65,n66,n67,n68,n69,n70,n71,n72,n74,n75,n76,n77,n78,n79,n80,n81,n82,n83,n84,n85,n86,n87,n88,n89,n90,n91,n92,n93,n94,n95,n96,n97,n98,n99,n100,n101,n102,n103,n104,n105,n106,n107,n108,n109,n110,n111,n112,n113,n114,n115,n116,n117,n118,n119,n120,n121,n122,n123,n124,n125,n126,n127,n128,n129,n130,n131,n132,n133,n134,n135,n137,n138,n139,n140,n141,n142,n143,n144,n145,n146,n147,n148,n149,n150,n151,n152,n153,n154,n155,n156,n157,n158,n159,n160,n161,n162,n163,n164,n165,n166,n167,n168,n169,n170,n171,n172,n173,n174,n175,n176,n177,n178,n179,n180,n181,n182,n183,n184,n185,n186,n187,n188,n189,n190,n191,n192,n193,n194,n195,n196,n197,n198: std_logic;
begin
    n9 <= '0';
    n10 <= '1';
    n11 <= ( n9 and not pi5 )
      or ( n10 and pi5 );
    n12 <= ( n9 and not pi5 )
      or ( n10 and pi5 );
    n13 <= ( n11 and not pi4 )
      or ( n12 and pi4 );
    n14 <= ( n10 and not pi5 )
      or ( n10 and pi5 );
    n15 <= ( n9 and not pi5 )
      or ( n10 and pi5 );
    n16 <= ( n14 and not pi4 )
      or ( n15 and pi4 );
    n17 <= ( n13 and not pi3 )
      or ( n16 and pi3 );
    n18 <= ( n9 and not pi5 )
      or ( n10 and pi5 );
    n19 <= ( n9 and not pi5 )
      or ( n10 and pi5 );
    n20 <= ( n18 and not pi4 )
      or ( n19 and pi4 );
    n21 <= ( n10 and not pi5 )
      or ( n10 and pi5 );
    n22 <= ( n9 and not pi5 )
      or ( n10 and pi5 );
    n23 <= ( n21 and not pi4 )
      or ( n22 and pi4 );
    n24 <= ( n20 and not pi3 )
      or ( n23 and pi3 );
    n25 <= ( n17 and not pi2 )
      or ( n24 and pi2 );
    n26 <= ( n10 and not pi5 )
      or ( n10 and pi5 );
    n27 <= ( n9 and not pi5 )
      or ( n10 and pi5 );
    n28 <= ( n26 and not pi4 )
      or ( n27 and pi4 );
    n29 <= ( n10 and not pi5 )
      or ( n10 and pi5 );
    n30 <= ( n9 and not pi5 )
      or ( n10 and pi5 );
    n31 <= ( n29 and not pi4 )
      or ( n30 and pi4 );
    n32 <= ( n28 and not pi3 )
      or ( n31 and pi3 );
    n33 <= ( n9 and not pi5 )
      or ( n10 and pi5 );
    n34 <= ( n9 and not pi5 )
      or ( n10 and pi5 );
    n35 <= ( n33 and not pi4 )
      or ( n34 and pi4 );
    n36 <= ( n10 and not pi5 )
      or ( n10 and pi5 );
    n37 <= ( n9 and not pi5 )
      or ( n10 and pi5 );
    n38 <= ( n36 and not pi4 )
      or ( n37 and pi4 );
    n39 <= ( n35 and not pi3 )
      or ( n38 and pi3 );
    n40 <= ( n32 and not pi2 )
      or ( n39 and pi2 );
    n41 <= ( n25 and not pi1 )
      or ( n40 and pi1 );
    n42 <= ( n9 and not pi5 )
      or ( n10 and pi5 );
    n43 <= ( n9 and not pi5 )
      or ( n10 and pi5 );
    n44 <= ( n42 and not pi4 )
      or ( n43 and pi4 );
    n45 <= ( n10 and not pi5 )
      or ( n10 and pi5 );
    n46 <= ( n9 and not pi5 )
      or ( n10 and pi5 );
    n47 <= ( n45 and not pi4 )
      or ( n46 and pi4 );
    n48 <= ( n44 and not pi3 )
      or ( n47 and pi3 );
    n49 <= ( n9 and not pi5 )
      or ( n10 and pi5 );
    n50 <= ( n9 and not pi5 )
      or ( n10 and pi5 );
    n51 <= ( n49 and not pi4 )
      or ( n50 and pi4 );
    n52 <= ( n10 and not pi5 )
      or ( n10 and pi5 );
    n53 <= ( n9 and not pi5 )
      or ( n10 and pi5 );
    n54 <= ( n52 and not pi4 )
      or ( n53 and pi4 );
    n55 <= ( n51 and not pi3 )
      or ( n54 and pi3 );
    n56 <= ( n48 and not pi2 )
      or ( n55 and pi2 );
    n57 <= ( n10 and not pi5 )
      or ( n10 and pi5 );
    n58 <= ( n9 and not pi5 )
      or ( n10 and pi5 );
    n59 <= ( n57 and not pi4 )
      or ( n58 and pi4 );
    n60 <= ( n10 and not pi5 )
      or ( n10 and pi5 );
    n61 <= ( n9 and not pi5 )
      or ( n10 and pi5 );
    n62 <= ( n60 and not pi4 )
      or ( n61 and pi4 );
    n63 <= ( n59 and not pi3 )
      or ( n62 and pi3 );
    n64 <= ( n9 and not pi5 )
      or ( n10 and pi5 );
    n65 <= ( n9 and not pi5 )
      or ( n10 and pi5 );
    n66 <= ( n64 and not pi4 )
      or ( n65 and pi4 );
    n67 <= ( n10 and not pi5 )
      or ( n10 and pi5 );
    n68 <= ( n9 and not pi5 )
      or ( n10 and pi5 );
    n69 <= ( n67 and not pi4 )
      or ( n68 and pi4 );
    n70 <= ( n66 and not pi3 )
      or ( n69 and pi3 );
    n71 <= ( n63 and not pi2 )
      or ( n70 and pi2 );
    n72 <= ( n56 and not pi1 )
      or ( n71 and pi1 );
    po2 <= ( n41 and not pi0 )
      or ( n72 and pi0 );
    n74 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n75 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n76 <= ( n74 and not pi4 )
      or ( n75 and pi4 );
    n77 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n78 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n79 <= ( n77 and not pi4 )
      or ( n78 and pi4 );
    n80 <= ( n76 and not pi3 )
      or ( n79 and pi3 );
    n81 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n82 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n83 <= ( n81 and not pi4 )
      or ( n82 and pi4 );
    n84 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n85 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n86 <= ( n84 and not pi4 )
      or ( n85 and pi4 );
    n87 <= ( n83 and not pi3 )
      or ( n86 and pi3 );
    n88 <= ( n80 and not pi2 )
      or ( n87 and pi2 );
    n89 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n90 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n91 <= ( n89 and not pi4 )
      or ( n90 and pi4 );
    n92 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n93 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n94 <= ( n92 and not pi4 )
      or ( n93 and pi4 );
    n95 <= ( n91 and not pi3 )
      or ( n94 and pi3 );
    n96 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n97 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n98 <= ( n96 and not pi4 )
      or ( n97 and pi4 );
    n99 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n100 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n101 <= ( n99 and not pi4 )
      or ( n100 and pi4 );
    n102 <= ( n98 and not pi3 )
      or ( n101 and pi3 );
    n103 <= ( n95 and not pi2 )
      or ( n102 and pi2 );
    n104 <= ( n88 and not pi1 )
      or ( n103 and pi1 );
    n105 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n106 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n107 <= ( n105 and not pi4 )
      or ( n106 and pi4 );
    n108 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n109 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n110 <= ( n108 and not pi4 )
      or ( n109 and pi4 );
    n111 <= ( n107 and not pi3 )
      or ( n110 and pi3 );
    n112 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n113 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n114 <= ( n112 and not pi4 )
      or ( n113 and pi4 );
    n115 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n116 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n117 <= ( n115 and not pi4 )
      or ( n116 and pi4 );
    n118 <= ( n114 and not pi3 )
      or ( n117 and pi3 );
    n119 <= ( n111 and not pi2 )
      or ( n118 and pi2 );
    n120 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n121 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n122 <= ( n120 and not pi4 )
      or ( n121 and pi4 );
    n123 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n124 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n125 <= ( n123 and not pi4 )
      or ( n124 and pi4 );
    n126 <= ( n122 and not pi3 )
      or ( n125 and pi3 );
    n127 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n128 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n129 <= ( n127 and not pi4 )
      or ( n128 and pi4 );
    n130 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n131 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n132 <= ( n130 and not pi4 )
      or ( n131 and pi4 );
    n133 <= ( n129 and not pi3 )
      or ( n132 and pi3 );
    n134 <= ( n126 and not pi2 )
      or ( n133 and pi2 );
    n135 <= ( n119 and not pi1 )
      or ( n134 and pi1 );
    po1 <= ( n104 and not pi0 )
      or ( n135 and pi0 );
    n137 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n138 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n139 <= ( n137 and not pi4 )
      or ( n138 and pi4 );
    n140 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n141 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n142 <= ( n140 and not pi4 )
      or ( n141 and pi4 );
    n143 <= ( n139 and not pi3 )
      or ( n142 and pi3 );
    n144 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n145 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n146 <= ( n144 and not pi4 )
      or ( n145 and pi4 );
    n147 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n148 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n149 <= ( n147 and not pi4 )
      or ( n148 and pi4 );
    n150 <= ( n146 and not pi3 )
      or ( n149 and pi3 );
    n151 <= ( n143 and not pi2 )
      or ( n150 and pi2 );
    n152 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n153 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n154 <= ( n152 and not pi4 )
      or ( n153 and pi4 );
    n155 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n156 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n157 <= ( n155 and not pi4 )
      or ( n156 and pi4 );
    n158 <= ( n154 and not pi3 )
      or ( n157 and pi3 );
    n159 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n160 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n161 <= ( n159 and not pi4 )
      or ( n160 and pi4 );
    n162 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n163 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n164 <= ( n162 and not pi4 )
      or ( n163 and pi4 );
    n165 <= ( n161 and not pi3 )
      or ( n164 and pi3 );
    n166 <= ( n158 and not pi2 )
      or ( n165 and pi2 );
    n167 <= ( n151 and not pi1 )
      or ( n166 and pi1 );
    n168 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n169 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n170 <= ( n168 and not pi4 )
      or ( n169 and pi4 );
    n171 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n172 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n173 <= ( n171 and not pi4 )
      or ( n172 and pi4 );
    n174 <= ( n170 and not pi3 )
      or ( n173 and pi3 );
    n175 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n176 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n177 <= ( n175 and not pi4 )
      or ( n176 and pi4 );
    n178 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n179 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n180 <= ( n178 and not pi4 )
      or ( n179 and pi4 );
    n181 <= ( n177 and not pi3 )
      or ( n180 and pi3 );
    n182 <= ( n174 and not pi2 )
      or ( n181 and pi2 );
    n183 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n184 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n185 <= ( n183 and not pi4 )
      or ( n184 and pi4 );
    n186 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n187 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n188 <= ( n186 and not pi4 )
      or ( n187 and pi4 );
    n189 <= ( n185 and not pi3 )
      or ( n188 and pi3 );
    n190 <= ( n10 and not pi5 )
      or ( n9 and pi5 );
    n191 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n192 <= ( n190 and not pi4 )
      or ( n191 and pi4 );
    n193 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n194 <= ( n9 and not pi5 )
      or ( n9 and pi5 );
    n195 <= ( n193 and not pi4 )
      or ( n194 and pi4 );
    n196 <= ( n192 and not pi3 )
      or ( n195 and pi3 );
    n197 <= ( n189 and not pi2 )
      or ( n196 and pi2 );
    n198 <= ( n182 and not pi1 )
      or ( n197 and pi1 );
    po0 <= ( n167 and not pi0 )
      or ( n198 and pi0 );
end prio_encode_behav;
