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

Treat System.Runtime.CompilerServices.Unsafe as intrinsic #68739

Merged
merged 30 commits into from
May 12, 2022
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
b30794d
Treat System.Runtime.CompilerServices.Unsafe as intrinsic
tannergooding May 1, 2022
a9bc307
Remove duplicated logic from Get_CORINFO_SIG_INFO
tannergooding May 1, 2022
3e3c839
Don't create a multiply node if the size is 1
tannergooding May 1, 2022
9e84bdd
Remove unnecessary impBashVarAddrsToI calls over gtNewIconNode
tannergooding May 1, 2022
4d42990
Use `#ifdef TARGET_64BIT` rather than `#if (REGSIZE_BYTES == 8)`
tannergooding May 1, 2022
201217e
Don't unnecessarily call `genActualType(TYP_U_IMPL)`, just use `TYP_I…
tannergooding May 1, 2022
1bf3f3a
Only insert casts for `TYP_INT` to `TYP_I_IMPL` or `TYP_U_IMPL` on 64…
tannergooding May 1, 2022
6963037
Have Unsafe.SkipInit create a `GT_NO_OP` node
tannergooding May 1, 2022
2301adc
Have Unsafe.Subtract and Unsafe.SubtractByteOffset be intrinsic
tannergooding May 1, 2022
3c4f660
Adding a couple `CLANG_FORMAT_COMMENT_ANCHOR;` to comments that prece…
tannergooding May 1, 2022
4d91472
Applying formatting patch
tannergooding May 1, 2022
982660e
Revert "Have Unsafe.Subtract and Unsafe.SubtractByteOffset be intrinsic"
tannergooding May 1, 2022
a933fec
Fixing the operand evaluation order for NI_SRCS_UNSAFE_Add
tannergooding May 2, 2022
fff8ddc
Fixing the operand evaluation order for NI_SRCS_UNSAFE_ByteOffset
tannergooding May 2, 2022
7166b2e
Implement NI_SRCS_UNSAFE_SubtractByteOffset
tannergooding May 2, 2022
4e3303a
Fix the build failure
tannergooding May 2, 2022
66de257
Ensure impImplicitIorI4Cast is called on op2 for NI_SRCS_UNSAFE_Add
tannergooding May 2, 2022
e491b78
Don't declare a `tmp` in NI_SRCS_UNSAFE_Add to make the logic clearer
tannergooding May 2, 2022
b3e6e3c
Have NI_SRCS_UNSAFE_SkipInit return gtNewNothingNode
tannergooding May 2, 2022
0b372a5
Handle side effects for NI_SRCS_UNSAFE_SkipInit
tannergooding May 2, 2022
3e2a2ae
Revert "Implement NI_SRCS_UNSAFE_SubtractByteOffset"
tannergooding May 2, 2022
ab91385
Manually simplify some of the NI_SRCS_* import logic
tannergooding May 2, 2022
f8dd74d
Ensure NI_SRCS_SkipInit returns the unused node when its side-effecting
tannergooding May 2, 2022
77b9af1
Remove unnecessary comment anchors
tannergooding May 2, 2022
d7b4783
Applying formatting patch
tannergooding May 2, 2022
0c07847
Try to workaround the JIT issue by spilling op1/op2 for Unsafe.Add
tannergooding May 3, 2022
272bce2
Apply formatting patch
tannergooding May 3, 2022
8c964f1
Merge remote-tracking branch 'dotnet/main' into unsafe-intrinsics
tannergooding May 5, 2022
79c717b
Revert "Try to workaround the JIT issue by spilling op1/op2 for Unsaf…
tannergooding May 5, 2022
e573dd8
Have Unsafe.Subtract and Unsafe.SubtractByteOffset be intrinsic
tannergooding May 5, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions src/coreclr/jit/compiler.h
Original file line number Diff line number Diff line change
Expand Up @@ -3677,6 +3677,11 @@ class Compiler
CORINFO_SIG_INFO* sig,
bool mustExpand);

GenTree* impSRCSUnsafeIntrinsic(NamedIntrinsic intrinsic,
CORINFO_CLASS_HANDLE clsHnd,
CORINFO_METHOD_HANDLE method,
CORINFO_SIG_INFO* sig);

#ifdef FEATURE_HW_INTRINSICS
GenTree* impHWIntrinsic(NamedIntrinsic intrinsic,
CORINFO_CLASS_HANDLE clsHnd,
Expand Down
Loading