-
Notifications
You must be signed in to change notification settings - Fork 5k
JIT ARM64-SVE: Add simple bitwise ops #101762
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
Merged
Merged
Changes from all commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2919,7 +2919,10 @@ void emitter::emitInsSve_R_R_R(instruction ins, | |
|
||
if (sopt == INS_SCALABLE_OPTS_UNPREDICATED) | ||
{ | ||
assert(opt == INS_OPTS_SCALABLE_D); | ||
// The instruction only has a .D variant. However, this doesn't matter as | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Doing this prevents adding special cases in hwinstrinccodegen. |
||
// it operates on bits not lanes. Effectively this means all standard opt | ||
// sizes are supported. | ||
assert(insOptsScalableStandard(opt)); | ||
assert(isVectorRegister(reg2)); // nnnnn | ||
fmt = IF_SVE_AU_3A; | ||
} | ||
|
@@ -3728,7 +3731,7 @@ void emitter::emitInsSve_R_R_R(instruction ins, | |
else if (sopt == INS_SCALABLE_OPTS_WITH_SIMD_SCALAR) | ||
{ | ||
assert(isFloatReg(reg1)); | ||
assert(isValidVectorElemsize(size)); | ||
assert(isScalableVectorSize(size)); | ||
fmt = IF_SVE_CN_3A; | ||
} | ||
else | ||
|
@@ -3748,7 +3751,7 @@ void emitter::emitInsSve_R_R_R(instruction ins, | |
if (sopt == INS_SCALABLE_OPTS_UNPREDICATED) | ||
{ | ||
assert(ins == INS_sve_mov); | ||
assert(opt == INS_OPTS_SCALABLE_D); | ||
assert(insOptsScalableStandard(opt)); | ||
assert(isVectorRegister(reg1)); // ddddd | ||
assert(isVectorRegister(reg2)); // nnnnn | ||
assert(isVectorRegister(reg3)); // mmmmm | ||
|
@@ -11820,6 +11823,7 @@ BYTE* emitter::emitOutput_InstrSve(BYTE* dst, instrDesc* id) | |
code |= insEncodeSveElemsize(optGetSveElemsize((insOpts)(id->idInsOpt() + 1))); // xx | ||
dst += emitOutput_Instr(dst, code); | ||
break; | ||
|
||
case IF_SVE_BF_2A: // ........xx.xxiii ......nnnnnddddd -- SVE bitwise shift by immediate (unpredicated) | ||
case IF_SVE_FT_2A: // ........xx.xxiii ......nnnnnddddd -- SVE2 bitwise shift and insert | ||
case IF_SVE_FU_2A: // ........xx.xxiii ......nnnnnddddd -- SVE2 bitwise shift right and accumulate | ||
|
@@ -12622,7 +12626,7 @@ void emitter::emitInsSveSanityCheck(instrDesc* id) | |
assert(isVectorRegister(id->idReg1())); // ddddd | ||
assert(isLowPredicateRegister(id->idReg2())); // ggg | ||
assert(isVectorRegister(id->idReg3())); // mmmmm | ||
assert(isValidVectorElemsize(id->idOpSize())); | ||
assert(isScalableVectorSize(id->idOpSize())); | ||
break; | ||
|
||
// Scalable to FP SIMD scalar. | ||
|
@@ -14393,8 +14397,13 @@ void emitter::emitInsSveSanityCheck(instrDesc* id) | |
break; | ||
|
||
case IF_SVE_BJ_2A: // ........xx...... ......nnnnnddddd -- SVE floating-point exponential accelerator | ||
case IF_SVE_CH_2A: // ........xx...... ......nnnnnddddd -- SVE unpack vector elements | ||
case IF_SVE_HF_2A: // ........xx...... ......nnnnnddddd -- SVE floating-point reciprocal estimate (unpredicated) | ||
assert(insOptsScalableAtLeastHalf(id->idInsOpt())); | ||
a74nh marked this conversation as resolved.
Show resolved
Hide resolved
|
||
assert(isVectorRegister(id->idReg1())); | ||
assert(isVectorRegister(id->idReg2())); | ||
break; | ||
|
||
case IF_SVE_CH_2A: // ........xx...... ......nnnnnddddd -- SVE unpack vector elements | ||
assert(insOptsScalableWide(id->idInsOpt())); | ||
assert(isVectorRegister(id->idReg1())); | ||
assert(isVectorRegister(id->idReg2())); | ||
|
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same changes as for
AddAcross
in previous PR - thesize
arg is not used, as the sizes are dependant onopts
.