Update of /cvsroot/compbench/CompBenchmarks++/CBM-PI/t
In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv29977
Modified Files:
03-CBMCompilerSelector-public.pl
Log Message:
GCC 3.1.x introduced.
Index: 03-CBMCompilerSelector-public.pl
===================================================================
RCS file: /cvsroot/compbench/CompBenchmarks++/CBM-PI/t/03-CBMCompilerSelector-public.pl,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -d -r1.7 -r1.8
*** 03-CBMCompilerSelector-public.pl 20 Mar 2007 20:29:55 -0000 1.7
--- 03-CBMCompilerSelector-public.pl 17 Apr 2007 20:08:08 -0000 1.8
***************
*** 1,3 ****
--- 1,11 ----
#!/usr/bin/perl -w -I ..
+ # -----------------------------------------------------------------------------
+ # $Id$
+ #
+ # This is free software.
+ # For details, see the GNU Public License in the COPYING file, or
+ # Look http://www.fsf.org
+ # -----------------------------------------------------------------------------
+
use strict;
use CBM;
***************
*** 10,13 ****
--- 18,25 ----
my $sys;
+ my %supportedVersions = ('g++' => '2.95.x 3.0.x 3.1.x',
+ 'gcc' => '2.95.x 3.0.x 3.1.x',
+ 'tcc' => '0.9.x');
+
my %references = ('compiler-fake-g++-4.1.1-13' =>
{'language' => 'C++',
***************
*** 15,19 ****
'compilerName' => 'g++ (GCC) 4.1.2 20060901 (prerelease) (Debian 4.1.1-13)',
'compilerVersion' => '4.1.2 20060901 (prerelease)',
! 'vanilla' => '4.1.2'
},
'compiler-fake-gcc-3.2.3-20-rh' =>
--- 27,32 ----
'compilerName' => 'g++ (GCC) 4.1.2 20060901 (prerelease) (Debian 4.1.1-13)',
'compilerVersion' => '4.1.2 20060901 (prerelease)',
! 'vanilla' => '4.1.2',
! 'compatibility' => '3.1.x'
},
'compiler-fake-gcc-3.2.3-20-rh' =>
***************
*** 22,26 ****
'compilerName' => 'gcc (GCC) 3.2.3 20030502 (Red Hat Linux 3.2.3-20)',
'compilerVersion' => '3.2.3',
! 'vanilla' => '3.2.3'
},
'compiler-fake-gcc-4.1.1-13' =>
--- 35,40 ----
'compilerName' => 'gcc (GCC) 3.2.3 20030502 (Red Hat Linux 3.2.3-20)',
'compilerVersion' => '3.2.3',
! 'vanilla' => '3.2.3',
! 'compatibility' => '3.1.x'
},
'compiler-fake-gcc-4.1.1-13' =>
***************
*** 29,33 ****
'compilerName' => 'gcc (GCC) 4.1.2 20060901 (prerelease) (Debian 4.1.1-13)',
'compilerVersion' => '4.1.2 20060901 (prerelease)',
! 'vanilla' => '4.1.2'
},
'compiler-fake-tcc-0.9.23',
--- 43,48 ----
'compilerName' => 'gcc (GCC) 4.1.2 20060901 (prerelease) (Debian 4.1.1-13)',
'compilerVersion' => '4.1.2 20060901 (prerelease)',
! 'vanilla' => '4.1.2',
! 'compatibility' => '3.1.x'
},
'compiler-fake-tcc-0.9.23',
***************
*** 36,44 ****
'compilerName' => 'Tiny C Compiler tcc version 0.9.23',
'compilerVersion' => 'tcc version 0.9.23',
! 'vanilla' => '0.9.23'
}
);
! plan tests => (keys %references)*5;
$sys = CBM::Init();
--- 51,77 ----
'compilerName' => 'Tiny C Compiler tcc version 0.9.23',
'compilerVersion' => 'tcc version 0.9.23',
! 'vanilla' => '0.9.23',
! 'compatibility' => '0.9.x'
}
);
! sub checkSupportedVersion {
! my $co = shift;
! my $refdata = shift;
!
! my @expectedVersions = split(' ', $supportedVersions{$co->compiler()});
! my $xn = (@expectedVersions+0);
! my $n = $co->supportedVersionNumber();
!
! ok($n == $xn,
! "Supported versions number for " . $co->compiler() . " is $xn (has $n)");
!
! my $comp = $co->relativeDescriptionDirectory();
! my $xv = $refdata->{compatibility};
!
! ok($comp eq $xv, "Nearest compatibility for " . $co->VanillaVersion() . " is $xv (has $comp)");
! }
!
! plan tests => (keys %references)*7;
$sys = CBM::Init();
***************
*** 58,61 ****
--- 91,95 ----
ok($refdata{compilerVersion} eq $co->Version(), "$reffile: compilerVersion is $refdata{compilerVersion} (has " . $co->Version() . ")");
ok($refdata{vanilla} eq $co->VanillaVersion(), "$reffile: vanilla is $refdata{vanilla} (has " . $co->VanillaVersion() . ")");
+ checkSupportedVersion($co, \%refdata);
}
|