Slow compilation

hi
I’ve been experiencing very slow compilation speed in clang when used with polly. Is there any specific reason for it? Is there any solution for this? (Using clang version 15.0.7 an an ARM cluster)

We’d need to know:

  • What does “slow” mean to you.
  • What compile commands and settings are you using.
  • What system resources are you using? (how much is the compile specifically using, not just what does the system have overall)
  • What does “with polly” mean? (obvious to a polly user I’m sure, but I have no idea)
  • Have you compiled any other ways, that are not “slow”.

(I don’t quote “slow” to be sarcastic, it’s just that it means different things in context so it helps to define it)

If you are compiling a small program (and not clang itself) perhaps you could share it or a version of it on the off chance there is something unique to your setup, and others do not see this slowness.

hello,
What I mean is clang taking more time when we use -mllvm -polly flag along with it to prepare executable.
using a local ARM cluster (A64FX)
flags used:clang -O3 -mllvm -polly matrix.c (a matrix multiplication program of data type double)
time taken:
real 1m10.000s
user 1m9.504s
sys 0m0.135s
where as
clang -O3 matrix.c
time:
real 0m0.785s
user 0m0.227s
sys 0m0.182s

Polly is a collection of aggressive optimizations. One of the main reasons they’re not enabled by default is that they are computationally intensive and dramatically increase compile time.

This is behaving as expected.

1 Like