InstEmitAlu32.cs 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757
  1. using ARMeilleure.Decoders;
  2. using ARMeilleure.IntermediateRepresentation;
  3. using ARMeilleure.State;
  4. using ARMeilleure.Translation;
  5. using static ARMeilleure.Instructions.InstEmitAluHelper;
  6. using static ARMeilleure.Instructions.InstEmitHelper;
  7. using static ARMeilleure.IntermediateRepresentation.OperandHelper;
  8. namespace ARMeilleure.Instructions
  9. {
  10. static partial class InstEmit32
  11. {
  12. public static void Add(ArmEmitterContext context)
  13. {
  14. IOpCode32Alu op = (IOpCode32Alu)context.CurrOp;
  15. Operand n = GetAluN(context);
  16. Operand m = GetAluM(context, setCarry: false);
  17. Operand res = context.Add(n, m);
  18. if (op.SetFlags)
  19. {
  20. EmitNZFlagsCheck(context, res);
  21. EmitAddsCCheck(context, n, res);
  22. EmitAddsVCheck(context, n, m, res);
  23. }
  24. EmitAluStore(context, res);
  25. }
  26. public static void Adc(ArmEmitterContext context)
  27. {
  28. IOpCode32Alu op = (IOpCode32Alu)context.CurrOp;
  29. Operand n = GetAluN(context);
  30. Operand m = GetAluM(context, setCarry: false);
  31. Operand res = context.Add(n, m);
  32. Operand carry = GetFlag(PState.CFlag);
  33. res = context.Add(res, carry);
  34. if (op.SetFlags)
  35. {
  36. EmitNZFlagsCheck(context, res);
  37. EmitAdcsCCheck(context, n, res);
  38. EmitAddsVCheck(context, n, m, res);
  39. }
  40. EmitAluStore(context, res);
  41. }
  42. public static void And(ArmEmitterContext context)
  43. {
  44. IOpCode32Alu op = (IOpCode32Alu)context.CurrOp;
  45. Operand n = GetAluN(context);
  46. Operand m = GetAluM(context);
  47. Operand res = context.BitwiseAnd(n, m);
  48. if (op.SetFlags)
  49. {
  50. EmitNZFlagsCheck(context, res);
  51. }
  52. EmitAluStore(context, res);
  53. }
  54. public static void Bfc(ArmEmitterContext context)
  55. {
  56. OpCode32AluBf op = (OpCode32AluBf)context.CurrOp;
  57. Operand d = GetIntA32(context, op.Rd);
  58. Operand res = context.BitwiseAnd(d, Const(~op.DestMask));
  59. SetIntA32(context, op.Rd, res);
  60. }
  61. public static void Bfi(ArmEmitterContext context)
  62. {
  63. OpCode32AluBf op = (OpCode32AluBf)context.CurrOp;
  64. Operand n = GetIntA32(context, op.Rn);
  65. Operand d = GetIntA32(context, op.Rd);
  66. Operand part = context.BitwiseAnd(n, Const(op.SourceMask));
  67. if (op.Lsb != 0)
  68. {
  69. part = context.ShiftLeft(part, Const(op.Lsb));
  70. }
  71. Operand res = context.BitwiseAnd(d, Const(~op.DestMask));
  72. res = context.BitwiseOr(res, context.BitwiseAnd(part, Const(op.DestMask)));
  73. SetIntA32(context, op.Rd, res);
  74. }
  75. public static void Bic(ArmEmitterContext context)
  76. {
  77. IOpCode32Alu op = (IOpCode32Alu)context.CurrOp;
  78. Operand n = GetAluN(context);
  79. Operand m = GetAluM(context);
  80. Operand res = context.BitwiseAnd(n, context.BitwiseNot(m));
  81. if (op.SetFlags)
  82. {
  83. EmitNZFlagsCheck(context, res);
  84. }
  85. EmitAluStore(context, res);
  86. }
  87. public static void Clz(ArmEmitterContext context)
  88. {
  89. Operand m = GetAluM(context, setCarry: false);
  90. Operand res = context.CountLeadingZeros(m);
  91. EmitAluStore(context, res);
  92. }
  93. public static void Cmp(ArmEmitterContext context)
  94. {
  95. Operand n = GetAluN(context);
  96. Operand m = GetAluM(context, setCarry: false);
  97. Operand res = context.Subtract(n, m);
  98. EmitNZFlagsCheck(context, res);
  99. EmitSubsCCheck(context, n, res);
  100. EmitSubsVCheck(context, n, m, res);
  101. }
  102. public static void Cmn(ArmEmitterContext context)
  103. {
  104. Operand n = GetAluN(context);
  105. Operand m = GetAluM(context, setCarry: false);
  106. Operand res = context.Add(n, m);
  107. EmitNZFlagsCheck(context, res);
  108. EmitAddsCCheck(context, n, res);
  109. EmitAddsVCheck(context, n, m, res);
  110. }
  111. public static void Eor(ArmEmitterContext context)
  112. {
  113. IOpCode32Alu op = (IOpCode32Alu)context.CurrOp;
  114. Operand n = GetAluN(context);
  115. Operand m = GetAluM(context);
  116. Operand res = context.BitwiseExclusiveOr(n, m);
  117. if (op.SetFlags)
  118. {
  119. EmitNZFlagsCheck(context, res);
  120. }
  121. EmitAluStore(context, res);
  122. }
  123. public static void Mov(ArmEmitterContext context)
  124. {
  125. IOpCode32Alu op = (IOpCode32Alu)context.CurrOp;
  126. Operand m = GetAluM(context);
  127. if (op.SetFlags)
  128. {
  129. EmitNZFlagsCheck(context, m);
  130. }
  131. EmitAluStore(context, m);
  132. }
  133. public static void Movt(ArmEmitterContext context)
  134. {
  135. OpCode32AluImm16 op = (OpCode32AluImm16)context.CurrOp;
  136. Operand d = GetIntA32(context, op.Rd);
  137. Operand imm = Const(op.Immediate << 16); // Immeditate value as top halfword.
  138. Operand res = context.BitwiseAnd(d, Const(0x0000ffff));
  139. res = context.BitwiseOr(res, imm);
  140. EmitAluStore(context, res);
  141. }
  142. public static void Mul(ArmEmitterContext context)
  143. {
  144. IOpCode32Alu op = (IOpCode32Alu)context.CurrOp;
  145. Operand n = GetAluN(context);
  146. Operand m = GetAluM(context);
  147. Operand res = context.Multiply(n, m);
  148. if (op.SetFlags)
  149. {
  150. EmitNZFlagsCheck(context, res);
  151. }
  152. EmitAluStore(context, res);
  153. }
  154. public static void Mvn(ArmEmitterContext context)
  155. {
  156. IOpCode32Alu op = (IOpCode32Alu)context.CurrOp;
  157. Operand m = GetAluM(context);
  158. Operand res = context.BitwiseNot(m);
  159. if (op.SetFlags)
  160. {
  161. EmitNZFlagsCheck(context, res);
  162. }
  163. EmitAluStore(context, res);
  164. }
  165. public static void Orr(ArmEmitterContext context)
  166. {
  167. IOpCode32Alu op = (IOpCode32Alu)context.CurrOp;
  168. Operand n = GetAluN(context);
  169. Operand m = GetAluM(context);
  170. Operand res = context.BitwiseOr(n, m);
  171. if (op.SetFlags)
  172. {
  173. EmitNZFlagsCheck(context, res);
  174. }
  175. EmitAluStore(context, res);
  176. }
  177. public static void Pkh(ArmEmitterContext context)
  178. {
  179. OpCode32AluRsImm op = (OpCode32AluRsImm)context.CurrOp;
  180. Operand n = GetAluN(context);
  181. Operand m = GetAluM(context);
  182. Operand res;
  183. bool tbform = op.ShiftType == ShiftType.Asr;
  184. if (tbform)
  185. {
  186. res = context.BitwiseOr(context.BitwiseAnd(n, Const(0xFFFF0000)), context.BitwiseAnd(m, Const(0xFFFF)));
  187. }
  188. else
  189. {
  190. res = context.BitwiseOr(context.BitwiseAnd(m, Const(0xFFFF0000)), context.BitwiseAnd(n, Const(0xFFFF)));
  191. }
  192. EmitAluStore(context, res);
  193. }
  194. public static void Rbit(ArmEmitterContext context)
  195. {
  196. Operand m = GetAluM(context);
  197. Operand res = EmitReverseBits32Op(context, m);
  198. EmitAluStore(context, res);
  199. }
  200. public static void Rev(ArmEmitterContext context)
  201. {
  202. Operand m = GetAluM(context);
  203. Operand res = context.ByteSwap(m);
  204. EmitAluStore(context, res);
  205. }
  206. public static void Rev16(ArmEmitterContext context)
  207. {
  208. Operand m = GetAluM(context);
  209. Operand res = EmitReverseBytes16_32Op(context, m);
  210. EmitAluStore(context, res);
  211. }
  212. public static void Revsh(ArmEmitterContext context)
  213. {
  214. Operand m = GetAluM(context);
  215. Operand res = EmitReverseBytes16_32Op(context, m);
  216. EmitAluStore(context, context.SignExtend16(OperandType.I32, res));
  217. }
  218. public static void Rsc(ArmEmitterContext context)
  219. {
  220. IOpCode32Alu op = (IOpCode32Alu)context.CurrOp;
  221. Operand n = GetAluN(context);
  222. Operand m = GetAluM(context, setCarry: false);
  223. Operand res = context.Subtract(m, n);
  224. Operand borrow = context.BitwiseExclusiveOr(GetFlag(PState.CFlag), Const(1));
  225. res = context.Subtract(res, borrow);
  226. if (op.SetFlags)
  227. {
  228. EmitNZFlagsCheck(context, res);
  229. EmitSbcsCCheck(context, m, n);
  230. EmitSubsVCheck(context, m, n, res);
  231. }
  232. EmitAluStore(context, res);
  233. }
  234. public static void Rsb(ArmEmitterContext context)
  235. {
  236. IOpCode32Alu op = (IOpCode32Alu)context.CurrOp;
  237. Operand n = GetAluN(context);
  238. Operand m = GetAluM(context, setCarry: false);
  239. Operand res = context.Subtract(m, n);
  240. if (op.SetFlags)
  241. {
  242. EmitNZFlagsCheck(context, res);
  243. EmitSubsCCheck(context, m, res);
  244. EmitSubsVCheck(context, m, n, res);
  245. }
  246. EmitAluStore(context, res);
  247. }
  248. public static void Sbc(ArmEmitterContext context)
  249. {
  250. IOpCode32Alu op = (IOpCode32Alu)context.CurrOp;
  251. Operand n = GetAluN(context);
  252. Operand m = GetAluM(context, setCarry: false);
  253. Operand res = context.Subtract(n, m);
  254. Operand borrow = context.BitwiseExclusiveOr(GetFlag(PState.CFlag), Const(1));
  255. res = context.Subtract(res, borrow);
  256. if (op.SetFlags)
  257. {
  258. EmitNZFlagsCheck(context, res);
  259. EmitSbcsCCheck(context, n, m);
  260. EmitSubsVCheck(context, n, m, res);
  261. }
  262. EmitAluStore(context, res);
  263. }
  264. public static void Sbfx(ArmEmitterContext context)
  265. {
  266. OpCode32AluBf op = (OpCode32AluBf)context.CurrOp;
  267. var msb = op.Lsb + op.Msb; // For this instruction, the msb is actually a width.
  268. Operand n = GetIntA32(context, op.Rn);
  269. Operand res = context.ShiftRightSI(context.ShiftLeft(n, Const(31 - msb)), Const(31 - op.Msb));
  270. SetIntA32(context, op.Rd, res);
  271. }
  272. public static void Sdiv(ArmEmitterContext context)
  273. {
  274. EmitDiv(context, false);
  275. }
  276. public static void Ssat(ArmEmitterContext context)
  277. {
  278. OpCode32Sat op = (OpCode32Sat)context.CurrOp;
  279. EmitSat(context, -(1 << op.SatImm), (1 << op.SatImm) - 1);
  280. }
  281. public static void Ssat16(ArmEmitterContext context)
  282. {
  283. OpCode32Sat16 op = (OpCode32Sat16)context.CurrOp;
  284. EmitSat16(context, -(1 << op.SatImm), (1 << op.SatImm) - 1);
  285. }
  286. public static void Sub(ArmEmitterContext context)
  287. {
  288. IOpCode32Alu op = (IOpCode32Alu)context.CurrOp;
  289. Operand n = GetAluN(context);
  290. Operand m = GetAluM(context, setCarry: false);
  291. Operand res = context.Subtract(n, m);
  292. if (op.SetFlags)
  293. {
  294. EmitNZFlagsCheck(context, res);
  295. EmitSubsCCheck(context, n, res);
  296. EmitSubsVCheck(context, n, m, res);
  297. }
  298. EmitAluStore(context, res);
  299. }
  300. public static void Sxtb(ArmEmitterContext context)
  301. {
  302. EmitSignExtend(context, true, 8);
  303. }
  304. public static void Sxtb16(ArmEmitterContext context)
  305. {
  306. EmitExtend16(context, true);
  307. }
  308. public static void Sxth(ArmEmitterContext context)
  309. {
  310. EmitSignExtend(context, true, 16);
  311. }
  312. public static void Teq(ArmEmitterContext context)
  313. {
  314. Operand n = GetAluN(context);
  315. Operand m = GetAluM(context);
  316. Operand res = context.BitwiseExclusiveOr(n, m);
  317. EmitNZFlagsCheck(context, res);
  318. }
  319. public static void Tst(ArmEmitterContext context)
  320. {
  321. Operand n = GetAluN(context);
  322. Operand m = GetAluM(context);
  323. Operand res = context.BitwiseAnd(n, m);
  324. EmitNZFlagsCheck(context, res);
  325. }
  326. public static void Ubfx(ArmEmitterContext context)
  327. {
  328. OpCode32AluBf op = (OpCode32AluBf)context.CurrOp;
  329. var msb = op.Lsb + op.Msb; // For this instruction, the msb is actually a width.
  330. Operand n = GetIntA32(context, op.Rn);
  331. Operand res = context.ShiftRightUI(context.ShiftLeft(n, Const(31 - msb)), Const(31 - op.Msb));
  332. SetIntA32(context, op.Rd, res);
  333. }
  334. public static void Udiv(ArmEmitterContext context)
  335. {
  336. EmitDiv(context, true);
  337. }
  338. public static void Usat(ArmEmitterContext context)
  339. {
  340. OpCode32Sat op = (OpCode32Sat)context.CurrOp;
  341. EmitSat(context, 0, op.SatImm == 32 ? (int)(~0) : (1 << op.SatImm) - 1);
  342. }
  343. public static void Usat16(ArmEmitterContext context)
  344. {
  345. OpCode32Sat16 op = (OpCode32Sat16)context.CurrOp;
  346. EmitSat16(context, 0, (1 << op.SatImm) - 1);
  347. }
  348. public static void Uxtb(ArmEmitterContext context)
  349. {
  350. EmitSignExtend(context, false, 8);
  351. }
  352. public static void Uxtb16(ArmEmitterContext context)
  353. {
  354. EmitExtend16(context, false);
  355. }
  356. public static void Uxth(ArmEmitterContext context)
  357. {
  358. EmitSignExtend(context, false, 16);
  359. }
  360. private static void EmitSignExtend(ArmEmitterContext context, bool signed, int bits)
  361. {
  362. IOpCode32AluUx op = (IOpCode32AluUx)context.CurrOp;
  363. Operand m = GetAluM(context);
  364. Operand res;
  365. if (op.RotateBits == 0)
  366. {
  367. res = m;
  368. }
  369. else
  370. {
  371. Operand rotate = Const(op.RotateBits);
  372. res = context.RotateRight(m, rotate);
  373. }
  374. switch (bits)
  375. {
  376. case 8:
  377. res = (signed) ? context.SignExtend8(OperandType.I32, res) : context.ZeroExtend8(OperandType.I32, res);
  378. break;
  379. case 16:
  380. res = (signed) ? context.SignExtend16(OperandType.I32, res) : context.ZeroExtend16(OperandType.I32, res);
  381. break;
  382. }
  383. if (op.Add)
  384. {
  385. res = context.Add(res, GetAluN(context));
  386. }
  387. EmitAluStore(context, res);
  388. }
  389. private static void EmitExtend16(ArmEmitterContext context, bool signed)
  390. {
  391. IOpCode32AluUx op = (IOpCode32AluUx)context.CurrOp;
  392. Operand m = GetAluM(context);
  393. Operand res;
  394. if (op.RotateBits == 0)
  395. {
  396. res = m;
  397. }
  398. else
  399. {
  400. Operand rotate = Const(op.RotateBits);
  401. res = context.RotateRight(m, rotate);
  402. }
  403. Operand low16, high16;
  404. if (signed)
  405. {
  406. low16 = context.SignExtend8(OperandType.I32, res);
  407. high16 = context.SignExtend8(OperandType.I32, context.ShiftRightUI(res, Const(16)));
  408. }
  409. else
  410. {
  411. low16 = context.ZeroExtend8(OperandType.I32, res);
  412. high16 = context.ZeroExtend8(OperandType.I32, context.ShiftRightUI(res, Const(16)));
  413. }
  414. if (op.Add)
  415. {
  416. Operand n = GetAluN(context);
  417. Operand lowAdd, highAdd;
  418. if (signed)
  419. {
  420. lowAdd = context.SignExtend16(OperandType.I32, n);
  421. highAdd = context.SignExtend16(OperandType.I32, context.ShiftRightUI(n, Const(16)));
  422. }
  423. else
  424. {
  425. lowAdd = context.ZeroExtend16(OperandType.I32, n);
  426. highAdd = context.ZeroExtend16(OperandType.I32, context.ShiftRightUI(n, Const(16)));
  427. }
  428. low16 = context.Add(low16, lowAdd);
  429. high16 = context.Add(high16, highAdd);
  430. }
  431. res = context.BitwiseOr(
  432. context.ZeroExtend16(OperandType.I32, low16),
  433. context.ShiftLeft(context.ZeroExtend16(OperandType.I32, high16), Const(16)));
  434. EmitAluStore(context, res);
  435. }
  436. private static void EmitDiv(ArmEmitterContext context, bool unsigned)
  437. {
  438. Operand n = GetAluN(context);
  439. Operand m = GetAluM(context);
  440. Operand zero = Const(m.Type, 0);
  441. Operand divisorIsZero = context.ICompareEqual(m, zero);
  442. Operand lblBadDiv = Label();
  443. Operand lblEnd = Label();
  444. context.BranchIfTrue(lblBadDiv, divisorIsZero);
  445. if (!unsigned)
  446. {
  447. // ARM64 behaviour: If Rn == INT_MIN && Rm == -1, Rd = INT_MIN (overflow).
  448. // TODO: tests to ensure A32 works the same
  449. Operand intMin = Const(int.MinValue);
  450. Operand minus1 = Const(-1);
  451. Operand nIsIntMin = context.ICompareEqual(n, intMin);
  452. Operand mIsMinus1 = context.ICompareEqual(m, minus1);
  453. Operand lblGoodDiv = Label();
  454. context.BranchIfFalse(lblGoodDiv, context.BitwiseAnd(nIsIntMin, mIsMinus1));
  455. EmitAluStore(context, intMin);
  456. context.Branch(lblEnd);
  457. context.MarkLabel(lblGoodDiv);
  458. }
  459. Operand res = unsigned
  460. ? context.DivideUI(n, m)
  461. : context.Divide(n, m);
  462. EmitAluStore(context, res);
  463. context.Branch(lblEnd);
  464. context.MarkLabel(lblBadDiv);
  465. EmitAluStore(context, zero);
  466. context.MarkLabel(lblEnd);
  467. }
  468. private static void EmitSat(ArmEmitterContext context, int intMin, int intMax)
  469. {
  470. OpCode32Sat op = (OpCode32Sat)context.CurrOp;
  471. Operand n = GetIntA32(context, op.Rn);
  472. int shift = DecodeImmShift(op.ShiftType, op.Imm5);
  473. switch (op.ShiftType)
  474. {
  475. case ShiftType.Lsl:
  476. if (shift == 32)
  477. {
  478. n = Const(0);
  479. }
  480. else
  481. {
  482. n = context.ShiftLeft(n, Const(shift));
  483. }
  484. break;
  485. case ShiftType.Asr:
  486. if (shift == 32)
  487. {
  488. n = context.ShiftRightSI(n, Const(31));
  489. }
  490. else
  491. {
  492. n = context.ShiftRightSI(n, Const(shift));
  493. }
  494. break;
  495. }
  496. Operand lblCheckLtIntMin = Label();
  497. Operand lblNoSat = Label();
  498. Operand lblEnd = Label();
  499. context.BranchIfFalse(lblCheckLtIntMin, context.ICompareGreater(n, Const(intMax)));
  500. SetFlag(context, PState.QFlag, Const(1));
  501. SetIntA32(context, op.Rd, Const(intMax));
  502. context.Branch(lblEnd);
  503. context.MarkLabel(lblCheckLtIntMin);
  504. context.BranchIfFalse(lblNoSat, context.ICompareLess(n, Const(intMin)));
  505. SetFlag(context, PState.QFlag, Const(1));
  506. SetIntA32(context, op.Rd, Const(intMin));
  507. context.Branch(lblEnd);
  508. context.MarkLabel(lblNoSat);
  509. SetIntA32(context, op.Rd, n);
  510. context.MarkLabel(lblEnd);
  511. }
  512. private static void EmitSat16(ArmEmitterContext context, int intMin, int intMax)
  513. {
  514. OpCode32Sat16 op = (OpCode32Sat16)context.CurrOp;
  515. void SetD(int part, Operand value)
  516. {
  517. if (part == 0)
  518. {
  519. SetIntA32(context, op.Rd, context.ZeroExtend16(OperandType.I32, value));
  520. }
  521. else
  522. {
  523. SetIntA32(context, op.Rd, context.BitwiseOr(GetIntA32(context, op.Rd), context.ShiftLeft(value, Const(16))));
  524. }
  525. }
  526. Operand n = GetIntA32(context, op.Rn);
  527. Operand nLow = context.SignExtend16(OperandType.I32, n);
  528. Operand nHigh = context.ShiftRightSI(n, Const(16));
  529. for (int part = 0; part < 2; part++)
  530. {
  531. Operand nPart = part == 0 ? nLow : nHigh;
  532. Operand lblCheckLtIntMin = Label();
  533. Operand lblNoSat = Label();
  534. Operand lblEnd = Label();
  535. context.BranchIfFalse(lblCheckLtIntMin, context.ICompareGreater(nPart, Const(intMax)));
  536. SetFlag(context, PState.QFlag, Const(1));
  537. SetD(part, Const(intMax));
  538. context.Branch(lblEnd);
  539. context.MarkLabel(lblCheckLtIntMin);
  540. context.BranchIfFalse(lblNoSat, context.ICompareLess(nPart, Const(intMin)));
  541. SetFlag(context, PState.QFlag, Const(1));
  542. SetD(part, Const(intMin));
  543. context.Branch(lblEnd);
  544. context.MarkLabel(lblNoSat);
  545. SetD(part, nPart);
  546. context.MarkLabel(lblEnd);
  547. }
  548. }
  549. private static void EmitAluStore(ArmEmitterContext context, Operand value)
  550. {
  551. IOpCode32Alu op = (IOpCode32Alu)context.CurrOp;
  552. EmitGenericAluStoreA32(context, op.Rd, op.SetFlags, value);
  553. }
  554. }
  555. }