Allocates and returns a new `CompileOptions` object with specified values.
- Parameter useSingleThread: Specifies whether the graph should execute on one thread.
- Parameter generateDebugInfo: A Boolean value that specifies whether the generated graph includes debug info.
- Parameter optimizationPreference: A constant that specifies the graph compilation optimization preferences.
- SeeAlso: `BNNSGraphCompileOptionsMakeDefault`
get · iOS 18.0+
useSingleThread
TypeScript
get useSingleThread(): boolean
Swift declaration
var useSingleThread: Bool { get set }
The option for compiled graph to execute on only one thread.
Default behavior is to execute on multiple threads.
- SeeAlso: `BNNSGraphCompileOptionsSetTargetSingleThread`
- SeeAlso: `BNNSGraphCompileOptionsGetTargetSingleThread`
set · iOS 18.0+
useSingleThread
TypeScript
set useSingleThread(value: boolean)
Swift declaration
var useSingleThread: Bool { get set }
The option for compiled graph to execute on only one thread.
Default behavior is to execute on multiple threads.
- SeeAlso: `BNNSGraphCompileOptionsSetTargetSingleThread`
- SeeAlso: `BNNSGraphCompileOptionsGetTargetSingleThread`
get · iOS 18.0+
generateDebugInfo
TypeScript
get generateDebugInfo(): boolean
Swift declaration
var generateDebugInfo: Bool { get set }
A Boolean value that specifies whether the generated `BNNSGraph.Context` object includes debug info.
Default behavior is *not* to include debug info.
- SeeAlso: `BNNSGraphCompileOptionsSetGenerateDebugInfo`
- SeeAlso: `BNNSGraphCompileOptionsGetGenerateDebugInfo`
set · iOS 18.0+
generateDebugInfo
TypeScript
set generateDebugInfo(value: boolean)
Swift declaration
var generateDebugInfo: Bool { get set }
A Boolean value that specifies whether the generated `BNNSGraph.Context` object includes debug info.
Default behavior is *not* to include debug info.
- SeeAlso: `BNNSGraphCompileOptionsSetGenerateDebugInfo`
- SeeAlso: `BNNSGraphCompileOptionsGetGenerateDebugInfo`
get · iOS 18.0+
optimizationPreference
TypeScript
get optimizationPreference(): BNNSGraph_CompileOptions_OptimizationPreference
Swift declaration
var optimizationPreference: BNNSGraph.CompileOptions.OptimizationPreference { get set }
The option that specifies the optimization preference to compile with.
Default is `.performance`.
- SeeAlso: BNNSGraphOptimizationPreference
set · iOS 18.0+
optimizationPreference
TypeScript
set optimizationPreference(value: BNNSGraph_CompileOptions_OptimizationPreference)
Swift declaration
var optimizationPreference: BNNSGraph.CompileOptions.OptimizationPreference { get set }
The option that specifies the optimization preference to compile with.
Default is `.performance`.
- SeeAlso: BNNSGraphOptimizationPreference
init · iOS 18.0+
init
TypeScript
static init(): BNNSGraph_CompileOptions
Swift declaration
init()
Allocates and returns a new `CompileOptions` object with default values.
- SeeAlso: `BNNSGraphCompileOptionsMakeDefault`