Changeset 15725
- Timestamp:
- 08/06/13 11:33:09 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/test/NightlyRun/runme.m
r15719 r15725 159 159 disp(['Extracting results of ' fields{i}]); 160 160 end 161 errlog = cellstr(md.results.(fields{i}).errlog); 162 lines = strfind(errlog,'definitely lost:'); 163 lines = find(~cellfun(@isempty,lines)); 164 total = 0; 165 for j=1:numel(lines) 166 Line = errlog(lines(j)); 161 results = md.results.(fields{i}); 162 errlog = cellstr(results(1).errlog); 163 lines1 = strfind(errlog,'definitely lost:'); 164 lines1 = find(~cellfun(@isempty,lines1)); 165 lines2 = strfind(errlog,'Conditional jump or move depends on uninitialised value'); 166 lines2 = find(~cellfun(@isempty,lines2)); 167 jumps = numel(lines2); 168 leaks = 0; 169 for j=1:numel(lines1) 170 Line = errlog(lines1(j)); 167 171 Numbers = sscanf(Line{1},'==%i== definitely lost: %s bytes in %i blocks',[1 Inf]); 168 total = total+ str2num(strrep(char(Numbers(2:end-1)),',',''));169 end 170 if total==0,171 disp(sprintf(['SUCCESS difference: 0 < 0 test id: %i test name: %s field: valgrind '],id,id_string));172 leaks = leaks + str2num(strrep(char(Numbers(2:end-1)),',','')); 173 end 174 if leaks==0, 175 disp(sprintf(['SUCCESS difference: 0 < 0 test id: %i test name: %s field: valgrindleaks'],id,id_string)); 172 176 else 173 disp(sprintf(['ERROR difference: %i > 0 test id: %i test name: %s field: valgrind'],total,id,id_string)); 177 disp(sprintf(['ERROR difference: %i > 0 test id: %i test name: %s field: valgrindleaks'],leaks,id,id_string)); 178 disp('STOP'); 179 return; 180 end 181 if jumps==0, 182 disp(sprintf(['SUCCESS difference: 0 < 0 test id: %i test name: %s field: valgrindjumps'],id,id_string)); 183 else 184 disp(sprintf(['ERROR difference: %i > 0 test id: %i test name: %s field: valgrindjumps'],jumps,id,id_string)); 174 185 disp('STOP'); 175 186 return;
Note:
See TracChangeset
for help on using the changeset viewer.