Commit Graph

56 Commits

Author SHA1 Message Date
florian
637976e83f * patch by Marģers to unify internal error numbers, resolves #37888
git-svn-id: trunk@47103 -
2020-10-13 19:59:01 +00:00
florian
28f25b2df0 * reworked usage of tcgnotnode.handle_locjump
git-svn-id: trunk@46275 -
2020-08-05 21:15:32 +00:00
Károly Balogh
660432685a m68k: review and some cleanup of the shlshrnode, also add a special case for shifting 64bit values by 1
git-svn-id: trunk@34757 -
2016-10-23 16:46:34 +00:00
Károly Balogh
77318be022 m68k: fix build errors with some assemblers on modulo calculation on 020+
git-svn-id: trunk@33867 -
2016-06-01 10:50:22 +00:00
Károly Balogh
b4fd85f19c m68k: unaligned handling for math and typeconv nodes
git-svn-id: trunk@33854 -
2016-05-29 18:48:24 +00:00
Károly Balogh
a2a630e9c5 m68k: fixed and enabled hardware mod/div support for coldfire, also it no longer depends on cpu family but cpu capability
git-svn-id: trunk@33821 -
2016-05-26 16:54:39 +00:00
Károly Balogh
6706445cb4 m68k: enable hardware divisions for all '020+, not only 020 itself
git-svn-id: trunk@33810 -
2016-05-26 10:38:08 +00:00
Károly Balogh
aa63aa95bb m68k: a bunch of '000 related fixes and cleanups. generated source now compiles for '000 again, which was broken due to recent improvements conflicting with limitations of the original '000
git-svn-id: trunk@33809 -
2016-05-26 10:33:29 +00:00
Károly Balogh
92b2cf917d m68k: when saving/restoring FPU registers, use the right FPU register size on ColdFire to calculate the stored size
git-svn-id: trunk@33614 -
2016-05-02 14:18:30 +00:00
Károly Balogh
bd564b8933 m68k: some code to support the ColdFire v4e FPU. not functional yet.
git-svn-id: trunk@33533 -
2016-04-18 03:25:32 +00:00
Károly Balogh
4e964c2ed7 m68k: rewrote fixref and a_load_ref_ref, fixing a bunch of problems on ColdFire, unifying and simplifying the code a lot, and hopefully not killing anything in the process
git-svn-id: trunk@33446 -
2016-04-08 03:27:19 +00:00
Károly Balogh
5f66d63335 m68k: disabled comment generation
git-svn-id: trunk@30045 -
2015-03-01 15:49:57 +00:00
Károly Balogh
997ec578e0 m68k: added a simple unaryminusnode which can utilize FNEG instruction for floats on 68881
git-svn-id: trunk@30044 -
2015-03-01 15:00:07 +00:00
sergei
01c8ee158d - removed unused variables
git-svn-id: trunk@28282 -
2014-07-31 18:35:55 +00:00
sergei
0262514939 * m68k: Transform 32-bit div/mod nodes into helper calls during pass 1. This is consistent with the way other targets do it, and results in pretty much nicer code.
git-svn-id: trunk@28098 -
2014-06-28 13:28:01 +00:00
sergei
85c0ba96e2 * tm68knotnode brought up to speed:
- removed code for everything but booleans (it is handled perfectly well by generic code)
 + operate directly on references when possible
 + added handling for 64-bit data.

git-svn-id: trunk@28096 -
2014-06-28 05:14:27 +00:00
Károly Balogh
1e65caa37a fixed the 68020 codepath for emit_div/mod
git-svn-id: trunk@27081 -
2014-03-10 18:01:53 +00:00
Károly Balogh
875a7418b3 disable broken 68020 codepath and fall back to generic until it gets fixed
git-svn-id: trunk@27070 -
2014-03-10 01:36:05 +00:00
Károly Balogh
db49a169cb handle more locations in tm68knotnode, fixes several tests failing to compile with 200203223
git-svn-id: trunk@25746 -
2013-10-11 02:51:23 +00:00
svenbarth
f8fe25f8cf Forgot to commit one location where address registers need to be allocated.
m68k/n68kmat.pas, tm68kmoddivnode.call_rtl_divmod_reg_reg:
  * (de)allocate address registers

