<div dir="ltr">Hi everyone!<div><br></div><div>I am new to llvm and excuse me if this is a wrong question for this forum. </div><div><br></div><div>I am trying to design a front end for my own programming language using the LLVM infrastructure for a personal project. It's a very simple procedural language for now; no object oriented business.</div><div><br></div><div>I am playing around with a simple concept and was wondering if it's possible to implement it in the LLVM environment.</div><div><br></div><div>Consider I have a simple declaration statement.</div><div><br></div><div>float array a[sqrt(9)];</div><div><br></div><div>Is it possible to evaluate "sqrt(9)" before generating LLVM IR by calling some math library function? This is still compile time and way before the JIT kicks in, so I won't be able to take advantage of the JIT. In other words, the LLVM IRBuilder would probably see something like -- "float array a[3];", and won't even know that "sqrt(9)" existed. Only my parser would be aware of its existence.</div><div><br></div><div>Let me know if this is possible.</div><div><br></div><div>Thanks,</div><div>Pranav</div><div><br></div><div><br></div></div>