verilog中的{a + b}和(a + b)有何不同。我用模擬做: reg [3:0] a = 4'b0001;
reg [3:0] b = 4'b1111;
reg [4:0] c = (a + b); give the result c = 5'b1_0000
但 reg [4:0] c = {a + b}; give c = 5'b0_0000;
它意味着(A + B)可以得
如果對於給定的過程,我聲明一個變量(比如說一個1位變量,variable temp : std_logic;),那麼我可以給變量賦值如果給定條件返回true,即 if (xyz=1) then --Assuming that this condition returns TRUE
temp:= '1';
??這個邏輯是否可以合成爲ASIC?
比方說,我下面的代碼: always_ff @(posedge clk, negedge rst) begin
if (~rst) begin
bad_singal <= '0;
good_signal <= '0;
end else begin
// do something
// bad_signal is not used