Skip to content

[ARM32] illegal instruction when run dotnet to create a console project #33344

Closed
@oldzhu

Description

@oldzhu

dotnet --info

.NET Core SDK (reflecting any global.json):
Version: 5.0.100-preview.2.20155.8
Commit: 12b7ebfb89

Runtime Environment:
OS Name: buildroot
OS Version: 2020.02-rc3
OS Platform: Linux
RID: linux-arm
Base Path: /root/dotnet/sdk/5.0.100-preview.2.20155.8/

Host (useful for support):
Version: 5.0.0-preview.2.20155.1
Commit: e2881ae

.NET Core SDKs installed:
5.0.100-preview.2.20155.8 [/root/dotnet/sdk]

.NET Core runtimes installed:
Microsoft.AspNetCore.App 5.0.0-preview.2.20155.1 [/root/dotnet/shared/Microsoft.AspNetCore.App]
Microsoft.NETCore.App 5.0.0-preview.2.20155.1 [/root/dotnet/shared/Microsoft.NETCore.App]
...

The gdb debugging log:
..
(gdb) r
Starting program: /root/dotnet/dotnet new console --output sample1
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/libthread_db.so.1".
[New Thread 0x763cd440 (LWP 232)]
[New Thread 0x75bcc440 (LWP 233)]
...
[New Thread 0x6b9ef440 (LWP 244)]
[Thread 0x6b9ef440 (LWP 244) exited]

Thread 1 "dotnet" received signal SIGILL, Illegal instruction.
0x6fad85e6 in ?? ()
(gdb) disas /rs $pc-10,+20
Dump of assembler code from 0x6fad85dc to 0x6fad85f0:
0x6fad85dc: 04 2b cmp r3, #4
0x6fad85de: 51 f8 04 2b ldr.w r2, [r1], #4
0x6fad85e2: 40 f8 04 2b str.w r2, [r0], #4
=> 0x6fad85e6: bd e8 00 40 ldmia.w sp!, {lr}
0x6fad85ea: 03 b0 add sp, #12
0x6fad85ec: 70 47 bx lr
bt 0x6fad85ee: 00 00 movs r0, r0
End of assembler dump.

