Commit Graph

927 Commits

Author SHA1 Message Date
Jonas Maebe
61e4a1b811 + added tasmlist parameter to getintparaloc() (needed for llvm)
git-svn-id: trunk@30429 -
2015-04-04 14:29:16 +00:00
Jonas Maebe
201121d7c9 * synchronised with trunk till r30345
git-svn-id: branches/hlcgllvm@30349 -
2015-03-28 12:28:15 +00:00
Jonas Maebe
687bb15299 * renamed getdatalabel() to getglobaldatalabel
git-svn-id: branches/hlcgllvm@30336 -
2015-03-27 21:25:34 +00:00
Jeppe Johansen
fa5bd1c513 ARMv7M supports UMULL.
Fix missing conflicts for multiplication instructions for >=ARMv6.

git-svn-id: trunk@30276 -
2015-03-22 14:39:43 +00:00
Jeppe Johansen
5ca1740bee Fix issue in is_thumb32_imm. imm<11:10> have to be non-zero meaning the rotate only works from 8 to 31. Caused 0x8000001F to be mistaken for a valid immediate.
git-svn-id: trunk@30266 -
2015-03-21 12:46:45 +00:00
Jeppe Johansen
09acd9b1ab Add workaround for ARM thumb when using GAS.
git-svn-id: trunk@30254 -
2015-03-17 21:24:07 +00:00
Jonas Maebe
bd203a5b57 * synchronised with trunk till r30240
git-svn-id: branches/hlcgllvm@30241 -
2015-03-15 19:44:58 +00:00
Jeppe Johansen
f92f0751f4 Fix selection of LDR/STR instructions in thumb mode. Most forms don't support pre or post indexing.
Fix emission of offsets.

git-svn-id: trunk@30234 -
2015-03-15 12:12:13 +00:00
Jonas Maebe
8445381929 * merged ait_set and ait_thumb_set into a single tai class
(tai_symbolpair)

git-svn-id: trunk@30197 -
2015-03-14 18:35:28 +00:00
Jeppe Johansen
52e505bff7 Fixed internal error in GOT related code for ARM internal assembler.
git-svn-id: trunk@30188 -
2015-03-14 16:03:16 +00:00
Jeppe Johansen
439027a8de Add most pre-UAL VFP instruction forms.
Add fused mac instructions for VFPv4.

git-svn-id: trunk@30187 -
2015-03-14 14:59:13 +00:00
Jeppe Johansen
64f127141f Add VFPv4 FPU type for ARM.
Fix assembler reader so it can read instructions longer than 5 characters.

git-svn-id: trunk@30186 -
2015-03-14 12:49:07 +00:00
Jeppe Johansen
73abf5e630 Merge from armiw branch.
Update ARM internal assembler to support most ARM, Thumb and Thumb-2 instructions.
Changed generation of VFP instructions to use UAL mnemonics.
Added divided and unified assembler syntax support to ARM assembly reader.

git-svn-id: trunk@30181 -
2015-03-13 19:22:27 +00:00
Jeppe Johansen
3d7dce81fe Make MRS and MSR use the right encoding on Thumb architectures.
Set regnumber_count_bsstart to 128 to be able to search all registers.

git-svn-id: branches/laksen/armiw@30150 -
2015-03-08 17:30:38 +00:00
Jeppe Johansen
03b9e5117f Fix off by 1 error in assembler reader which prevented B instructions from being parsed.
git-svn-id: branches/laksen/armiw@30147 -
2015-03-08 12:52:43 +00:00
Jeppe Johansen
914e9e7b49 Merged from trunk
git-svn-id: branches/laksen/armiw@30146 -
2015-03-08 12:33:46 +00:00
Jeppe Johansen
d12b913e70 Add initial support in ARM-embedded for Allwinner A20.
git-svn-id: trunk@30144 -
2015-03-08 12:22:57 +00:00
Jonas Maebe
67b8aceaee * synchronized with privatetrunk till r30095
git-svn-id: branches/hlcgllvm@30101 -
2015-03-05 20:32:15 +00:00
Jonas Maebe
b2427d04ed * ensure that data pools are not inserted right after add/tbb/tbh-based
jumptable dispatches

