finished exec & deleted reports in alu
This commit is contained in:
parent
72cb0a963d
commit
0853e65042
|
@ -6,6 +6,8 @@ ARM barrel shifter (pour debug ROR et RRX) : http://www.davespace.co.uk/arm/intr
|
|||
|
||||
VHDL basics par Intel FPGA : https://www.youtube.com/watch?v=zm-RA6BsYmc&ab_channel=IntelFPGA
|
||||
|
||||
Declaration VHDL : https://www.csee.umbc.edu/portal/help/VHDL/declare.html
|
||||
|
||||
# notice :
|
||||
|
||||
Utiliser uniquement ghdl-gcc (llvm et mcode abort lors des overflows dans les tbs)
|
||||
|
|
10
alu.vhdl
10
alu.vhdl
|
@ -40,24 +40,24 @@ begin
|
|||
begin
|
||||
case cmd is
|
||||
when "00" =>
|
||||
report "ADD";
|
||||
-- report "ADD";
|
||||
res_temp <= add;
|
||||
cout_temp <= add_cout;
|
||||
|
||||
when "01" =>
|
||||
report "AND";
|
||||
-- report "AND";
|
||||
res_temp <= op1 and op2 ;
|
||||
cout_temp <= '0';
|
||||
when "10" =>
|
||||
report "OR ";
|
||||
-- report "OR ";
|
||||
res_temp <= op1 or op2;
|
||||
cout_temp <= '0';
|
||||
when "11" =>
|
||||
report "XOR";
|
||||
-- report "XOR";
|
||||
res_temp <= op1 xor op2 ;
|
||||
cout_temp <= '0';
|
||||
when others =>
|
||||
report "ERROR";
|
||||
report "[ERROR] SWITCH CASE UNREACHABLE (Alu::cmd not initialised ?)";
|
||||
end case;
|
||||
end process;
|
||||
|
||||
|
|
21
exec.vhdl
21
exec.vhdl
|
@ -240,15 +240,18 @@ architecture Behavior OF EXec is
|
|||
-- carry flag
|
||||
exe_c <= alu_value_cout;
|
||||
|
||||
-- sortie mutex entre ALU et fifo
|
||||
|
||||
-- sortie du mutiplexeur entre ALU et fifo
|
||||
mem_adr <= (dec_op1) when dec_pre_index='1' else alu_value_out;
|
||||
|
||||
-- Sortie restante
|
||||
-- exe_pop <= dec2exe_empty;
|
||||
|
||||
-- exe_dest <= dec_exe_dest;
|
||||
-- exe_wb <= dec_exe_wb;
|
||||
-- exe_flag_wb <= dec_flag_wb;
|
||||
|
||||
-- Synchronisation fifo
|
||||
exe_pop <= '1' when (
|
||||
(not dec2exe_empty='1') and (not exe2mem_full='1') -- verification dec2exe non vide et exe2mem non pleine
|
||||
and (dec_mem_lb='1' or dec_mem_lw='1' or dec_mem_sb='1' or dec_mem_sw='1') -- si un acces memoire a lieu
|
||||
) else '0';
|
||||
|
||||
|
||||
exe_dest <= dec_exe_dest;
|
||||
exe_wb <= '0' when dec2exe_empty ='1' else dec_exe_wb ;
|
||||
exe_flag_wb <= '0' when dec2exe_empty ='1' else dec_flag_wb;
|
||||
|
||||
end Behavior;
|
Loading…
Reference in New Issue