Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions docs/building-apps/build-properties.md
Original file line number Diff line number Diff line change
Expand Up @@ -314,6 +314,25 @@ If the .pkg that was created (if `CreatePackage` was enabled) should be signed.

Only applicable to macOS and Mac Catalyst.

## EnableProfiler

Enable components that are required for profiling to work.

It's enabled by default for debug builds (when [MtouchDebug](#MtouchDebug) or
[MmpDebug](#MmpDebug) is enabled), but needs to be enabled manually before
profiling release builds:

```xml
<PropertyGroup>
<EnableProfiler>true</EnableProfiler>
</PropertyGroup>
```

This will increase the app size slightly.

Only applicable when using the Mono runtime (CoreCLR always supports
profiling, while NativeAOT never does).

## EnableSGenConc

Enables the concurrent mode for the SGen garbage collector.
Expand Down
2 changes: 1 addition & 1 deletion dotnet/targets/Xamarin.Shared.Sdk.targets
Original file line number Diff line number Diff line change
Expand Up @@ -452,7 +452,7 @@
<ItemGroup>
<_MonoComponent Include="hot_reload" Condition="'$(MtouchInterpreter)' != ''" />
<_MonoComponent Include="debugger" Condition="'$(_BundlerDebug)' == 'true'" />
<_MonoComponent Include="diagnostics_tracing" Condition="'$(_BundlerDebug)' == 'true'" />
<_MonoComponent Include="diagnostics_tracing" Condition="'$(EnableProfiler)' == 'true'" />
<_MonoComponent Include="marshal-ilgen" Condition="'$(_AppleExcludeMarshalIlgenComponent)' != 'true'" />
</ItemGroup>
</Target>
Expand Down
2 changes: 2 additions & 0 deletions msbuild/Xamarin.Shared/Xamarin.Shared.props
Original file line number Diff line number Diff line change
Expand Up @@ -292,6 +292,8 @@ Copyright (C) 2020 Microsoft. All rights reserved.
<!-- Does not apply unless we're actually building a library - and since BundleOriginalResources can be specified on the command line, use a secondary property -->
<!-- that also encapsulates whether we're a library or not (this makes conditions simpler) -->
<_BundleOriginalResources Condition="'$(OutputType)' == 'Library' And '$(IsAppExtension)' != 'true' And '$(BundleOriginalResources)' == 'true'">true</_BundleOriginalResources>

<EnableProfiling Condition="'$(EnableProfiling)' == '' And '$(_BundlerDebug)' == 'true'">true</EnableProfiling>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this should probably be EnableProfiler instead of EnableProfiling

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ops, fix in progress: #22905

</PropertyGroup>

<PropertyGroup Condition="'$(IsBindingProject)' == 'true'">
Expand Down
Loading