Success Story: Code Modernization for the Glass Industry

NCC presenting the success story

Turkish National e-Science e-Infrastructure (TRUBA), operating under Turkish Academic Network and Information Center (TUBITAK ULAKBIM) is the coordinator of NCC Turkey. Middle East Technical University (METU), Sabancı University (SU), and Istanbul Technical University National Center for High-Performance Computing (UHeM) are the third parties of the NCC.

While METU is a public university based in Ankara, SU is a privately-funded university in Istanbul. ITU UHeM, also based in Istanbul, provides supercomputing and data storage services to academic and industrial users. Our competencies include High-Performance Computing (HPC), High-Performance Data Analytics (HPDA), Artificial Intelligence (AI), CUDA, Materials Science, Computational Fluid Dynamics (CFD), and several other fields. The third-party presenting this success story is Sabanci University.

Technical/scientific Challenge:

Şişecam fabricates glass products using custom-made furnaces. They use a simulation code written some decades ago that traces the glass particles inside the furnace. In a nutshell, the longer the particles stay inside the furnace, the better the quality of the product. To achieve this, they need to perform simulations with many particles; however, the computational cost increases enormously as the number of particles increases. To overcome this problem, the company applied to the center for consultancy on code modernization and scalable parallelization of the code to decrease the design process of the furnaces. 

Business impact:

In the simulation code, the particles are processed in batches. After the code is parallelized and modernized, the batch size is increased to 1000 from 10. The reason for using a large batch size is the long-tailed running time of some of the particles; using a larger batch size and dynamic scheduling we were able to increase core utilization to > 90% from < 20% on the development machine (with 16-core/32-thread AMD Ryzen9).

On the longest-running test case provided by Şişecam, the Fortran code was taking 7 hours 14 minutes on the development machine, whereas unoptimized C++ code takes only 27 minutes 21 seconds. On a server with 20-core Xeon 6148 2.40 GHz, the code only takes 286 seconds. Even when a single thread, the runtime is 18 minutes, a huge speed-up compared to 7 hours on the development machine. Using 20 cores, the new implementation was able to achieve 3.86x speedup which can be further improved.

Industrial Organisations Involved:

As one of the most powerful industrial conglomerates in Turkey, Şişecam is a global player in all key areas of the glass industry. It is internationally renowned for its ever-growing production power, highly reputable brand image, superior product quality, and value-creating sustainable growth approach. It is currently one of the world’s leading glass producers with production operations located in 14 countries on four continents, 24000 employees, and sales in over 150 countries around the globe.


Before the use-case study, the simulation process was taking days and Şişecam was limited by small models to make the process faster and wanted to increase the size to have more accurate simulations. In this case study, after discussions, we all agreed on converting the whole codebase to C++ is the main path we need to follow. The competence center helped Şişecam engineers to convert the code to a more modern architecture and discuss/recommend parallelization strategies on a multicore system with OpenMP. At last, the Fortran code is translated to modern C++ line by line, except goto statements which are translated as loop constructs for better readability. Then, the dead code is eliminated to reduce code size. Common logical patterns are converted to functions for better readability.


  • We were able to translate a complicated numerical code that depends on depreciated technologies to modern C++.
  • While translating, improvements in both maintainability and performance are done.
  • In addition, the implementation is parallelized to use multiple cores with efficiency and the runtime is reduced from hours to minutes.


Success story # Highlights:

  • Glass production, particle simulation, code modernization.
  • Industry sector: Glass Manufacturing & engineering.
  • Technology: HPC.


Kamer Kaya, Sabancı University, Computer Science and Engineering,

This project has received funding from the European High-Performance Computing Joint Undertaking (JU) under grant agreement No 951732. The JU receives support from the European Union’s Horizon 2020 research and innovation program and Germany, Bulgaria, Austria, Croatia, Cyprus, the Czech Republic, Denmark, Estonia, Finland, Greece, Hungary, Ireland, Italy, Lithuania, Latvia, Poland, Portugal, Romania, Slovenia, Spain, Sweden, the United Kingdom, France, the Netherlands, Belgium, Luxembourg, Slovakia, Norway, Switzerland, Turkey, Republic of North Macedonia, Iceland, Montenegro