git-svn-id: trunk@25653 -
2013-10-05 17:50:12 +00:00
svenbarth
741992bae4 m68k/n68kmat.pas, tm68kshlshrnode.first_shlshr64bitint:
use RTL helper functions (through the inherited method) if we're not shifting by a constant

This fixes test/cg/tshlshr

git-svn-id: trunk@23378 -
2013-01-13 19:33:23 +00:00
Jonas Maebe
69c29a415f * pass the procdef to getintparaloc instead of only the proccalloption, so
that the type of the parameters can be determined automatically
   o added compilerproc declarations for all helpers called in the compiler
     via their assembler name, so we can look up the corresponding procdef

git-svn-id: trunk@23325 -
2013-01-06 15:05:40 +00:00
svenbarth
772072d8c9 m68k/n68kmat.pas, tm68kmoddivnode:
+ add routine "call_rtl_moddiv_reg_reg" which handles the calling of "fpc_div_longint", "fpc_div_dword", "fpc_mod_longint" and "fpc_mod_dword"
  * emit_mod_reg_reg & emit_div_reg_reg: use the new method instead of doing the call oneself

=> "Str(SomeInt, SomeStr)" and "Writeln(SomeInt)" now works

git-svn-id: trunk@22893 -
2012-10-31 21:27:05 +00:00
svenbarth
7ffd6c61a1 m68k/n68kmat.pas, tm68knotnode.pass_generate_code:
* correctly handle the case "expectloc = LOC_JUMP"
  * make internal error unique

git-svn-id: trunk@22790 -
2012-10-20 21:05:17 +00:00
svenbarth
b6eac7a31b n68kmat.pas, tm68knotnode.pass_generate_code:
fix the double running of second_pass in the way it was intended to work: check for left.expectloc instead of left.location.loc

git-svn-id: trunk@22788 -
2012-10-20 20:31:01 +00:00
svenbarth
72a01f17f5 * m68k/n68kmat.pas, tm68knotnode.pass_generate_code:
It is a bad idea (TM) to do a second_pass twice on the same node
* added test

git-svn-id: trunk@22785 -
2012-10-20 18:23:35 +00:00
svenbarth
ff0eebf1ff Also change RTL helper FPC_DIV_CARDINAL to FPC_DIV_DWORD
git-svn-id: trunk@22745 -
2012-10-18 20:12:12 +00:00
svenbarth
d5523e6af6 For now completely disable (I)MUL/(I)DIV support for Coldfire and pass through the RTL routines
(of which the names had changed from FPC_MUL_LONGWORD->FPC_MUL_DWORD and FPC_MOD_CARDINAL->
FPC_MOD_DWORD).
Also disable the usage of FPU opcodes for Coldfire.

git-svn-id: trunk@22739 -
2012-10-18 20:11:39 +00:00
Jonas Maebe
edd42aa42a * moved subsetref/reg and bit_set/test support from cgobj to hlcgobj for
future use by high level code generator targets
   o this in turn required that all a_load*_loc* methods are called via
     hlcg rather than via cg, since a location can be a subsetref/reg and
     and those are no longer handled in tcg
   o that then required moving several force_location_* routines into
     thlcg because they use a_load_loc*, but did not take tdef size
     parameters (which are required by the thlcg a_load_loc* routines)
   o the only practical consequence is that from now on, you have to
     use hlcg.location_force_mem/reg() (fpureg not yet) and
     hlcg.gen_load_loc_cgpara() instead of the removed versions from ncgutil,
     and hlcg.a_load*loc*() instead of cg.a_load*loc* if a subsetref/reg
     might be involved

