Skip to main content

optimize

The optimize function specifies the level and type of optimization used while building the target configuration.

optimize "value"

If no value is set for a configuration, the toolset's default optimization (usually none) will be performed.

Parameters

value specifies the desired level of optimization:

ValueDescription
OffNo optimization will be performed.
OnPerform a balanced set of optimizations.
DebugOptimization with some debugger step-through support.
SizeOptimize for the smallest file size.
SpeedOptimize for the best performance.
FullFull optimization.

Applies To

Project configurations.

Availability

Premake 5.0.

Examples

optimize "Speed"