sergei
897c8b8f7b
* Cleanup fpc_trunc_real implementation.
...
* For single-precision variant, truncate to 64 bits instead of 32, since this how trunc()/round() are defined.
* Do not access float64 as int64, doing so would break on ARM hardfloat after r26010.
git-svn-id: trunk@26065 -
2013-11-12 09:31:23 +00:00
sergei
437b3755d1
* math.hypot(): factor larger argument out of expression in order to avoid loss of precision.
...
git-svn-id: trunk@26026 -
2013-11-11 09:56:20 +00:00
nickysn
870d432468
+ reenabled the new str<->float conversion code on i8086 after the fix in r26005
...
git-svn-id: trunk@26013 -
2013-11-10 18:29:17 +00:00
sergei
203efdcd0e
* Let order of fields in float64 record depend on FPC_DOUBLE_HILO_SWAPPED, so messing with this order on every usage of float64 is no longer necessary.
...
git-svn-id: trunk@26010 -
2013-11-10 14:52:57 +00:00
Jonas Maebe
6359441045
* force shl operations to be 32 bit on 16/8 bit platforms (patch by
...
Max Nazhalov, mantis #25241 )
git-svn-id: trunk@26005 -
2013-11-10 10:24:54 +00:00
sergei
5ea99c84fd
* x86_64 non-Win64 targets: calculate tan() and cotan() using x87 "fptan" instruction.
...
git-svn-id: trunk@25996 -
2013-11-09 11:31:27 +00:00
sergei
2b1e5f7014
* Mantis #17273 : don't generate x87 instructions on win64 target.
...
git-svn-id: trunk@25995 -
2013-11-08 13:31:07 +00:00
sergei
d83fbd7602
* Replaced fpc_arctan_real() implementation with one providing a better precision.
...
git-svn-id: trunk@25994 -
2013-11-08 11:33:57 +00:00
nickysn
7516b87382
* (temporarily) disabled the new str<->float code on the i8086, because it
...
causes a lot of wrong conversions and thus a lot of testsuite failures.
git-svn-id: trunk@25993 -
2013-11-08 08:22:35 +00:00
sergei
441e37b8b4
- Eliminated separate extractFloat32* routines, they are used only once and manually inlining them does not harm to readability.
...
git-svn-id: trunk@25983 -
2013-11-07 10:12:13 +00:00
Jonas Maebe
d4b6406e62
* fixed compilation of new str<->float code on the JVM target (patch by
...
Max Nazhalov) and use that code by default on the JVM target
* adapted JVM tests for the new str<->float code similar to how the
generic tests were adapted
git-svn-id: trunk@25954 -
2013-11-06 16:13:50 +00:00
Jonas Maebe
8fe7d82db7
* changed type of TAbstractSearchRec.name_do_not_touch from untyped pointer
...
into rawbytestring because otherwise -gt can overwrite it
- removed hack from r25944 in morphos/sysutils.pp that worked around this
problem
git-svn-id: trunk@25952 -
2013-11-06 13:17:06 +00:00
sergei
797653dd14
* Reverted overflow/underflow handling in fpc_exp_real to original state of C port. In particular, changed constant values to typed constants. Resolves #24839 .
...
* Values like "huge" or "twom1000" must be declared as typed constants, so expressions using them are evaluated at runtime. E.g. "huge*huge" will either raise an overflow exception or will be evaluated as infinity, if overflows are masked. Calling float_raise() is not necessary anymore.
* Also replaced round() by trunc() when converting double to integer, this is how C defines such conversions.
git-svn-id: trunk@25945 -
2013-11-06 05:02:02 +00:00
Károly Balogh
3b87e2c386
fixed InternalFindFirst to initialize out Rslt properly, also reverted some earlier changes leading to potential issues as Jonas pointed out
...
git-svn-id: trunk@25944 -
2013-11-06 03:34:25 +00:00
Károly Balogh
83544d3f30
fix typo in comment
...
git-svn-id: trunk@25943 -
2013-11-06 03:17:35 +00:00
Károly Balogh
a691971b9d
fixed RawByteString PathConv() return value, removed the no longer needed dosLock() function, and related cleanups
...
git-svn-id: trunk@25939 -
2013-11-05 18:52:27 +00:00
Károly Balogh
6522cd78ee
added some float64() casts, based on similar casts in the 32bit code path, which makes ARM to build again
...
git-svn-id: trunk@25914 -
2013-11-02 17:44:47 +00:00
Jonas Maebe
ee0d80ac19
* force use of real2str.inc after r25888 because it doesn't compile (yet?)
...
for the jvm target (mantis #25267 )
git-svn-id: trunk@25910 -
2013-11-01 19:20:47 +00:00
Jonas Maebe
21eeec9981
+ re-implementation of real->string and string->real conversion routines
...
based on the Grisu1 algorithm. This corrects several precision issues
with the previous code used to perform such conversions (patch by
Max Nazhalov, mantis #25241 )
o adaptation of several tests to deal with the better precision of these
routines compared to the previous version
Please don't remove the real2str.inc file yet, it's still used by the
JVM target for now
git-svn-id: trunk@25888 -
2013-10-31 12:39:27 +00:00
sergei
ca445577ff
- Linux RTL: MIPS no longer needs the softfloat code, don't compile it.
...
git-svn-id: trunk@25882 -
2013-10-30 12:25:11 +00:00
sergei
9ad98a2c4d
* Handle "SarInt64" always as internal procedure, introduced virtual method tinlinenode.first_sar that by default converts it into call to "fpc_sarint64" unless target CPU is 64-bit. This provides a point to insert target-specific optimizations.
...
git-svn-id: trunk@25876 -
2013-10-28 14:31:36 +00:00
nickysn
611358be7e
* fixed the stack traces (StackTop initialization) under go32v2 as well
...
git-svn-id: trunk@25875 -
2013-10-28 00:14:08 +00:00
nickysn
af91346830
+ added exeinfo to the implicitunits list in the makefile for i8086-msdos
...
git-svn-id: trunk@25865 -
2013-10-27 14:23:31 +00:00
nickysn
8066d12c87
* fixed the stack traces under i8086-msdos (StackTop wasn't initialized)
...
git-svn-id: trunk@25863 -
2013-10-27 13:53:16 +00:00
nickysn
28c16f31e6
* __stkbottom, __nearheap_start and __nearheap_end moved to the implementation
...
part of the system unit for i8086-msdos
git-svn-id: trunk@25862 -
2013-10-27 13:28:58 +00:00
nickysn
714ca3a61d
* fixed the stack traces under linux (StackTop wasn't initialized)
...
git-svn-id: trunk@25861 -
2013-10-27 12:37:32 +00:00
nickysn
f23794bf39
* get_caller_frame for i8086 optimized for size
...
git-svn-id: trunk@25860 -
2013-10-27 12:01:29 +00:00
nickysn
7489bfb56b
* fixed get_caller_addr returning the wrong segment in i8086 medium memory model
...
git-svn-id: trunk@25859 -
2013-10-27 11:36:45 +00:00
nickysn
4646884d87
+ enabled compilation of unit ctypes for i8086-msdos
...
git-svn-id: trunk@25858 -
2013-10-26 22:26:42 +00:00
nickysn
85c8be531a
+ added an asm implementation of FillWord for i8086 as well
...
git-svn-id: trunk@25854 -
2013-10-26 16:52:57 +00:00
nickysn
2f88ae82b1
+ added an asm implementation of FillChar for i8086
...
git-svn-id: trunk@25849 -
2013-10-25 23:15:44 +00:00
nickysn
5abeb67bff
* the i8086 versions of InterLockedDecrement and InterLockedIncrement were
...
missing 'nostackframe'. Fixed.
git-svn-id: trunk@25813 -
2013-10-17 22:38:59 +00:00
nickysn
e0e4c04456
* the Ptr(sel,ofs) parameters changed from longint to word on i8086
...
git-svn-id: trunk@25811 -
2013-10-17 20:44:58 +00:00
nickysn
f30fddec53
* use 16-bit LEA directly in fpc_SetJmp, since that instruction is now supported
...
by the compiler
git-svn-id: trunk@25809 -
2013-10-17 17:33:55 +00:00
nickysn
9be15583af
* compilation of i8086 rtl fixed (seems like the fpc asm reader doesn't support 16-bit LEA, so hardcode it with DB for now)
...
git-svn-id: trunk@25806 -
2013-10-16 16:34:48 +00:00
nickysn
c9d021aeb8
* prefer to use ax in fpc_SetJmp for i8086, because it's faster on old CPUs (and makes no difference on newer CPUs)
...
git-svn-id: trunk@25805 -
2013-10-16 15:17:23 +00:00
nickysn
acbf73ec6e
* stack frame eliminated also in fpc_longJmp for i8086
...
git-svn-id: trunk@25804 -
2013-10-16 13:50:18 +00:00
nickysn
0d24dcc21b
* optimizations in fpc_SetJmp for i8086 by stack frame elimination and using SI instead of BP
...
git-svn-id: trunk@25803 -
2013-10-16 12:49:38 +00:00
nickysn
6596ba9036
* fixed the stack param offsets in Ptr, get_caller_addr and get_caller_frame after the stackframe elimination
...
git-svn-id: trunk@25802 -
2013-10-16 12:39:39 +00:00
nickysn
9bf3d1edff
* optimized get_caller_addr and get_caller_frame on i8086 by eliminating the stack frame and using si, instead of bp
...
git-svn-id: trunk@25801 -
2013-10-16 12:35:05 +00:00
nickysn
aa9fe36fd3
* optimized version of Ptr() for i8086
...
git-svn-id: trunk@25800 -
2013-10-16 12:29:22 +00:00
nickysn
1c53d24743
* fixed typo (bug) in i8086 get_pc_addr. Use SP instead of BP to obtain the
...
return address.
git-svn-id: trunk@25799 -
2013-10-16 09:32:55 +00:00
nickysn
ea1370a89e
+ implementated get_frame() and get_pc_addr() for the i8086
...
git-svn-id: trunk@25795 -
2013-10-15 20:16:13 +00:00
nickysn
9b2b5a9565
* fixed a bug in fpc_SetJmp on i8086, that caused an incorrect value of sp to
...
be written in Jmp_buf.sp
git-svn-id: trunk@25793 -
2013-10-15 16:28:37 +00:00
Jonas Maebe
2b1a077b98
+ added now that the iOS SDK files aren't under NDA anymore
...
git-svn-id: trunk@25788 -
2013-10-14 19:29:39 +00:00
nickysn
3fb87cb529
* go32.map_device_in_memory_block result checking made consistent with all the
...
other functions in the go32 unit
git-svn-id: trunk@25787 -
2013-10-14 19:20:28 +00:00
nickysn
59f441269e
+ added function free_linear_addr_mapping to unit go32
...
git-svn-id: trunk@25786 -
2013-10-14 19:15:18 +00:00
nickysn
8bad012e83
+ added functions get_page_attributes and set_page_attributes to unit go32
...
git-svn-id: trunk@25785 -
2013-10-14 18:46:44 +00:00
nickysn
1b36781dd8
+ added function get_dpmi_version to unit go32
...
git-svn-id: trunk@25784 -
2013-10-14 18:42:05 +00:00
nickysn
6cf2382760
+ added the PFD_DIRECT3D_ACCELERATED and PFD_SUPPORT_COMPOSITION constants to
...
the windows unit
git-svn-id: trunk@25774 -
2013-10-14 11:59:24 +00:00