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

Subversion Repositories qaz_libs

[/] [qaz_libs/] [trunk/] [basal/] [src/] [misc/] [one_hot_encoder.sv] - Diff between revs 34 and 38

Show entire file | Details | Blame | View Log

Rev 34 Rev 38
Line 44... Line 44...
 
 
  // --------------------------------------------------------------------
  // --------------------------------------------------------------------
  //
  //
  generate
  generate
    if(A == 1)
    if(A == 1)
    begin: mux_gen
    begin: one_hot_encoder_gen
        assign encoded[1:0] = select[0] ? 2'b10 :2'b01;
        assign encoded[1:0] = select[0] ? 2'b10 :2'b01;
    end
    end
    else
    else
    begin: recurse_mux_gen
    begin: recurse_one_hot_encoder_gen
      wire [W-1:0] encoder_out;
      wire [W-1:0] encoder_out;
 
 
      one_hot_encoder #(.A(A - 1))
      one_hot_encoder #(.A(A - 1))
        one_hot_encoder_i
        one_hot_encoder_i
        (
        (

powered by: WebSVN 2.1.0

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