Merge from mainline
[official-gcc.git] / gcc / testsuite / consistency.vlad / README
blob3cdf6e32a555643d4cdb6270ee2200d94d3deca3
1   This directory contains tests and scripts for consistency checking
2 compilers.  They could be used for consistency checking different
3 C/C++ compiler for one platform or C/C++ compilers for different
4 platforms.
6   For example, to check the consistency, you could type
8    make check-consistency RUNTESTFLAGS='BASE_COMPILER=i960-97r2 CONSISTENCY_OPTIONS="-O2 -fvtable-thunks -mno-strict-align -fno-rtti -fcheck-new -mcall-i960-old -mlittle-endian" NO_LONG_DOUBLE=1 NO_LIBGLOSS_LIBRARY_OPTIONS=1'
10   In this example, DEJAGNU driver vlad.exp will process all C/C++
11 tests in all subdirectories (e.g. layout) started with lower case
12 letter.  C tests (with suffixes .c) will be compiled by C compiler
13 only.  C++ tests will be compiled by C and C++ compilers.  It is
14 supposed that each test outputs the result which is saved in temp_dir
16    <basename of the test>.out
18    <basename of the test>.out++
20 correspondingly for C compiler and C++ compiler.  For example, there
21 will be two output files
23    `align-double.out' and `align-double.out++'
25 for test `align-double.c'.
27   After this if there is subdirectory <BASE_COMPILER>-results
28 (`i960-97r2-results' in our example) and there is corresponding saved
29 output file for the base compiler the the files are compared in order
30 to check consistency.
32   To create the base for future comparisons of output files, you
33 should create the directory and move output files from the temporary
34 directory into the created directory.
36 The test script file has the following parameters
38  1. BASE_COMPILER.  The variable must be defined for work the script
39     properly.
41  2. CONSISTENCY_OPTIONS.  The options which will be used for
42     compilations.  The default value is "-O2".
44  3. NO_LONG_DOUBLE.  If the variable value is not zero, the tests
45     which contain long double are expected to be fail.
47  4. NO_LIBGLOSS_LIBRARY_OPTIONS.  If the variable value is not zero,
48     the tests are compiled without standard dejagnu libgloss library
49     paths.
51   Currently, there is directory `layout' for checking allocation
52 parameters of C/C++ compiler and subdirectory i960-97r2 which contains
53 the test results for 97r2 i960-vxworks C/C++ compiler.
55   You can create other consistency tests.  Simply, create a directory
56 started with lower case letter, place the tests and create the
57 subdirectory with the test results for a base compiler.  If you need
58 to compile tests in a directory with a wrap file simply place the file
59 name (e.g. _dummy_stab.S) in file WRAP_FILE in the test directory.
61   The tests will be only compiled (and the test results will not be
62 compared) if you place <basename of the test>.conly in the directory
63 of the test.  You can use own driver for checking consistency.  To
64 make this, place the TCL script with name <basename of the test>.cexp.
66 Vladimir Makarov <vmakarov@cygnus.com>