Skip to content

Commit

Permalink
[mono][s390x] Fix wrong implementation of OP_CHECK_THIS (#76916)
Browse files Browse the repository at this point in the history
* Only access a single byte in memory for OP_CHECK_THIS

* Remove unnecessary ltgr instruction

* Fixes #76915
  • Loading branch information
uweigand authored Oct 12, 2022
1 parent c6c8bb8 commit 4850c88
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/mono/mono/mini/mini-s390x.c
Original file line number Diff line number Diff line change
Expand Up @@ -3594,8 +3594,7 @@ mono_arch_output_basic_block (MonoCompile *cfg, MonoBasicBlock *bb)
break;
case OP_CHECK_THIS: {
/* ensure ins->sreg1 is not NULL */
s390_lg (code, s390_r0, 0, ins->sreg1, 0);
s390_ltgr (code, s390_r0, s390_r0);
s390_llgc (code, s390_r0, 0, ins->sreg1, 0);
}
break;
case OP_ARGLIST: {
Expand Down

0 comments on commit 4850c88

Please sign in to comment.