Changes between Version 3 and Version 4 of Ticket #2133, comment 19
- Timestamp:
- 2018-11-15T17:33:16+01:00 (5 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #2133, comment 19
v3 v4 4 4 dev_r10164_HPC09_ESIWACE_PREP_MERGE: action 2a: add report calls of mppmin/max/sum, see #2133 5 5 }}} 6 7 8 In action 2a, we used the following script to automatically modify all the calls to lbc_lnk and mpp_min/max/sum (that are not yet changed).9 10 11 {{{#!bash12 set -u13 14 for dd in $( find . -wholename "*/MY_SRC" ) $( find src -type d | grep -v svn )15 do16 cd $dd17 pwd18 echo19 for file in `grep -i "call *lbc_lnk *( *[a-zA-Z_0-9]" * | awk '{print $1}' | sed s/\:'.*'// | uniq`20 do21 routinename=` echo $file | sed s/\\\.'.*'//`22 sed -e "s/ lbc_lnk\( *\)(\( *\)\([a-zA-Z_0-9]\)/ lbc_lnk\1(\2\'${routinename}\', \3/g" \23 -e "s/ lbc_lnk_multi\( *\)(\( *\)\([a-zA-Z_0-9]\)/ lbc_lnk_multi\1(\2\'${routinename}\', \3/g" \24 $file > toto25 mv toto $file26 echo $file done27 done28 for file in `grep -i "call *mpp_... *( *[a-zA-Z_0-9]" * | awk '{print $1}' | sed s/\:'.*'// | uniq`29 do30 routinename=` echo $file | sed s/\\\.'.*'//`31 sed -e "s/ mpp_min\( *\)(\( *\)\([a-zA-Z_0-9]\)/ mpp_min\1(\2\'${routinename}\', \3/g" \32 -e "s/ mpp_max\( *\)(\( *\)\([a-zA-Z_0-9]\)/ mpp_max\1(\2\'${routinename}\', \3/g" \33 -e "s/ mpp_sum\( *\)(\( *\)\([a-zA-Z_0-9]\)/ mpp_sum\1(\2\'${routinename}\', \3/g" \34 $file > toto35 mv toto $file36 echo $file done37 done38 echo39 cd -40 done41 42 }}}43