git-svn-id: trunk@30027 -
2015-02-27 20:52:12 +00:00
Jonas Maebe
2ab7f5c35d * moved x86-specific requirements from the generic bsr/bsf code to the
x86 code generator (register size constraints)

git-svn-id: trunk@29984 -
2015-02-23 22:57:18 +00:00
Jonas Maebe
d6de2c03cb * generic part of r26050 from the hlcgllvm branch: made tcgvecnode hlcg-safe
o in particular, add tdef size information to the update_reference*()
     methods, and factored out offset adjustments into its own method
   o also make sure the passed size to update_reference*() corresponds to the
     actual size of the index, as it's no longer guaranteed to be ptruint
     since the previous commit

git-svn-id: trunk@29967 -
2015-02-23 22:56:00 +00:00
Jonas Maebe
3fe0bd065e * ARM assembler reader: don't check for postfixes beyond the length
of the opcode

git-svn-id: trunk@29823 -
2015-02-23 22:47:56 +00:00
florian
9eab90d8c4 * always pass the architecture to the arm assembler
* encode pld/ldrd in arm.inc using .long, so it causes no errors with older architectures settings of the assembler

git-svn-id: trunk@29780 -
2015-02-21 21:58:30 +00:00
florian
80cc09e350 o fix wince compilation:
* apparently, wince (or GNU AS for it) does not support blx imm
  * set FPC_IN_SYSTEM directive, so assembler code in divide.inc is compiled right

git-svn-id: trunk@29779 -
2015-02-21 21:55:56 +00:00
Jeppe Johansen
47dbec3111 Rebase to trunk revision
git-svn-id: branches/laksen/armiw@29708 -
2015-02-15 16:08:18 +00:00
Jeppe Johansen
60b3ea8038 Use proper syntax when emitting UAL VFP instructions for all postfix types.
Fixed postfix of VSQRT instruction.

git-svn-id: branches/laksen/armiw@29591 -
2015-02-01 09:38:45 +00:00
sergei
9cc0bdd6b9 + Missing part of internal ARM assembler, Mantis #26588. I'm not setting it as default for arm-wince yet, because testing reveals several points in generic code that need adjustments.
git-svn-id: trunk@29588 -
2015-01-30 22:45:05 +00:00
sergei
472310d83f * ARM: Fixed interface wrapper generation after r28542 for targets without BX instruction.
git-svn-id: trunk@29580 -
2015-01-30 15:00:28 +00:00
Jeppe Johansen
db401f0371 Add missing size postfix to VNEG VFP instruction.
git-svn-id: branches/laksen/armiw@29436 -
2015-01-11 13:40:35 +00:00
Jeppe Johansen
2ac11e4b82 Use proper relocation type for Thumb-2 BLX.
Initialize MM register allocator properly for Thumb-2 cg.

git-svn-id: branches/laksen/armiw@29435 -
2015-01-11 13:30:52 +00:00
Jeppe Johansen
572076fc4d Add MSR/MRS for ARMv6M/7M.
Fix bug in FPA LFM/SFM.
Add usermode handling of LDM/STM.

git-svn-id: branches/laksen/armiw@29371 -
2015-01-02 13:24:03 +00:00
Jeppe Johansen
7390acc426 Merged from recent trunk.
git-svn-id: branches/laksen/armiw@29369 -
2015-01-01 23:54:40 +00:00
Jeppe Johansen
f963ff1b5b Add CPSxx instructions, and some missing FPA instructions.
git-svn-id: branches/laksen/armiw@29368 -
2015-01-01 21:17:21 +00:00
Jeppe Johansen
ff7af306df Add FPA support.
git-svn-id: branches/laksen/armiw@29366 -
2015-01-01 11:18:04 +00:00
Jeppe Johansen
49346b3041 Fix SWI as a pseudo instruction.
Add VFPv2/3 instruction entries for Thumb2.

