/******************************************
* (C)Copyright by N.T.T 1993(unpublished) *
* All rights are reserved.                *
******************************************/
%i "../int_h/cla4.h"
module cla16 {
    input       cin ;
    input       in1<16> ;
    input       in2<16> ;
    output      out<16> ;
    output      gout ;
    output      pout ;
    sel_v       cry<4> ;
    cla4        cla43 ;
    cla4        cla42 ;
    cla4        cla41 ;
    cla4        cla40 ;
    instrin     do ;
    instruct do par {
        cry = ((cin&cla40.pout&cla41.pout&cla42.pout)
              |    (cla40.gout&cla41.pout&cla42.pout)
              |               (cla41.gout&cla42.pout)
              |                           cla42.gout)
           || ((cin&cla40.pout&cla41.pout)
              |    (cla40.gout&cla41.pout)
              |                cla41.gout)
           || ((cin&cla40.pout)
              |     cla40.gout)
           || cin ;
        out = cla43.do(cry<3>,in1<15:12>,in2<15:12>).out
           || cla42.do(cry<2>,in1 <11:8>,in2 <11:8>).out
           || cla41.do(cry<1>,in1  <7:4>,in2  <7:4>).out
           || cla40.do(cry<0>,in1  <3:0>,in2  <3:0>).out ;
        gout =  (cla40.gout&cla41.pout&cla42.pout&cla43.pout)
               |           (cla41.gout&cla42.pout&cla43.pout)
               |                      (cla42.gout&cla43.pout)
               |                                  cla43.gout ;
        pout = cla40.pout&cla41.pout&cla42.pout&cla43.pout ;
    }
}
