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

Arm/Arm64 cross builds failing #4502

Closed
mmitche opened this issue Sep 16, 2015 · 6 comments · Fixed by dotnet/coreclr#1575
Closed

Arm/Arm64 cross builds failing #4502

mmitche opened this issue Sep 16, 2015 · 6 comments · Fixed by dotnet/coreclr#1575
Assignees

Comments

@mmitche
Copy link
Member

mmitche commented Sep 16, 2015

As of:

http://dotnet-ci.cloudapp.net/job/dotnet_coreclr_arm64_linux_debug/29/

Changes in that build:

Changes 1.Add link to .NET Core Roadmap (commit: 2c65582) (detail)
2.Use Frame list context when GetThreadContext is unavailable (commit: eb3260e) (detail)
3.Use out-of-proc libunwind to unwind native stack from DAC (commit: d0f71d0) (detail)

Error:

In file included from /mnt/j/workspace/dotnet_coreclr_arm64_linux_debug/src/pal/src/exception/seh.cpp:282:
/mnt/j/workspace/dotnet_coreclr_arm64_linux_debug/src/pal/src/exception/seh-unwind.cpp:494:5: error: use of undeclared identifier 'WinContextToUnwindContext'; did you mean 'WinContextToUnwindCursor'?
WinContextToUnwindContext(context, &unwContext);
^~~~~~~~~~~~~~~~~~~~~~~~~
WinContextToUnwindCursor
/mnt/j/workspace/dotnet_coreclr_arm64_linux_debug/src/pal/src/exception/seh-unwind.cpp:88:13: note: 'WinContextToUnwindCursor' declared here
static void WinContextToUnwindCursor(CONTEXT *winContext, unw_cursor_t *cursor)
^
/mnt/j/workspace/dotnet_coreclr_arm64_linux_debug/src/pal/src/exception/seh-unwind.cpp:494:40: error: cannot initialize a parameter of type 'unw_cursor_t *' (aka 'unw_cursor *') with an rvalue of type 'unw_context_t *' (aka 'unw_tdep_context *')
WinContextToUnwindContext(context, &unwContext);
^~~~~~~~~~~
/mnt/j/workspace/dotnet_coreclr_arm64_linux_debug/src/pal/src/exception/seh-unwind.cpp:88:73: note: passing argument to parameter 'cursor' here
static void WinContextToUnwindCursor(CONTEXT *winContext, unw_cursor_t *cursor)

@mmitche
Copy link
Member Author

mmitche commented Sep 16, 2015

/cc @benpye

@benpye
Copy link
Contributor

benpye commented Sep 16, 2015

@mmitche Working on fixing the build break, however I believe arm64 shouldn't be broken. It appears the arm64 build is actually also building the arm files:

Using rootfs in /opt/arm-liux-genueabihf-root
+ ROOTFS_DIR=/opt/arm-liux-genueabihf-root ./build.sh skipmscorlib arm cross verbose debug

@mmitche
Copy link
Member Author

mmitche commented Sep 16, 2015

@benpye Agh...how did that happen. Changed.

@benpye
Copy link
Contributor

benpye commented Sep 16, 2015

After I believe I have fixed the first error I am hitting the assert at https://github.com/dotnet/coreclr/blob/master/src/debug/inc/dbgipcevents.h#L2355 . I guess this is a cause of the conversion from MAX_PATH somewhere along the line, I have modified it to the smallest value that will pass the assertion and therefor I assume is large enough. I'll let this build finish and run PAL tests, then send a PR. I won't really be able to test the seh-exception change as I don't think a PAL test was introduced with the new method.

@mmitche
Copy link
Member Author

mmitche commented Sep 16, 2015

Different error on arm64:

In file included from /mnt/j/workspace/dotnet_coreclr_arm64_linux_debug/src/pal/src/exception/seh.cpp:282:
/mnt/j/workspace/dotnet_coreclr_arm64_linux_debug/src/pal/src/exception/seh-unwind.cpp:398:14: error: duplicate case value: 'UNW_REG_IP' and 'UNW_AARCH64_X30' both equal '30'
case UNW_AARCH64_X30: *valp = (unw_word_t) winContext->Lr; break;
^
/mnt/j/workspace/dotnet_coreclr_arm64_linux_debug/src/pal/src/exception/seh-unwind.cpp:395:14: note: previous case defined here
case UNW_REG_IP: *valp = (unw_word_t) winContext->Pc; break;
^
1 error generated.

@benpye
Copy link
Contributor

benpye commented Sep 16, 2015

I've disabled that code for non AMD64 platforms for now since it seems like it's only called from the AMD64 VM. Something I would like @kangaroo to look at though, libunwind lies on both ARM and ARM64 about the registers it's using, in this case, it uses LR for both IP and LR as per https://github.com/fdoray/libunwind/blob/master/include/libunwind-aarch64.h hence it has two of the same case. I already use the exact registers on ARM to avoid this, maybe this should be done for ARM64 too?

@msftgits msftgits transferred this issue from dotnet/coreclr Jan 30, 2020
@ghost ghost locked as resolved and limited conversation to collaborators Jan 5, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants