سؤال

I'm writing Objective-C code with LLVM. I have one file full of very performance-critical code. Is it possible to turn on compiler optimizations (specifically, loop unrolling) for just this one file, without setting a project-wide value?

هل كانت مفيدة؟

المحلول

Yes, it's possible. Choose your project file from the project navigator. Then choose the target. Click the Build Phases tab. Open the Compile Sources section. Double-click the source file of interest and add the compiler flag. Here's a picture:

compiler flag for one source file

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top