Files
cheri-cap-lib/module_wrap64_getTop.v
2026-02-17 13:49:05 +00:00

75 lines
2.1 KiB
Verilog

//
// Generated by Bluespec Compiler, version 2025.01.1 (build 65e3a87)
//
// On Tue Feb 17 13:06:25 GMT 2026
//
//
// Ports:
// Name I/O size props
// wrap64_getTop O 33
// wrap64_getTop_cap I 115
//
// Combinational paths from inputs to outputs:
// wrap64_getTop_cap -> wrap64_getTop
//
//
`ifdef BSV_ASSIGNMENT_DELAY
`else
`define BSV_ASSIGNMENT_DELAY
`endif
`ifdef BSV_POSITIVE_RESET
`define BSV_RESET_VALUE 1'b1
`define BSV_RESET_EDGE posedge
`else
`define BSV_RESET_VALUE 1'b0
`define BSV_RESET_EDGE negedge
`endif
module module_wrap64_getTop(wrap64_getTop_cap,
wrap64_getTop);
// value method wrap64_getTop
input [114 : 0] wrap64_getTop_cap;
output [32 : 0] wrap64_getTop;
// signals for module outputs
wire [32 : 0] wrap64_getTop;
// remaining internal signals
wire [32 : 0] addTop__h64, result__h512, ret__h66;
wire [24 : 0] mask__h65;
wire [23 : 0] wrap64_getTop_cap_BITS_113_TO_90_PLUS_SEXT_wra_ETC__q2;
wire [9 : 0] x__h178;
wire [1 : 0] wrap64_getTop_cap_BITS_1_TO_0__q1;
// value method wrap64_getTop
assign wrap64_getTop =
(wrap64_getTop_cap[31:26] < 6'd25 &&
ret__h66[32:31] -
{ 1'b0,
(wrap64_getTop_cap[31:26] == 6'd24) ?
wrap64_getTop_cap[17] :
wrap64_getTop_cap_BITS_113_TO_90_PLUS_SEXT_wra_ETC__q2[23] } >
2'd1) ?
result__h512 :
ret__h66 ;
// remaining internal signals
assign addTop__h64 =
{ {23{x__h178[9]}}, x__h178 } << wrap64_getTop_cap[31:26] ;
assign mask__h65 = 25'd33554431 << wrap64_getTop_cap[31:26] ;
assign result__h512 = { ~ret__h66[32], ret__h66[31:0] } ;
assign ret__h66 =
{ { 1'b0, wrap64_getTop_cap[113:90] } & mask__h65, 8'd0 } +
addTop__h64 ;
assign wrap64_getTop_cap_BITS_113_TO_90_PLUS_SEXT_wra_ETC__q2 =
wrap64_getTop_cap[113:90] +
({ {22{wrap64_getTop_cap_BITS_1_TO_0__q1[1]}},
wrap64_getTop_cap_BITS_1_TO_0__q1 } <<
wrap64_getTop_cap[31:26]) ;
assign wrap64_getTop_cap_BITS_1_TO_0__q1 = wrap64_getTop_cap[1:0] ;
assign x__h178 = { wrap64_getTop_cap[3:2], wrap64_getTop_cap[25:18] } ;
endmodule // module_wrap64_getTop