Compiling erlydtl files with OTP 27 very slow/getting timeout

We are having a lot erlydtl files in our application and compiling those with otp27 takes for ever to complete.
We took just one sample file. It took 32 secs to compile with otp25 and we got a timeout when trying with otp27.

Environment: M1 MB Air running Monterey 12.1

Any help is highly appreciated.

If you could provide the file in question that would be great. If you cannot, can you at least run erlc +time on it as that may provide some idea of which compiler pass is taking such a long time.

Hi, Thats a internal file with lot erlydtl code and i am using erlydtl:compile to compile the file for which I am getting timeout with OTP27 where as the same file compiles in 32 seconds with OTP25