Commit Graph

53 Commits

Author SHA1 Message Date
Karoly Balogh
fd83fd5779 m68k-linux: try to be as ColdFire compatible in the startup code as possible, so explicitly use jsr, otherwise this might compile to a long bsr, that is not CF compatible (except cfv4) 2022-08-31 22:14:15 +02:00
florian
727e25e93e * make __lib_csu* weak symbols on m68k-linux 2022-04-02 16:03:49 +02:00
pierre
0055023394 Also set __stkptr inside cprt0.as and dllprt0.as startup assembly sources
git-svn-id: trunk@48223 -
2021-01-19 22:30:59 +00:00
florian
7b88d1127f * remove unused file
git-svn-id: trunk@47619 -
2020-11-28 13:41:44 +00:00
florian
b2a67d4656 * fixed comments in sysnr.inc files
git-svn-id: trunk@47426 -
2020-11-15 19:30:19 +00:00
florian
80394fc6e8 - removed cvs remainders ($Id$ and $Log$ tags)
git-svn-id: trunk@47119 -
2020-10-16 21:19:10 +00:00
florian
91fe098eb4 * check first for x86 exception and only for sse if no x87 exceptions is thrown, clear all exception afterwards
* throw rte 206 instead of rte 216 for denormal on m68k-linux as well

git-svn-id: trunk@47117 -
2020-10-16 19:44:25 +00:00
Károly Balogh
313790502d * linux-m68k: depend on FPU defines to compile FPU code, instead of CPU68020. also, minor cosmetics
git-svn-id: trunk@46447 -
2020-08-15 09:07:30 +00:00
florian
7281ea7a2c * floating point division by zero should throw run time error 208, fixed
git-svn-id: trunk@46210 -
2020-08-03 19:42:16 +00:00
marco
ee760a60f4 * changed copyright to Sven since he is the first one with an implementation.
Florian added the file, but as empty skeleton

git-svn-id: trunk@43965 -
2020-01-17 17:51:20 +00:00
marco
3053f8c2e8 * many syscallh header files had GPL license instead of modified. I owned the copyright, or in one case, Thomas did, but it was a full copy of mine. -> changed to modified
* removed the remark about calling convention from several implementations. Oldfpccall no longer used.

git-svn-id: trunk@43962 -
2020-01-17 12:07:50 +00:00
pierre
3b39ec84e4 Examine all exception bits in m68k fpsr register to decide which into which run time error it is converted
git-svn-id: trunk@43909 -
2020-01-10 22:58:34 +00:00
florian
295041e523 * updated linux syscall numbers
git-svn-id: trunk@43835 -
2020-01-02 11:08:40 +00:00
marco
bffbff73e1 * remove deprecated parts linux stat records (FPC 1.0 leftovers)
git-svn-id: trunk@39644 -
2018-08-19 15:10:22 +00:00
Károly Balogh
a3a7285df4 linux: an attempt to clean up and fix syscall calling conventions for ftruncate64, pread64 and pwrite64 on platforms which use aligned register pairs to pass the 64bit parameters
git-svn-id: trunk@37719 -
2017-12-12 02:39:45 +00:00
sergei
ad2963783e * m68k-linux startup code:
+ initialize __stkptr variable (was missing, causing any stack check to fail)
 + non-executable stack marker.

git-svn-id: trunk@28249 -
2014-07-23 13:55:38 +00:00
sergei
e65c4e13e0 * m68k: updated/fixed dllprt0.as, now able to link a shared library.
git-svn-id: trunk@28189 -
2014-07-09 22:59:13 +00:00
sergei
15ff2c1236 * m68k: Fixed name of ELF interpreter, and updated cprt0.as to somewhat working state. Now a "hello world" program using libc can be linked and launched, but anything more complex needs another round of fixing the parameter passing code, in order to get the stack properly balanced.
git-svn-id: trunk@28181 -
2014-07-07 20:08:50 +00:00
sergei
12e0416323 * m68k-linux: now actually fixed syscall failure conditions.
git-svn-id: trunk@28092 -
2014-06-27 19:41:02 +00:00
sergei
4b4651d298 * m68k-linux: syscalls are expected to return -1 on failure, not -errno. This fixes some of the tests, webtbs/tw2494 is one of them.
git-svn-id: trunk@28089 -
2014-06-27 15:41:51 +00:00
svenbarth
e734ca7a9b M68k: Fix passing of environment variables. Fixes the compiler not being able to execute the external assembler and linker.
* rtl/linux/m68k/prt0.as:
    between the arguments and the environment variables is a NULL; keep this in mind when loading the address of the first environment variable.

git-svn-id: trunk@26851 -
2014-02-23 12:41:05 +00:00
Károly Balogh
c6d60979d2 set errno after syscalls. this fixes tiorte test at least. this code ideally should be in assembly, but it seems the assembler reader needs some fixing first...
git-svn-id: trunk@26828 -
2014-02-22 05:30:04 +00:00
svenbarth
1e48c7c930 Now that spilling correctly works on m68k we definitely need to store/restore the registers inside the FpSyscall functions. Fixes quite some tests.
* rtl/linux/m68k/syscall.inc:
    Remove "assembler" modifier and instead use an inline asm block with an accurate list of modified registers so that the compiler correctly stores/restores them

