//A reset signal synchronizer //Async entry, synchronous exit! module rsync (/*AUTOARG*/ // Outputs nrst_out, // Inputs clk, nrst_in ); parameter PS = 2; //number of sync pipeline stages parameter DW = 1; //number of bits to synchronize input clk; input [DW-1:0] nrst_in; output [DW-1:0] nrst_out; //TOOD: Should only be one target `ifdef TARGET_SIM reg [PS-1:0] sync_pipe[DW-1:0]; `else (* ASYNC_REG = "TRUE" *) (* DONT_TOUCH = "TRUE" *) reg [PS-1:0] sync_pipe[DW-1:0]; `endif genvar i; integer j; generate for(i=0;i