Commit 3f4585c
authored
Treat System.Runtime.CompilerServices.Unsafe as intrinsic (#68739)
* Treat System.Runtime.CompilerServices.Unsafe as intrinsic
* Remove duplicated logic from Get_CORINFO_SIG_INFO
* Don't create a multiply node if the size is 1
* Remove unnecessary impBashVarAddrsToI calls over gtNewIconNode
* Use `#ifdef TARGET_64BIT` rather than `#if (REGSIZE_BYTES == 8)`
* Don't unnecessarily call `genActualType(TYP_U_IMPL)`, just use `TYP_I_IMPL` directly
* Only insert casts for `TYP_INT` to `TYP_I_IMPL` or `TYP_U_IMPL` on 64-bit
* Have Unsafe.SkipInit create a `GT_NO_OP` node
* Have Unsafe.Subtract and Unsafe.SubtractByteOffset be intrinsic
* Adding a couple `CLANG_FORMAT_COMMENT_ANCHOR;` to comments that precede an `#ifdef`
* Applying formatting patch
* Revert "Have Unsafe.Subtract and Unsafe.SubtractByteOffset be intrinsic"
This reverts commit 2301adc.
* Fixing the operand evaluation order for NI_SRCS_UNSAFE_Add
* Fixing the operand evaluation order for NI_SRCS_UNSAFE_ByteOffset
* Implement NI_SRCS_UNSAFE_SubtractByteOffset
* Fix the build failure
* Ensure impImplicitIorI4Cast is called on op2 for NI_SRCS_UNSAFE_Add
* Don't declare a `tmp` in NI_SRCS_UNSAFE_Add to make the logic clearer
* Have NI_SRCS_UNSAFE_SkipInit return gtNewNothingNode
* Handle side effects for NI_SRCS_UNSAFE_SkipInit
* Revert "Implement NI_SRCS_UNSAFE_SubtractByteOffset"
This reverts commit 7166b2e.
* Manually simplify some of the NI_SRCS_* import logic
* Ensure NI_SRCS_SkipInit returns the unused node when its side-effecting
* Remove unnecessary comment anchors
* Applying formatting patch
* Try to workaround the JIT issue by spilling op1/op2 for Unsafe.Add
* Apply formatting patch
* Revert "Try to workaround the JIT issue by spilling op1/op2 for Unsafe.Add"
* Have Unsafe.Subtract and Unsafe.SubtractByteOffset be intrinsic
This reverts commit 982660e.1 parent 5975649 commit 3f4585c
File tree
3 files changed
+577
-22
lines changed- src/coreclr/jit
3 files changed
+577
-22
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3685 | 3685 | | |
3686 | 3686 | | |
3687 | 3687 | | |
| 3688 | + | |
| 3689 | + | |
| 3690 | + | |
| 3691 | + | |
| 3692 | + | |
3688 | 3693 | | |
3689 | 3694 | | |
3690 | 3695 | | |
| |||
3968 | 3973 | | |
3969 | 3974 | | |
3970 | 3975 | | |
| 3976 | + | |
3971 | 3977 | | |
3972 | 3978 | | |
3973 | 3979 | | |
| |||
0 commit comments