git-svn-id: trunk@21287 -
2012-05-13 12:33:10 +00:00
Jonas Maebe
9bc15a5f61 * renamed a_param_* to a_load_*_cgpara
git-svn-id: trunk@15305 -
2010-05-22 09:07:21 +00:00
Jonas Maebe
a4cc881693 * fixed compilation after addition of support for weak symbols
git-svn-id: trunk@12716 -
2009-02-08 10:21:17 +00:00
yury
491f0fa1d8 * Replaced all user defined warnings by TODO comments to reduce compiler noise.
git-svn-id: trunk@11443 -
2008-07-23 11:00:03 +00:00
Károly Balogh
0c6f533ba3 + made m68k compiler to compile again
git-svn-id: trunk@8467 -
2007-09-13 22:30:27 +00:00
florian
85d63d9fa9 * settings refactored
git-svn-id: trunk@5094 -
2006-10-30 18:02:58 +00:00
peter
3078a1927f * remove ttype
* rename old ttype variables *type to *def
  * rename resulttypepass to pass_typecheck
  * rename pass_2 to pass_generate_code

git-svn-id: trunk@5077 -
2006-10-29 22:19:39 +00:00
peter
b7fe6797bf Merged revisions 2921-2922,2925 via svnmerge from
http://svn.freepascal.org/svn/fpc/branches/linker/compiler

........
r2921 | peter | 2006-03-15 08:35:00 +0100 (Wed, 15 Mar 2006) | 2 lines

  * pass ObjectWriter to ObjectOuput

........
r2922 | peter | 2006-03-15 12:40:30 +0100 (Wed, 15 Mar 2006) | 2 lines

  * refactor asmdata

........
r2925 | peter | 2006-03-15 16:09:39 +0100 (Wed, 15 Mar 2006) | 3 lines

  * add cfi to asmdata
  * move asmlist, asmcfi, asmdata to own unit

........

git-svn-id: trunk@2932 -
2006-03-16 08:52:22 +00:00
peter
d8dc5679e3 * aktcputype and aktoptimizecputype was missing in the previous optimization commits
git-svn-id: trunk@2907 -
2006-03-13 12:29:56 +00:00
peter
b6e35a200e * rewrite of optimizer options
git-svn-id: trunk@2901 -
2006-03-13 09:05:50 +00:00
Károly Balogh
db07870443 totally messy m68k changes. cleanup in progress
git-svn-id: trunk@2352 -
2006-01-27 14:20:35 +00:00
peter
a3ab2053c9 * support multiple asmlabel types, renamed getlabel to
getjumplabel and added type para to getlabel for specific types
  * moved lineinfo generation from assemble and aggas to dbgstabs

git-svn-id: trunk@1120 -
2005-09-18 21:16:10 +00:00
Károly Balogh
62121a9029 made m68k to compile again
git-svn-id: trunk@212 -
2005-06-05 13:07:13 +00:00
fpc
790a4fe2d3 * log and id tags removed
git-svn-id: trunk@42 -
2005-05-21 09:42:41 +00:00
fpc
50778076c3 initial import
git-svn-id: trunk@1 -
2005-05-16 18:37:41 +00:00
peter
e417e34496 * truncate log 2005-02-14 17:13:06 +00:00
Károly Balogh
6bae9c8f6d * made m68k to compile again 2005-01-08 04:10:36 +00:00
peter
c95a859f0a * generic tlocation
* move tlocation to cgutils
2004-10-31 21:45:02 +00:00
peter
65c3ba277c * ungetregister is now only used for cpuregisters, renamed to
ungetcpuregister
  * renamed (get|unget)explicitregister(s) to ..cpuregister
  * removed location-release/reference_release
2004-09-25 14:23:54 +00:00
florian
8a9758c5e2 * logs truncated 2004-06-20 08:55:28 +00:00
florian
1f18d7ac1b * some m68k stuff fixed 2004-04-25 21:26:16 +00:00
Jonas Maebe
edb2179730 + added freeintparaloc
* ppc get/freeintparaloc now check whether the parameter regs are
    properly allocated/deallocated (and get an extra list para)
  * ppc a_call_* now internalerrors if pi_do_call is not yet set
  * fixed lot of missing pi_do_call's
2003-06-07 18:57:04 +00:00