Commit Graph

32 Commits

Author SHA1 Message Date
florian
a6921fff7b + Aarch64: SxthSxtw2Sxth optimization 2022-01-20 22:15:14 +01:00
Florian Klämpfl
a47f153dae * avoid to create a stack frame on aarch64 if possible 2021-11-02 22:23:24 +01:00
Jonas Maebe
c745ae4836 AArch64 popt: don't replace registers with X/WZR
Most arithmetic/logica instructions don't support X/WZR as operand (since
you should use movk with the calculated constant in that case)

Resolves #39372
2021-10-04 20:58:05 +02:00
florian
2e8c99947a * define DEBUG_AOPTCPU if EXTDEBUG is used 2021-10-03 18:40:20 +02:00
florian
5762e687a3 * (modified) patch by J. Gareth Moreton: ARM/AArch64 Some short-range LDR/STR optimisations, last part of #38841 2021-09-12 20:11:14 +02:00
florian
40e1a09e6c * improved AndUtxh2And optimization
git-svn-id: trunk@49483 -
2021-06-05 21:14:30 +00:00
pierre
9bad5180bb Avoid using UXT and SXT instructions on arm version below 6
git-svn-id: trunk@49340 -
2021-05-06 16:17:16 +00:00
florian
d936280c6b * (modified) patch by J. Gareth Moreton to unify ldr/str optimizations on Aarch64/ARM, part of #38841
git-svn-id: trunk@49338 -
2021-05-05 20:38:05 +00:00
florian
7a3eb453d4 * arm/aarch64: patch by J. Gareth Moreton: fix register allocation information for Mov2None 2, should resolve #38055
git-svn-id: trunk@48235 -
2021-01-20 21:14:09 +00:00
florian
d4ad618a70 * similiar fix to r48167 for OptPass1SXTH
git-svn-id: trunk@48168 -
2021-01-17 19:01:14 +00:00
florian
14ddc59edb * arm*: fix SxtbAndImm2Sxtb (now SxtbAndImm2Uxtb) optimization as proposed by Pierre and Gareth
git-svn-id: trunk@48167 -
2021-01-17 10:12:55 +00:00
florian
1014e53081 * patch by J. Gareth Moreton: fixes crash on ARM with -CriotR, resolves #38116
git-svn-id: trunk@47531 -
2020-11-22 19:47:34 +00:00
florian
eadcaa5dfc * Arm Thumb does not support complex references including SP, resolves #38056
git-svn-id: trunk@47380 -
2020-11-10 22:04:55 +00:00
florian
6ec460c619 * patch by J. Gareth Moreton: MOV/LDR/STR/MOV optimisations for ARM/AArch64, resolves #37638
git-svn-id: trunk@47330 -
2020-11-06 21:41:59 +00:00
pierre
3f19bd693f + Add new LastCommonAsmOp constant to arm and aarch64 CPU targets.
* Uses this new constant to define TCommonAsmOps set type.
  + Use this constant in armgen/aoptarm MatchInstruction function,
    to avoid a range check error when compiling with -CriotR with optimization.

git-svn-id: trunk@47137 -
2020-10-19 09:19:25 +00:00
Jonas Maebe
9376f5a43a * AArch64: added SIMD instructions (only plain ARMv8-A for now)
o added AArch64 regset parsing support in assembler reader, means that "{"
     no longer starts comments there (like in the ARM assembler reader)
   o added AArch64 indexed SIMD register support and removed old cg hacks
     that worked around its absence

git-svn-id: trunk@47116 -
2020-10-15 20:29:36 +00:00
florian
bb92fbafa0 patch by J. Gareth Moreton: GetNextInstructionUsingReg drops out earlier, second part of #37526
git-svn-id: trunk@46976 -
2020-09-27 21:05:43 +00:00
florian
eec51afadd * patch (with little modification) by J. Gareth Moreton: refactor ARM/Aarch64 peephole optimizer, first part of #37526
git-svn-id: trunk@46975 -
2020-09-27 21:05:42 +00:00
florian
0b5c50ea41 * Aarch64: set register size correctly for AndStrb2Strb optimization, resolves #37427
git-svn-id: trunk@45872 -
2020-07-28 20:46:05 +00:00
pierre
ec3fe2f990 Fix overflow when value is high(int64) in OptPass1And method
git-svn-id: trunk@45734 -
2020-07-06 13:50:10 +00:00
florian
33094d263f * Aarch: handle 0 in AndAnd2And and check if the resulting constant
is really a shifter constant, resolves #37203

git-svn-id: trunk@45651 -
2020-06-14 14:16:49 +00:00
florian
c5d7e6807c * ARM: factor out TARMAsmOptimizer.OptPass1And
git-svn-id: trunk@45536 -
2020-05-30 20:44:19 +00:00
florian
db19900eb1 * TARMAsmOptimizer.RemoveSuperfluousMove should not mess with PC
git-svn-id: trunk@44842 -
2020-04-19 11:04:31 +00:00
florian
099faf2d2b * factored out and improved TARMAsmOptimizer.RedundantMovProcess
+ AArch64: use TARMAsmOptimizer.RedundantMovProcess

git-svn-id: trunk@44799 -
2020-04-18 21:48:25 +00:00
florian
9176efbab4 * factored out TARMAsmOptimizer.OptPass1SXTH
* AArch64: use TARMAsmOptimizer.OptPass1SXTH

git-svn-id: trunk@44739 -
2020-04-16 21:19:14 +00:00
florian
19a9d4c4ac * factored out TARMAsmOptimizer.OptPass1SXTB
* AArch64: use TARMAsmOptimizer.OptPass1SXTB

git-svn-id: trunk@44738 -
2020-04-16 21:19:13 +00:00
florian
7172397077 * factored out TARMAsmOptimizer.OptPass1UXTH
* AArch64: use TARMAsmOptimizer.OptPass1UXTH

git-svn-id: trunk@44737 -
2020-04-16 21:19:12 +00:00
florian
9bcff94e9e * factored out TARMAsmOptimizer.OptPass1UXTB
* several other routines being very similar for ARM and AAarch64 moved to aoptarm

git-svn-id: trunk@44725 -
2020-04-15 20:21:29 +00:00
florian
2276caae24 + common assembler optimizer base class for arm and aarch64
git-svn-id: trunk@44720 -
2020-04-13 21:01:01 +00:00
Jonas Maebe
1a9e246c29 * added is_normal_fieldvarsym() helper and use it
o fixes several places where there was a check whether something is a
     fieldvarsym, but not whether it's an instance rather than a class field

git-svn-id: trunk@43786 -
2019-12-24 22:12:44 +00:00
pierre
828a248287 Systematically include fpcdefs.inc at sart of all units used by compiler
git-svn-id: trunk@42322 -
2019-07-03 13:35:05 +00:00
Jonas Maebe
1a559f5c60 * move the homogenous float aggregate determination function to a common
unit for ARM and AArch64

git-svn-id: trunk@41419 -
2019-02-23 15:42:39 +00:00