Line | |
---|
1 | /* |
---|
2 | * $Id$ |
---|
3 | * |
---|
4 | * [ Description ] |
---|
5 | * |
---|
6 | */ |
---|
7 | |
---|
8 | #include <stdint.h> |
---|
9 | #include "Behavioural/Generic/RegisterFile/include/Parameters.h" |
---|
10 | #include "Behavioural/Generic/RegisterFile/include/Types.h" |
---|
11 | #include <sstream> |
---|
12 | using namespace std; |
---|
13 | |
---|
14 | namespace morpheo { |
---|
15 | namespace behavioural { |
---|
16 | namespace generic { |
---|
17 | namespace registerfile { |
---|
18 | |
---|
19 | string Parameters::msg_error(void) |
---|
20 | { |
---|
21 | string msg = ""; |
---|
22 | |
---|
23 | if ((8*sizeof(Tdata_t)) < _size_word) |
---|
24 | { |
---|
25 | msg += " - type \"Tdata_t\" is too little to the size defined by size_word\n"; |
---|
26 | msg += " * size_word : " + toString(_size_word) + "\n"; |
---|
27 | msg += " * Tdata_t (bits): " + toString(8*(sizeof(Tdata_t))) + "\n"; |
---|
28 | } |
---|
29 | |
---|
30 | if ((8*sizeof(Taddress_t)) < log2(_nb_word)) |
---|
31 | { |
---|
32 | msg += " - type \"Taddress_t\" is too little to the size defined by nb_word\n"; |
---|
33 | msg += " * nb_word : " + toString(_nb_word) + "\n"; |
---|
34 | msg += " > size (bits) : " + toString(log2(_nb_word)) + "\n"; |
---|
35 | msg += " * Taddress_t (bits) : " + toString(8*(sizeof(Taddress_t))) + "\n"; |
---|
36 | } |
---|
37 | |
---|
38 | if (_nb_word < 2) |
---|
39 | { |
---|
40 | msg += " - nb_word must be >= 2\n"; |
---|
41 | msg += " * nb_word : " + toString(_nb_word) + "\n"; |
---|
42 | } |
---|
43 | |
---|
44 | return msg; |
---|
45 | }; |
---|
46 | |
---|
47 | }; // end namespace registerfile |
---|
48 | }; // end namespace generic |
---|
49 | }; // end namespace behavioural |
---|
50 | }; // end namespace morpheo |
---|
Note: See
TracBrowser
for help on using the repository browser.