私は学術プロジェクト用のブース乗数を作成しようとしていますが、私は奇妙なエラーが発生しています。これがQuartus IIに戻るか、VHDLと何か関係があるかどうかは不明です。私は、次のコードを分析し、詳しく説明してみてください変数x:= x + yを代入すると、詳細が凍結します
毎回、無期限のプロセスがフリーズ(私はそれがすでに時間のために実行持っていた)の分析&合成相の46%で、コンソールに最後の行は12127 Elaborating entity "booth_mul" for the top level hierarchy
なしです任意のノートの他の特定の警告やエラー(いつもの(found x design units,...
)
ARCHITECTURE booth_mul OF booth_mul IS
BEGIN
process(Ain, Bin)
variable result, toResult: STD_LOGIC_VECTOR(63 downto 0);
--other variables
begin
--other stuff
for i in 0 to 31 loop
--other stuff
--toResult is the partial product being added to the result
toResult := STD_LOGIC_VECTOR(SHIFT_LEFT(UNSIGNED(toResult), i*2));
result := result + toResult; --A&E Freezes if this line is included!!
end loop;
output <= result;
end process;
END;
私はこれのさまざまな部分をコメントアウトしようとしましたし、それが問題であるラインです。これは、VHDLとかと構文の問題ですQuartus II自体?
Quartusを使用するII 64ビットバージョン13.0.1 232 2013年6月12日SJのWeb版に
アップデートのビルド: を私は自分のコードの残りの部分を提供してきましたが、それは障害でなければなりませんようにそれはいないようです。デザインはエラーなしでコンパイルされますが、これは3時間程度で完了します。ここに完全なデザインがあります:
LIBRARY ieee;
use ieee.std_logic_1164.all;
use ieee.std_logic_signed.all;
use ieee.numeric_std.all;
ENTITY booth_mul IS
PORT
(
Ain : IN STD_LOGIC_VECTOR(31 downto 0);
Bin : IN STD_LOGIC_VECTOR(31 DOWNTO 0);
output : OUT STD_LOGIC_VECTOR(63 DOWNTO 0)
);
END booth_mul;
ARCHITECTURE booth_mul OF booth_mul IS
BEGIN
process(Ain, Bin)
variable result, temp, toResult: STD_LOGIC_VECTOR(63 downto 0);
variable toAdd, toSub : STD_LOGIC_VECTOR(31 downto 0);
begin
toAdd := Ain;
toSub := (0 - Ain);
for i in 0 to 31 loop
if i = 0 then
if Bin(0) <= '1' then
toResult(31 downto 0):= toSub;
end if;
else
if (Bin(i) <= '1' and Bin(i-1) <='0') then
toResult(31 downto 0):= toSub;
elsif (Bin(i) <= '0' and Bin(i-1) <='1') then
toResult(31 downto 0):= toAdd;
end if;
end if;
--
-- --Sign Extension
if toResult(31) <= '1' then
toResult(63 downto 32) := x"11111111";
else
toResult(63 downto 32) := x"00000000";
end if;
toResult := STD_LOGIC_VECTOR(SHIFT_LEFT(UNSIGNED(toResult), i*2));
result := result + toResult; --A&E Freezes HERE!!
end loop;
output <= result;
end process;
END;
あなたの質問に[最小限の、完全で、検証可能な例](https://stackoverflow.com/help/mcve)は表示されません。 – user1155120
私は2014年のi7ノートパソコンで54分でQuartus 13.1ウェブ版でこれを合成しました。それはたくさんのロジックです:2082個のロジックエレメント。 –
VHDLの経験はありますか?コードをCPUのコードのように記述しています。 VHDL(特に合成の場合)には別のアプローチが必要です。 – JHBonarius