git-svn-id: trunk@26804 -
2014-02-16 21:21:40 +00:00
sergei
a3364a4b80 - RTL, Linux/FreeBSD shared library startup: removed FPC_SHARED_LIB_EXIT label, it is a leftover from times when library startup code was erroneously halting owning process on exit.
git-svn-id: trunk@25737 -
2013-10-10 13:14:56 +00:00
Jonas Maebe
81597bf171 * updated address of FSF (mantis #24646, patch by Alexey Svistunov)
git-svn-id: trunk@24986 -
2013-06-27 14:01:18 +00:00
svenbarth
fdf6b17421 rtl/linux/m68k/prt0.as:
correctly calculate and pass on the addresses for the parameters and the environment; this way parameters can now be used, but reading environment variables still does not seem to work...

Note: the other assembler files (especially cprt0.as) were not adjusted and might not work at all

git-svn-id: trunk@22936 -
2012-11-05 21:12:09 +00:00
svenbarth
7bc5995d4d Implement SysCall interface for m68k-linux. This is especially useful for testing code using
QEMU's userspace emulation as no libraries are needed then.

git-svn-id: trunk@22750 -
2012-10-18 20:12:32 +00:00
svenbarth
322dbe5b65 Various adjustments to the RTL for m68k:
* enable the 6 parameter syscall variant (still everything dummied out though)
* add termios constants
* don't change signal handlers for now
* disable assembly set routines as set handling was changed

git-svn-id: trunk@22743 -
2012-10-18 20:12:02 +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
svenbarth
81069a7eca rtl/linux/m68k/prt0.as:
Add __stkptr variable

git-svn-id: trunk@22735 -
2012-10-18 20:11:21 +00:00
svenbarth
9a9d941ee1 rtl/m68k/sysnr.inc:
adjust syscalls just enough so that we don't have any duplicate symbols; the correctness will
  be verified once we have linkable code

git-svn-id: trunk@22727 -
2012-10-18 20:10:38 +00:00
daniel
3307d98c40 - Revert micro-exe mode for now.
git-svn-id: trunk@16170 -
2010-10-15 16:49:48 +00:00
daniel
2139a229d3 + If no unit is used, no symbol inside the system unit is used,
and no language features requiring initialization are used,
    do not initialize units, but just configure the fpu and
    signal handlers.

git-svn-id: trunk@16124 -
2010-10-10 17:40:39 +00:00
Jonas Maebe
92ff07deaf * several fixes by Pierre Pede (parts of his patch to mantis #12492)
o fixed gprof under linux/i386
    o fixed pic-compilation of the linux/i386 rtl
    o initialisation of linux shared libraries is now possible with pic-code

git-svn-id: trunk@13703 -
2009-09-12 21:57:41 +00:00
Jonas Maebe
f6d452c2c0 * remove the RTL's installed signal handlers at the end of the system
unit's initialization code in case we're in a library
  + implemented InquireSignal(), AbandonSignalHandler(), HookSignal() and
    UnhookSignal() in the sysutils unit
  * for Kylix compatibility, these routines support operating on
    SIGINT and SIGQUIT as well, although they are not hooked by default
    by FPC. The run time errors/exception codes for these signals are
    resp. 217 and 233 (same as in Kylix; I changed ENoWideStringSupport
    to 234).
  * changed the BSD syscall version of fpsigaction to use pointer
    rather than "var" arguments (compatible with other targets, and
    required to be able to pass nil arguments inside the system unit)
  -> together fixes mantis #12704

git-svn-id: trunk@13077 -
2009-05-02 09:40:44 +00:00
micha
341cec908d * update linux syscall numbers (merge powerpc64 to powerpc)
git-svn-id: trunk@12106 -
2008-11-15 15:42:12 +00:00
florian
065b187c26 * properties set
git-svn-id: trunk@8209 -
2007-08-02 07:38:09 +00:00
daniel
82b973937d * Change padding to 2 bytes.
git-svn-id: trunk@6968 -
2007-03-24 07:56:39 +00:00
daniel
d030103742 + Restore "stat" data structure in backward compatible state
git-svn-id: trunk@6963 -
2007-03-23 22:23:24 +00:00
florian
0d38bda5c4 * small m68k-linux fixes
git-svn-id: trunk@5427 -
2006-11-19 21:51:20 +00:00
florian
b07cd83892 * made system unit on m68k-linux compilable
git-svn-id: trunk@5266 -
2006-11-06 18:42:47 +00:00
micha
b14c83a7e1 * stat records differ too much: use stat include file
git-svn-id: trunk@5126 -
2006-10-31 15:45:22 +00:00
florian
818ac29ba2 + some files from old fixes branch added
git-svn-id: trunk@2385 -
2006-01-31 21:55:42 +00:00
peter
63091ddafc * blksze to blksize
git-svn-id: trunk@2050 -
2005-12-25 11:08:23 +00:00
peter
4ace790492 * remove $Log
git-svn-id: trunk@231 -
2005-06-07 09:47:55 +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
florian
314fe14247 + routines in baseunix can be overriden by processor specifics in bsyscall.inc 2005-03-03 20:58:38 +00:00
peter
e417e34496 * truncate log 2005-02-14 17:13:06 +00:00
Jonas Maebe
54015aaf6e * the stat type is processor-dependent
* the dev_t tpye is processor dependent. Don't use it in the stat type
    however, as that one is also used at a time where dev_t is already
    defined as qword
2003-05-15 22:50:50 +00:00