(gdb) si
Fatal error. System.Runtime.InteropServices.SEHException (0x80004005): External component has thrown an exception.
[Thread 0x6ec31440 (LWP 240) exited]
at System.Memory1[[System.Byte, System.Private.CoreLib, Version=5.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].op_Implicit(System.Memory1)
at System.Security.Cryptography.Asn1.AsnWriter.WriteEncodedValue(System.ReadOnlySpan`1)
at Internal.Cryptography.Pal.X500NameEncoder.X500DistinguishedNameEncode(System.String, System.Security.Cryptography.X509Certificates.X500DistinguishedNameFlags)
at Internal.Cryptography.Pal.OpenSslX509Encoder.X500DistinguishedNameEncode(System.String, System.Security.Cryptography.X509Certificates.X500DistinguishedNameFlags)
at System.Security.Cryptography.X509Certificates.X500DistinguishedName.Encode(System.String, System.Security.Cryptography.X509Certificates.X500DistinguishedNameFlags)
at System.Security.Cryptography.X509Certificates.X500DistinguishedName..ctor(System.String)
at Microsoft.AspNetCore.Certificates.Generation.CertificateManager.CreateAspNetCoreHttpsDevelopmentCertificate(System.DateTimeOffset, System.DateTimeOffset, System.String, DiagnosticInformation)
at Microsoft.AspNetCore.Certificates.Generation.CertificateManager.EnsureValidCertificateExists(System.DateTimeOffset, System.DateTimeOffset, Microsoft.AspNetCore.Certificates.Generation.CertificatePurpose, System.String, Boolean, Boolean, System.String, System.String)
at Microsoft.AspNetCore.DeveloperCertificates.XPlat.CertificateGenerator.GenerateAspNetHttpsCertificate()
at Microsoft.DotNet.Cli.AspNetCoreCertificateGenerator.GenerateAspNetCoreDevelopmentCertificate()
at Microsoft.DotNet.Configurer.DotnetFirstTimeUseConfigurer.Configure()
at Microsoft.DotNet.Cli.Program.ConfigureDotNetForFirstTimeUse(Microsoft.DotNet.Configurer.IFirstTimeUseNoticeSentinel, Microsoft.DotNet.Configurer.IAspNetCertificateSentinel, Microsoft.DotNet.Configurer.IFileSentinel, Boolean, Microsoft.DotNet.Configurer.DotnetFirstRunConfiguration, Microsoft.DotNet.Cli.Utils.IEnvironmentProvider)
at Microsoft.DotNet.Cli.Program.ProcessArgs(System.String[], Microsoft.DotNet.Cli.Telemetry.ITelemetry)
at Microsoft.DotNet.Cli.Program.Main(System.String[])

Thread 1 "dotnet" received signal SIGABRT, Aborted.
0x76ca539c in raise () from /lib/libc.so.6

(gdb) bt
#0 0x76ca539c in raise () from /lib/libc.so.6
#1 0x76c8f3c4 in abort () from /lib/libc.so.6
#2 0x7683c704 in PROCAbort ()
from /root/dotnet/shared/Microsoft.NETCore.App/5.0.0-preview.2.20155.1/libcoreclr.so
#3 0x7683c620 in PROCEndProcess(void*, unsigned int, int) ()
from /root/dotnet/shared/Microsoft.NETCore.App/5.0.0-preview.2.20155.1/libcoreclr.so
#4 0x7661e6a2 in SafeExitProcess(unsigned int, int, ShutdownCompleteAction) ()
from /root/dotnet/shared/Microsoft.NETCore.App/5.0.0-preview.2.20155.1/libcoreclr.so
#5 0x7661f3a0 in EEPolicy::HandleFatalError(unsigned int, unsigned int, char16_t const*, _EXCEPTION_POINTERS*, char16_t const*, char16_t const*) ()
from /root/dotnet/shared/Microsoft.NETCore.App/5.0.0-preview.2.20155.1/libcoreclr.so
#6 0x7668cd3c in ProcessCLRException ()
from /root/dotnet/shared/Microsoft.NETCore.App/5.0.0-preview.2.20155.1/libcoreclr.so
#7 0x7669046e in UnwindManagedExceptionPass1(PAL_SEHException&, _CONTEXT*) ()
from /root/dotnet/shared/Microsoft.NETCore.App/5.0.0-preview.2.20155.1/libcoreclr.so
#8 0x76690620 in DispatchManagedException(PAL_SEHException&, bool) ()
from /root/dotnet/shared/Microsoft.NETCore.App/5.0.0-preview.2.20155.1/libcor--Type for more, q to quit, c to continue without paging--
eclr.so
#9 0x7668c110 in HandleHardwareException(PAL_SEHException*) ()
from /root/dotnet/shared/Microsoft.NETCore.App/5.0.0-preview.2.20155.1/libcoreclr.so
#10 0x76818578 in SEHProcessException(PAL_SEHException*) ()
from /root/dotnet/shared/Microsoft.NETCore.App/5.0.0-preview.2.20155.1/libcoreclr.so
#11 0x76819702 in common_signal_handler(int, siginfo_t*, void*, int, ...) ()
from /root/dotnet/shared/Microsoft.NETCore.App/5.0.0-preview.2.20155.1/libcoreclr.so
#12 0x76818f8a in sigill_handler(int, siginfo_t*, void*) ()
from /root/dotnet/shared/Microsoft.NETCore.App/5.0.0-preview.2.20155.1/libcoreclr.so
#13
#14 0x6fad85e6 in ?? ()
#15 0x6fad85d6 in ?? ()

category:correctness
theme:emitter
skill-level:beginner
cost:small

Metadata

Metadata

Assignees

Labels

arch-arm32area-CodeGen-coreclrCLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMIbug

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions