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
aarch64: error: inline assembly requires more registers than available #702
Comments
Looks like gcc also fails with -O0 here: from https://github.com/libunwind/libunwind/actions/runs/7543438232/job/20534462217
clang fails with all -O{0,2,3}.. it can only handle 14 registers in input operands at a time. Keeping any 14 in libunwind/src/aarch64/Gos-linux.c Lines 70 to 94 in b603e63
@bregma, this is a build regression in v1.8.0. Given the limitations of both clang and gcc, it seems like we have three options:
|
I'm hitting this error, so won't be able to upgrade to v1.8 til its resolved. Does anyone have a patch for this? |
I reverted #503 in dotnet/runtime to fix it like this: dotnet/runtime@ |
Hit similar issue when compile Libunwind with Clang-14.0.6 on Aarch64 (graviton) Amazon Linux 2. Here is the exact compilation command that fails:
|
This issue is tagged for 1.9.0. Would be great to get a fix as a patch in 1.8 series. Same issue as #742 |
) Context: #8800 Context: 8bc7a3e Context: 6836818 Context: libunwind/libunwind#702 Begin adding native method call tracing infrastructure based on [libunwind][0], initially used in tracing the reasons for why [Blazor][1] apps break when LLVM marshal methods are enabled (8bc7a3e, 6836818). The utility of such infrastructure, however, is beyond just that particular task; it should be available for general use by both us and applications. Method call tracing support is not enabled by default. To enable it, set the `$(_AndroidEnableNativeStackTracing)` MSBuild property to `true`. This will enable the ability to print native, managed and Java stack traces by invoking the `monodroid_log_traces` function from either managed or native application code. Additionally, change the directory layout for native code. Previously, `src/monodroid` would produce *five* native libs: * `libmono-android.debug.so` * `libmono-android.release.so` * `libxa-internal-api.so` * `libxamarin-app.so` * `libxamarin-debug-app-helper.so` This made for a large `src/monodroid/CMakeLists.txt`, complicating maintenance. We had considered trying to move these into separate `src/LIBRARY-NAME` directories, but it makes things easier with CMake if we introduce an intermediate directory. Introduce a new `src/native` directory, to hold native binaries: * `src/native/monodroid`: new location for `libmono-android.*.so` * `src/native/xamarin-debug-app-helper`: source for `libxamarin-debug-app-helper.so`, containing code moved from previous `src/monodroid` * `src/native/xamarin-app-stub`: source for the "stub" `libxamarin-app.so`; the "real" one is produced in the app build. Some `src/native/*` directories produce libraries (`.so` files). and some produce *static* archives (`.a` files) to simplify using code across native libraries. A [cmake-presets file][2] is processed by `xaprepare`, to create a `src/native/CMakePresets.json` which contains all the version-specific bits replacements such as Android API levels, paths to utilities etc. Developers can create a `src/native/CMakeUserPresets.json` file to provide local modifications to config options within `src/native/CMakePresets.json.in`. Other changes: * `src/native/libunwind/fixes/aarch64/Gos-linux.c` is an altered copy of [`libunwind/src/aarch64/Gos-linux.c`][3] in order to workaround libunwind/libunwind#702. * *Begin* turning some instance member functions into static member functions, as we don't otherwise need instances of those classes. * Begin using `std::source_location` for better crash messages, instead of using `__FILE__` and `__LINE__`. * Fix endless recursion from a typo in `Util::ends_with()` overload. [0]: https://github.com/libunwind/libunwind [1]: https://learn.microsoft.com/aspnet/core/blazor/hybrid/tutorials/maui?view=aspnetcore-8.0 [2]: https://cmake.org/cmake/help/latest/manual/cmake-presets.7.html [3]: https://github.com/libunwind/libunwind/blob/9cc4d98b22ae57bc1d8c253988feb85d4298a634/src/aarch64/Gos-linux.c
Hm, clang has a different error:
Originally posted by @sfc-gh-sgiesecke in #608 (comment)
Hitting the same issue in dotnet-runtime, where arm64 legs are cross-compiled using clang.
The text was updated successfully, but these errors were encountered: