Line 1... |
Line 1... |
`timescale 1ns / 1ps
|
`timescale 1ns / 1ps
|
`include "aDefinitions.v"
|
`include "aDefinitions.v"
|
|
`ifdef VERILATOR
|
|
`include "Theia_Core.v"
|
|
`endif
|
/**********************************************************************************
|
/**********************************************************************************
|
Theia, Ray Cast Programable graphic Processing Unit.
|
Theia, Ray Cast Programable graphic Processing Unit.
|
Copyright (C) 2010 Diego Valverde (diego.valverde.g@gmail.com)
|
Copyright (C) 2010 Diego Valverde (diego.valverde.g@gmail.com)
|
|
|
This program is free software; you can redistribute it and/or
|
This program is free software; you can redistribute it and/or
|
Line 322... |
Line 325... |
//Create the Cross-Bar interconnection grid now, rows are coonected to the memory banks,
|
//Create the Cross-Bar interconnection grid now, rows are coonected to the memory banks,
|
//while collumns are connected to the cores, 2 or more cores can not read from the same
|
//while collumns are connected to the cores, 2 or more cores can not read from the same
|
//bank at any given point in time
|
//bank at any given point in time
|
for (Core = 0; Core < `MAX_CORES; Core = Core + 1)
|
for (Core = 0; Core < `MAX_CORES; Core = Core + 1)
|
begin: CORE_CONNECT
|
begin: CORE_CONNECT
|
|
`ifndef VERILATOR
|
//Connect the Data Collum of this core to the Data Row of current bank, only if the Core is looking for data stored in this bank
|
//Connect the Data Collum of this core to the Data Row of current bank, only if the Core is looking for data stored in this bank
|
assign wCrossBarDataCollumn[ Core ] = ( wCoreBankSelect[ Core ] == Bank ) ? wCrossBarDataRow[ Bank ] : `WB_WIDTH'bz;
|
assign wCrossBarDataCollumn[ Core ] = ( wCoreBankSelect[ Core ] == Bank ) ? wCrossBarDataRow[ Bank ] : `WB_WIDTH'bz;
|
//Connect the Address Row of this Bank to the Address Column of the core, only if the Arbiter selected this core for reading
|
//Connect the Address Row of this Bank to the Address Column of the core, only if the Arbiter selected this core for reading
|
assign wCrossBarAddressRow[ Bank ] = ( wCurrentCoreSelected[ Bank ] == Core ) ? wCrossBarAdressCollumn[Core]: `WB_WIDTH'bz;
|
assign wCrossBarAddressRow[ Bank ] = ( wCurrentCoreSelected[ Bank ] == Core ) ? wCrossBarAdressCollumn[Core]: `WB_WIDTH'bz;
|
|
`endif
|
|
|
end
|
end
|
|
|
end
|
end
|
endgenerate
|
endgenerate
|