florian
358bfb4858
* SSE4.1+ implementation of int(...)
...
git-svn-id: trunk@36285 -
2017-05-21 15:28:34 +00:00
florian
12dec14859
* try to break dependency chains when generating vsqrt instructions
...
git-svn-id: trunk@36282 -
2017-05-21 11:35:33 +00:00
florian
8eec29b139
+ enable support for a processor specific frac function
...
* implemented inlined frac support for CPUs with SSE4.1+
git-svn-id: trunk@36281 -
2017-05-21 11:12:59 +00:00
nickysn
efc5e339d0
* use an enum instead of integer constants to represent inline numbers
...
* compinnr.inc include file converted to a unit
* inline number field size stored in ppu increased from byte to longint
* inlines in the parse tree (when written with the -vp option) now printed with
their enum name, instead of number
git-svn-id: trunk@36174 -
2017-05-10 14:41:43 +00:00
florian
b1dff29cbf
* removed unused units
...
git-svn-id: trunk@36165 -
2017-05-09 19:53:14 +00:00
Jonas Maebe
a25ebbba3e
+ added volatility information to all memory references
...
o separate information for reading and writing, because e.g. in a
try-block, only the writes to local variables and parameters are
volatile (they have to be committed immediately in case the next
instruction causes an exception)
o for now, only references to absolute memory addresses are marked
as volatile
o the volatily information is (should be) properly maintained throughout
all code generators for all archictures with this patch
o no optimizers or other compiler infrastructure uses the volatility
information yet
o this functionality is not (yet) exposed at the language level, it
is only for internal code generator use right now
git-svn-id: trunk@34996 -
2016-11-27 18:17:37 +00:00
pierre
1e9491550d
nutils.pas: Add new procedure:
...
procedure node_change_local_switch(p : tnode;cs : tlocalswitch;enable : boolean);
to add/remove cs local switch from all p tnode tree localsettings.
modify second_prefetch implementation in arm, ppcgen and x86 subdirectories
to use node_change_local_settings to temporarily disabled
checkpointer local switch, as prefetch is allowed even on unaccessible addresses.
(previous code was buggy because I frogot that each node has it own localswitches).
git-svn-id: trunk@34576 -
2016-09-29 21:34:34 +00:00
pierre
fe4e2956c6
Disable checkpointer call when handling left of prefetch node
...
git-svn-id: trunk@34559 -
2016-09-24 07:34:10 +00:00
florian
e5f63779bb
* pass S_NO instead of S_XMM to *SQRTSS/SD as size as the memory location is 32/64 bit
...
git-svn-id: trunk@34540 -
2016-09-18 20:05:25 +00:00
Jonas Maebe
aa1be3276f
- removed default value of _typ parameter of TAsmData.(Weak)RefAsmSymbol():
...
it was AT_NONE, which is invalid and should never be used
* explicitly pass the correct value for all calls to those methods elsewhere
in the compiler
git-svn-id: trunk@34250 -
2016-08-05 07:09:16 +00:00
florian
e4baf67722
* do not write any size suffix for cvt*ss2si, doing so makes no sense as the size of the single and the integer might be different on x86-64, resolves issue #30101
...
git-svn-id: trunk@33661 -
2016-05-08 18:50:53 +00:00
florian
0232a0d979
* several inlined math function do not need a non-constant register for the argument
...
git-svn-id: trunk@33649 -
2016-05-04 18:15:33 +00:00
Jonas Maebe
da696057ab
* converted register_maybe_adjust_setbase() to the high level code generator
...
git-svn-id: trunk@32591 -
2015-12-05 18:03:37 +00:00
yury
e04a3b4ac6
* Removed unused vars for x86 compiler.
...
git-svn-id: trunk@31743 -
2015-09-17 15:20:15 +00:00
Jonas Maebe
1bcc276dcf
* remove implicit typecast to extended automatically inserted for trunc/round
...
(due to the declaration in the system unit) on x86_64 if this allows us
to use SSE code instead (mantis #28366 )
git-svn-id: trunk@31192 -
2015-07-03 21:01:18 +00:00
Jonas Maebe
9079227c56
* don't give an internalerror when trying to prefetch a regvar or even
...
something without a location at all; it's a hint/optional operation,
so if there's nothing to prefetch just don't do anything
(mantis #27811 )
git-svn-id: trunk@30502 -
2015-04-08 20:35:13 +00:00
florian
de17e9fa1c
+ cpu capability CPUX86_HAS_CMOV
...
git-svn-id: trunk@29776 -
2015-02-21 20:47:40 +00:00
florian
8207e0ef22
+ make use of vfnmsub*/vfmsub*/vfnmadd* instructions if possible
...
git-svn-id: trunk@27721 -
2014-05-02 21:07:46 +00:00
florian
33602db802
* try to registers more cleverly during fma code generation
...
git-svn-id: trunk@27671 -
2014-04-26 18:11:13 +00:00
florian
18233f2c0c
* fix compilation of i8086 compiler
...
git-svn-id: trunk@27566 -
2014-04-13 19:28:59 +00:00
florian
d88d644925
+ support for FMA intrinsic: if there is no hardware support, the compiler throws an error.
...
Currently it is implemented only for x86-CPUs supporting the FMA extension. While it would
be possible to implement it in software or simulate fma(<single>,<single>,<single>) using
double operations, it makes no sense in my opinion to do so.
git-svn-id: trunk@27564 -
2014-04-13 19:21:54 +00:00
Jonas Maebe
d452686c39
* moved pbestrealtype from symdef to symcpu
...
git-svn-id: trunk@27441 -
2014-04-01 21:41:37 +00:00
Jonas Maebe
6b16c05a98
* fixed compilation for i8086 with 2.6.x (it gave an unreachable code
...
warning)
git-svn-id: trunk@27358 -
2014-03-29 22:31:43 +00:00
sergei
e4819e863b
+ Consider target_info.cprefix in symbol names.
...
git-svn-id: trunk@27315 -
2014-03-28 09:07:58 +00:00
Jonas Maebe
4065483a50
* completed thlcgobj.location_force_fpureg(), use it everywhere and removed
...
ncgutil/thlcg2ll.location_force_fpureg()
git-svn-id: trunk@27071 -
2014-03-10 09:01:05 +00:00
florian
c00d752813
+ create avx code in abs as well
...
* improved abs code generation with sse(2)
git-svn-id: trunk@26838 -
2014-02-22 15:35:14 +00:00
florian
1882ab8d5a
* i8086 has no cpu_capabilites
...
git-svn-id: trunk@26791 -
2014-02-16 08:27:29 +00:00
florian
84f7f5f934
* popcnt has a separate cpuid flag so we should separate it from sse
...
git-svn-id: trunk@26789 -
2014-02-16 08:27:24 +00:00
nickysn
a7b4953795
+ proper (i.e. not broken) implementation of arctan() for the 8087 and 80287
...
git-svn-id: trunk@26226 -
2013-12-12 23:46:51 +00:00
nickysn
09a3fc74e3
* use the fwait prefixed FSTCW, followed by FWAIT, instead of FNSTCW in
...
tx86inlinenode.second_trunc_real, when generating code for the 8087
git-svn-id: trunk@26186 -
2013-12-05 23:33:33 +00:00
sergei
bca2c464da
* Don't generate x87 instructions for sin and cos on win64, somehow managed to not commit this part in r25995. Mantis #17273 .
...
git-svn-id: trunk@26094 -
2013-11-15 10:37:59 +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
486a7ef81e
* tx86inlinenode.second_popcnt: use emit_ref_reg instead of appending instruction directly, this provides proper PIC handling of the reference. emit_reg_reg part is not strictly necessary, but done for consistency.
...
git-svn-id: trunk@25878 -
2013-10-28 16:40:42 +00:00
florian
fc72490166
* handle LOC_*FPUREGISTER correctly when using sse2 sqr, resolve #26408
...
git-svn-id: trunk@24909 -
2013-06-16 18:48:08 +00:00
florian
e81d2d1f3b
* basic avx support for floating point operations (use -Cfavx to activate)
...
git-svn-id: trunk@24896 -
2013-06-14 20:03:01 +00:00
Jonas Maebe
2dd75e707e
* renamed thlcgobj.tcgsize2orddef to defutil.cgsize_orddef
...
git-svn-id: trunk@24743 -
2013-06-01 18:28:15 +00:00
Jonas Maebe
5051453806
+ support for LOC_(C)MMREGISTER in hlcg
...
o migrated location_force_mmregister_scalar from ncgutil to hlcgobj
git-svn-id: trunk@24661 -
2013-05-31 12:05:14 +00:00
nickysn
2b583bb265
* do not use fsin and fcos on 286-, since they're 387+
...
git-svn-id: trunk@24596 -
2013-05-25 15:24:53 +00:00
nickysn
09249b31b8
* use the generic implementation of second_IncludeExclude in case the cpu is earlier than 386, since then it does not support BTR and BTS
...
git-svn-id: trunk@24593 -
2013-05-25 14:18:55 +00:00
nickysn
9f0c23bd4c
* fixed round() on i8086 after r24502
...
git-svn-id: trunk@24503 -
2013-05-15 00:45:08 +00:00
nickysn
3665ed4b03
+ enabled returning int64 in ax:bx:cx:dx for the i8086
...
git-svn-id: trunk@24502 -
2013-05-14 22:45:57 +00:00
nickysn
3152df6e7f
* fixed bugs in tx86inlinenode, introduced in r24237
...
git-svn-id: branches/i8086@24243 -
2013-04-14 16:16:47 +00:00
nickysn
97ca0fa323
- removed ti8086inlinenode.second_round_real, second_trunc_real and load_fpu_location as they mostly repeat the code in tx86inlinenode.load_fpu_location; tx86inlinenode.load_fpu_location adapted for i8086 instead
...
git-svn-id: branches/i8086@24237 -
2013-04-14 14:25:22 +00:00
nickysn
44ef72e1a4
* use the generic implementation of abs for the i8086
...
git-svn-id: branches/i8086@24004 -
2013-03-25 21:43:47 +00:00
nickysn
8d75441b6e
* do not generate prefetchnt instructions on the i8086
...
git-svn-id: branches/i8086@24003 -
2013-03-25 19:18:18 +00:00
florian
10dbdb5c9a
* fix compilation on x86-64
...
git-svn-id: trunk@22294 -
2012-09-03 09:52:06 +00:00
florian
76bea5c4fd
* x86-64 and i386 use the popcnt instruction of possible
...
git-svn-id: trunk@22291 -
2012-09-02 20:59:48 +00:00
florian
ff12d63248
+ generic popcnt support
...
git-svn-id: trunk@22290 -
2012-09-02 20:59:44 +00:00
florian
b782918434
* first draft to support the popcnt instruction, works so far for x86 with a real popcnt instruction
...
git-svn-id: trunk@22289 -
2012-09-02 20:59:39 +00:00
Jonas Maebe
bb28a7cd08
* decrease the fpu stack position counter after explicitly inserted
...
fist(t)pq instructions (mantis #22331 )
* also internalerror in case the internal fpu stack position counter
becomes larger than 7, so we don't have to wait for the entire
byte to overflow before we detect a problem
git-svn-id: trunk@21734 -
2012-06-29 09:52:35 +00:00