-
Notifications
You must be signed in to change notification settings - Fork 200
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[NativeAOT-LLVM] Add WasmExternalDwarf property to create an external_debug_info section #2786
base: feature/NativeAOT-LLVM
Are you sure you want to change the base?
Changes from 3 commits
804111f
dd84ce5
e8fd31f
27e99ef
b12b969
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -100,6 +100,7 @@ The .NET Foundation licenses this file to you under the MIT license. | |
|
||
<NativeObject>$(NativeIntermediateOutputPath)$(TargetName)$(NativeObjectExt)</NativeObject> | ||
<NativeBinary Condition="'$(NativeBinary)' == ''">$(NativeOutputPath)$(TargetName)$(NativeBinaryExt)</NativeBinary> | ||
<WasmBinary Condition="'$(_targetArchitecture)' == 'wasm'">$(NativeOutputPath)$(TargetName).wasm</WasmBinary> | ||
yowl marked this conversation as resolved.
Show resolved
Hide resolved
|
||
<IlcExportUnmanagedEntrypoints Condition="'$(IlcExportUnmanagedEntrypoints)' == '' and '$(NativeLib)' == 'Shared'">true</IlcExportUnmanagedEntrypoints> | ||
<ExportsFile Condition="$(ExportsFile) == '' and '$(BuildingFrameworkLibrary)' != 'true'">$(NativeIntermediateOutputPath)$(TargetName)$(ExportsFileExt)</ExportsFile> | ||
|
||
|
@@ -390,9 +391,11 @@ The .NET Foundation licenses this file to you under the MIT license. | |
<ItemGroup> | ||
<LlvmObjects Include="@(_IlcProducedFiles)" Condition="'%(Extension)' == '$(LlvmObjectExt)'"> | ||
<NativeObject>%(RelativeDir)%(Filename)$(NativeObjectExt)</NativeObject> | ||
<DwarfObject>"%(RelativeDir)%(Filename).dwo"</DwarfObject> | ||
</LlvmObjects> | ||
<NativeObjects Include="@(_IlcProducedFiles)" Condition="'%(Extension)' == '$(NativeObjectExt)'" /> | ||
<NativeObjects Include="@(LlvmObjects->'%(NativeObject)')" /> | ||
<DwarfObjects Include="@(LlvmObjects->'%(DwarfObject)')" /> | ||
yowl marked this conversation as resolved.
Show resolved
Hide resolved
|
||
</ItemGroup> | ||
</Target> | ||
|
||
|
@@ -444,7 +447,7 @@ The .NET Foundation licenses this file to you under the MIT license. | |
<PropertyGroup Condition="'$(_targetOS)' == 'wasi'"> | ||
<WasmCompilerPath>"$(WASI_SDK_PATH)/bin/clang++"</WasmCompilerPath> | ||
<WasmLinkerPath>"$(WASI_SDK_PATH)/bin/clang"</WasmLinkerPath> | ||
</PropertyGroup> | ||
</PropertyGroup> | ||
|
||
<!-- Invoke the compilers in parallel. --> | ||
<ItemGroup> | ||
|
@@ -537,6 +540,7 @@ The .NET Foundation licenses this file to you under the MIT license. | |
|
||
<PropertyGroup> | ||
<IlcIsLibLikeApp Condition="'$(IlcIsLibLikeApp)' == '' and ('$(NativeLib)' != '' or '$(CustomNativeMain)' != '')">true</IlcIsLibLikeApp> | ||
<WasmSymbolFile>$([System.IO.Path]::ChangeExtension('$(NativeBinary)', '.debug.wasm'))</WasmSymbolFile> | ||
</PropertyGroup> | ||
|
||
<ItemGroup Condition="'$(InvariantGlobalization)' != 'true'"> | ||
|
@@ -587,6 +591,7 @@ The .NET Foundation licenses this file to you under the MIT license. | |
<CustomLinkerArg Include="-s TOTAL_STACK=$(IlcWasmStackSize)" /> | ||
<CustomLinkerArg Condition="'$(WasmEnableJSBigIntIntegration)' == 'true'" Include="-s WASM_BIGINT=1" /> | ||
<CustomLinkerArg Condition="'$(IlcLlvmExceptionHandlingModel)' == 'cpp'" Include="-s DISABLE_EXCEPTION_CATCHING=0" /> | ||
<CustomLinkerArg Condition="'$(StripSymbols)' == 'true'" Include="-gseparate-dwarf="$(WasmSymbolFile)"" /> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Actually, testing what this property does, this in fact the correct way to use it. Using an absolute path results in the relative path, and using a relative path result in something that is relative to the current working directory. Tricky but workable. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Not sure I follow the outcome of the comment here. It is ok as is? I think it was working when I tested it. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Yes. |
||
|
||
<CustomLinkerArg Include="$(EmccFlags)" /> | ||
<CustomLinkerArg Include="-s MAXIMUM_MEMORY=$(EmccMaximumHeapSize)" Condition="'$(EmccMaximumHeapSize)' != ''" /> | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should happen for
DotNetJsApi
as well and check whether the.debug.wasm
file is present to copy, ideally using$(WasmSymbolFile)
.