git-svn-id: branches/laksen/armiw@29356 -
2014-12-29 11:34:34 +00:00
Jeppe Johansen
cbd75428c0 Fix an issue with local BLX branches not being turned into BL branches.
git-svn-id: branches/laksen/armiw@29355 -
2014-12-28 23:27:30 +00:00
Jeppe Johansen
9a482d5281 Refactor and secure some immediate operand encodings.
Add some system mode entries, udiv/sdiv in arm mode, and fix bugs in ldrh/strh.

git-svn-id: branches/laksen/armiw@29353 -
2014-12-28 21:41:06 +00:00
Jeppe Johansen
e7575d9f96 Fix some encoding bugs in ARM modes. Mostly shifts and signindex errors.
Add FPU mask checking for instructions too.

git-svn-id: branches/laksen/armiw@29352 -
2014-12-28 16:16:54 +00:00
Jeppe Johansen
97fdfc942b Fix encoding of shifterops for ARM dataprocessing instructions.
git-svn-id: branches/laksen/armiw@29348 -
2014-12-28 00:13:06 +00:00
Jeppe Johansen
c284d8f6ba Fix some warnings about unitialized variables.
git-svn-id: branches/laksen/armiw@29346 -
2014-12-27 23:11:54 +00:00
Jeppe Johansen
3ad03491ed Add Neg as a pseudo instruction, and fix RRX pseudo code expansion.
Split some of the thumb code emission rules to make it easier to specify short-cut notations.

git-svn-id: branches/laksen/armiw@29345 -
2014-12-27 17:44:30 +00:00
Jeppe Johansen
6fff181679 Add support for TBB/TBH instructions.
Precisize rules for selection of thumb instructions.
Add short-cut notation support for most simple Thumb2 instructions ( add r1,#4 instead of add r1,r1,#4 ).

git-svn-id: branches/laksen/armiw@29343 -
2014-12-27 16:00:06 +00:00
Jeppe Johansen
71cdedea82 Add missing NOP, and B instruction forms.
Move ThumbFunc flag from section to symbol.
Make .w forms optional the other way around. If .w is explicitly put on an instruction the assembler should always chose a wide form.

git-svn-id: branches/laksen/armiw@29341 -
2014-12-27 13:23:02 +00:00
Jeppe Johansen
cc418eef74 Added unified assembler syntax mode so it can be selected with $ASMMODE.
Fixed bug in Mov instruction.
Added initial scanning of IT/LastInIT detection for proper instruction selection.
Disabled "wide" format flag detection again for now.

git-svn-id: branches/laksen/armiw@29338 -
2014-12-27 00:19:09 +00:00
Jeppe Johansen
6976af8365 Change .thumb_func to be an ait_directive instead of it's own tai type.
git-svn-id: branches/laksen/armiw@29334 -
2014-12-26 23:13:14 +00:00
Jeppe Johansen
9683102813 BL/BLX in thumb mode is a long composed instruction in Thumb as well as Thumb2
git-svn-id: branches/laksen/armiw@29333 -
2014-12-26 23:10:34 +00:00
Jeppe Johansen
9227a9fcf2 Reenable check for Wide format flag.
git-svn-id: branches/laksen/armiw@29331 -
2014-12-26 20:08:07 +00:00
Jeppe Johansen
5c3093a937 Add most non-VFP Thumb-2 instruction entries for the ARM internal writer.
git-svn-id: branches/laksen/armiw@29329 -
2014-12-26 18:35:15 +00:00
Jeppe Johansen
3cb9b30165 Added full 16-bit Thumb support to the ARM internal writer.
git-svn-id: branches/laksen/armiw@29326 -
2014-12-25 19:33:14 +00:00
Jeppe Johansen
0494f48bfc Fix capability matrix for ARMv5. It should not have thumb support.
git-svn-id: branches/laksen/armiw@29287 -
2014-12-14 16:49:28 +00:00