Skip to content
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

Two more fixes for crossgen2 #538

Merged
merged 2 commits into from
Dec 5, 2019
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
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ public override ObjectData GetData(NodeFactory factory, bool relocsOnly = false)
for (int methodIndex = 0; methodIndex < _methods.Count; methodIndex++)
{
IMethodNode methodNode = _methods[methodIndex];
if (methodNode == null || (methodNode is MethodWithGCInfo methodWithGCInfo && methodWithGCInfo.IsEmpty))
if (methodNode == null || (methodNode is LocalMethodImport localMethod && localMethod.MethodCodeNode.IsEmpty))
{
// Flush an empty GC ref map block to prevent
// the indexed records from falling out of sync with methods
Expand Down
4 changes: 2 additions & 2 deletions src/coreclr/tests/src/CLRTest.CrossGen.targets
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ if [ ! -z ${RunCrossGen2+x} ]%3B then
mkdir IL
cp $(MSBuildProjectName).dll IL/$(MSBuildProjectName).dll
mv $(MSBuildProjectName).dll $(MSBuildProjectName).org
__Command=$_DebuggerFullPath "$CORE_ROOT/crossgen2/crossgen2" -r:$CORE_ROOT/*.dll --targetarch=x64 -O --inputbubble -o:$(scriptPath)$(MSBuildProjectName).dll $(scriptPath)$(MSBuildProjectName).org
__Command=$_DebuggerFullPath "$CORE_ROOT/crossgen2/crossgen2" -r:$CORE_ROOT/*.dll -r:$PWD/*.dll --targetarch=x64 -O --inputbubble -o:$(scriptPath)$(MSBuildProjectName).dll $(scriptPath)$(MSBuildProjectName).org
echo $__Command
$__Command
__cg2ExitCode=$?
Expand Down Expand Up @@ -130,7 +130,7 @@ if defined RunCrossGen2 (
mkdir IL
copy $(MSBuildProjectName).dll IL\$(MSBuildProjectName).dll
ren $(MSBuildProjectName).dll $(MSBuildProjectName).org
set __Command=!_DebuggerFullPath! "!CORE_ROOT!\crossgen2\crossgen2" %21scriptPath%21$(MSBuildProjectName).org -o:%21scriptPath%21$(MSBuildProjectName).dll --targetarch:x64 -O --inputbubble -r:!CORE_ROOT!\*.dll
set __Command=!_DebuggerFullPath! "!CORE_ROOT!\crossgen2\crossgen2" %21scriptPath%21$(MSBuildProjectName).org -o:%21scriptPath%21$(MSBuildProjectName).dll --targetarch:x64 -O --inputbubble -r:!CORE_ROOT!\*.dll -r:%25cd%25\*.dll
echo "!__Command!"
call !__Command!
set CrossGen2Status=!ERRORLEVEL!
Expand Down