Tags

Discussing Modern C++ at the INFN

C++ has been one of the most used lan­guages in the world of high­-en­ergy physics since the be­gin­ning of the LHC project in the early ’90s. During a very ex­citing visit to the INFN of­fices in Bologna, Matteo Ci­cuttin and I gave a talk about Modern C++ and its use in nu­meric ap­pli­ca­tions.

Bologna is al­ways a very nice city to visit in any oc­ca­sion. With its re­nais­sance center full of art, his­tory, and gas­tro­nomic spe­cialties, and its very ac­tive night life, each visit can be a unique ex­pe­ri­ence. If you look care­fully, though, you will find that Bologna is also one of the sci­en­tific hubs of the coun­try.

The emilian re­gion around the city is the core of the italian bio­med­ical and biotech in­dus­try, and the Uni­ver­sity of Bologna Alma Mater is the oldest uni­ver­sity in the world still op­er­at­ing. Be­sides that, Bologna also hosts one of the sec­tions of the INFN, the Na­tional In­sti­tute of Nu­clear Physics, the in­sti­tute that co­or­di­nates all the italian re­search ac­tiv­i­ties in par­ticle physics, and is one of the main players at CERN in Geneva.

Bologna is also home to the com­puting tech­nolo­gies re­search center of the INFN (CNAF), which runs one of the Tier 1 data cen­ters of CERN’s LHC com­puting grid. CNAF has a leading role, within the INFN, in the de­vel­op­ment of mid­dle­ware soft­ware for LHC Grid and Cloud com­puting ser­vices, and is in­volved in the de­vel­op­ment of soft­ware for some of the INFN ex­per­i­ments. Last year, thanks to my talk at Meeting C++ about func­tional pro­gram­ming in C++, I had the plea­sure to meet Francesco Gi­a­co­mini, a CNAFtec­nol­o­gist and C++ spe­cialist who was so kind to give two talks in Udine about how the C++ lan­guage is em­ployed in INFN and CNAF ac­tiv­i­ties. In con­trast to other areas of physics, where the use of legacy lan­guages like FOR­TRAN is still the norm, the C++ lan­guage is one of the most used in the par­ticle physics com­mu­nity, thanks to the leading role of CERN, which in the ’90s de­cided to adopt C++ for LHC sim­u­la­tion and data analysis soft­ware like ROOT and Geant4, and al­most all of ex­per­i­men­t-spe­cific code.

This year, on July 7th, I was glad to re­turn the favor by vis­iting CNAF to give a talk about Modern C++, to­gether with the friend of mine Matteo Ci­cuttin, who works at CER­MICS on finite-ele­ments nu­mer­ical methods for PDEs. Mat­teo, like me, is a strong ad­vo­cate of the use of this lan­guage in per­for­mance-sen­si­tive ap­pli­ca­tions and his work takes full ad­van­tage of modern lan­guage fea­tures and gen­eral pro­gram­ming tech­niques.

To­gether we out­lined some im­por­tant fea­tures of the lan­guage in the con­text of com­plex high­-per­for­mance code, and he showed his DiSk++ li­brary for res­o­lu­tion of large PDEs sys­tems. The talk led to an in­ter­esting de­bate about the status of C++ tooling sup­port and testing fa­cil­i­ties. You can find the slides here: Part 1 and Part 2.