-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Labels
Milestone
Description
Compile the following program and run:
static unsafe void Main(string[] args)
{
Unsafe.InitBlock(null, 0, 1000);
}CoreCLR:
Unhandled exception. System.NullReferenceException: Object reference not set to an instance of an object.
NativeAOT:
no exception, exits.
I assume this is what these comments mean:
runtime/src/coreclr/tools/aot/ILCompiler.Compiler/Compiler/JitHelper.cs
Lines 118 to 123 in 3e55167
| case ReadyToRunHelper.MemCpy: | |
| mangledName = "memcpy"; // TODO: Null reference handling | |
| break; | |
| case ReadyToRunHelper.MemSet: | |
| mangledName = "memset"; // TODO: Null reference handling | |
| break; |
so I decided to file a tracking issue.
(while CoreCLR wraps memset/memcpy calls into non-inlineable/without tail calls helpers)
Metadata
Metadata
Assignees
Labels
Type
Projects
Status
No status