This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Hi,
Is it possible to enable extra warning information that shows the intializer list of a c++ class has a different order compared to the class definition? In GCC these warnings appear when i supply -Wreorder
Is this also possible for the C6000 compiler?
If so which warning number (see #880-D example below) does this warning have, because i would like to enable it as an error
Example warning number :"foo.cpp", line 193: warning #880-D: parameter "foobar" was never referenced
Thanks in advance,
Rob
This diagnostic is classified as a remark by default, so you need to activate all remarks with the -pdr option:
cl6x file.cpp -pdr -pden "file.cpp", line 3: remark #1988-D: the initialization of member "a::x" will be done before that of member "a::y"
or turn this one remark into a warning with the -pdsw=1988 option:
cl6x file.cpp -pdsw=1988 -pden "file.cpp", line 3: warning #1988-D: the initialization of member "a::x" will be done before that of member "a::y"
Hi,
I tried your suggestion and have the following flags enabled when compiling:
COMMON_CFLAGS:= --gcc --silicon_version=6740 --abi=coffabi --display_error_number --
define=DSP=1 --display_error_number
CFLAGS:=$(COMMON_CFLAGS)
CXXFLAGS:=$(COMMON_CFLAGS)
LDFLAGS:=--warn_sections --reread_libs
COMMON_FLAGS:=--asm_directory=$(O)/$(1) --temp_directory=$(O)/$(1) --pp_directory=$(O)/$(1) --obj_directory=$(O)/$(1) \
--issue_remarks -pdsw=403 -pdsw=880 -pdsw=230 -pdsw=1988 -pdsw=342 -pdse=238 -pds=681
Question 1: I'm using c6x version 7.4.2 toolchain is this diagnostic number present in this compiler?
Question 2: can i suppress warnings generated by TI sytem headers like the following warning:
/data/tools/C6000CGT-7.4.2/include/limits", line 723: remark #195-D: zero used for undefined preprocessing identifier
Remark: When enabling all remarks with --issue_remarks (leaving out -pdsw, -pds, -pdse) i don't see the reordering warning. However when i compile my class with a normal GCC compiler it immediately displays the warning.
Hope you can help to enable more warnings in the c6x complir,
Thanks in advance,
Rob
Rob van de Voort said:Question 1: I'm using c6x version 7.4.2 toolchain is this diagnostic number present in this compiler?
No. No current release of the C6000 compiler supports this diagnostic. It will be supported in the next major release of the C6000 compiler. According to here, that is version 7.6.0, scheduled for the end of March.
Rob van de Voort said:Question 2: can i suppress warnings generated by TI sytem headers like the following warning:
Yes. To do it from the command line use -pds=195.
Thanks and regards,
-George
Thanks for your reply i will wait for the 7.6.0 releases before upgrading, for now i will verify the warnings in my classes using gcc x86.
Question3: -pds=195 also suppresses these remarks in my own code as well. I was wondering if the TI toolchain could ignore warnings generated by the TI system headers which i did not create.
For instance GCC ignores warnings generated by theses headers so meaningfull warnings of the user-code are visiable and not clouded by systemheader warnings. See http://gcc.gnu.org/onlinedocs/cpp/System-Headers.html
Thanks for your reply,
Regards Rob
Rob van de Voort said:-pds=195 also suppresses these remarks in my own code as well. I was wondering if the TI toolchain could ignore warnings generated by the TI system headers which i did not create.
Sorry, but the TI compiler does not provide such a feature.
Thanks and regards,
-George