1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-05-04 14:20:26 +02:00
Commit graph

83 commits

Author SHA1 Message Date
Paolo Bonzini
ceaf1b05cf fix jit_extr_f_d and jit_extr_d_f for x86-64
2010-08-10  Paulo César Pereira de Andrade <pcpa@mandriva.com.br>
	    Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/core-32.h (jit_replace): Use MOVLrr, not MOVLir.
	(jit_movbrm): Check index register as well.
	* lightning/i386/fp-64.h: Add jit_extr_f_d and jit_extr_d_f.
	* lightning/fp-common.h: Add jit_extr_f_d and jit_extr_d_f.
2010-08-15 06:29:51 -04:00
Paulo César Pereira de Andrade
5cef649486 fix two bugs in load/store for i386
* lightning/i386/core-32.h (jit_replace): Use MOVLrr, not MOVLir.
(jit_movbrm): Check index register as well.
2010-08-10 08:35:35 -04:00
Paolo Bonzini
128ad6a4e7 fix i386 jit_replace and x86_64 jit_movi_f
2010-07-28  Paolo Bonzini  <bonzini@gnu.org>

	* THANKS: Add Paulo Cesar Pereira de Andrade.
	* doc/porting.texi: Fix ordering of arguments in jit_stxi.
	* lightning/i386/core-32.h (jit_replace): Remove cmp argument.
	* lightning/i386/fp-64.h (jit_movi_f): Fix.
2010-07-28 23:29:13 +02:00
Paolo Bonzini
2ecf6a2c28 fix jit_movbrm in the i386 backend
2010-07-26  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/core-32.h (jit_replace): Move here (removed
	2009-03-01).
2010-07-26 09:14:18 +02:00
Paolo Bonzini
21ece8cdcd always set and replace lightning_frag
2010-07-19  Paolo Bonzini  <bonzini@gnu.org>

	* build-aux/lightning.m4: Always set and replace lightning_frag.
	* Makefile.in: Regenerate.
	* aclocal.m4: Regenerate.
	* config.h.in: Regenerate.
	* configure: Regenerate.
	* doc/Makefile.in: Regenerate.
	* doc/lightningize.1: Regenerate.
	* doc/version.texi: Regenerate.
	* lightning/Makefile.in: Regenerate.
	* opcode/Makefile.in: Regenerate.
	* tests/Makefile.in: Regenerate.
2010-07-19 14:40:08 +02:00
Paolo Bonzini
7179d226ed fix x86 shifts
2009-03-01  Paolo Bonzini  <bonzini@gnu.org>

        * lightning/i386/core-64.h: Use Mike's macros for x86-64 too.
        * lightning/i386/core.h: Remove jit_replace.

	2009-02-27  Mike Spivey  <mike@comlab.ox.ac.uk>

        * lightning/i386/core.h: Rewrite shift-handling macros.
        * lightning/fp-common.h: Fix jit_extr_{f_d,d_f}.
2009-03-01 17:59:41 +01:00
Paolo Bonzini
e6c352bc3e fix blunder in operand order (i386)
2009-02-17  Mike Spivey  <mike@comlab.ox.ac.uk>

	* lightning/i386/core.h: Fix blunder in operand order.
2009-02-19 20:23:30 +01:00
Paolo Bonzini
d671ec726d another fix to jit_fp_btest
2009-02-17  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/fp-32.h: Another fix to jit_fp_btest.
2009-02-17 12:20:19 +01:00
Paolo Bonzini
a76f19c5ef fix problems with i386 32-bit floating point branches
2009-02-17  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/fp-common.h: Define double branches if missing.
	* lightning/i386/asm.h: Define JC and JNC mnemonics.
	* lightning/i386/fp-32.h: Fix jit_fp_btest.  All reported
	by Mike Spivey.
2009-02-17 09:57:23 +01:00
Paolo Bonzini
f87b2f6df8 subtract 1 from the final byte being flushed in PPC jit_flush_code
2008-10-09  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/ppc/funcs.h (jit_flush_code): Subtract 1 from end.
	Reported by Eli Barzilay and Matthew Flatt.
2008-10-09 10:19:26 +02:00
Paolo Bonzini
da92a86557 fix installation bug
2008-08-23  Nix  <nix@esperi.org.uk>

	* lightning/i386/Makefile.frag: fp-32.h and fp-64.h are target files.
2008-08-23 15:33:54 +02:00
Laurent Michel
b3817a102e fix miscellaneous PPC-32 back-end bugs
2008-07-02  Laurent Michel  <ldm@engr.uconn.edu>

	* lightning/ppc/funcs.h (jit_flush_code): modified the computation
	of start/end. The pointer arithmetic was done without casting. It
	prevented compilation with recent gcc versions.
	* lightning/ppc/core.h (jit_pushr_i): The offset for the store was
	incorrect. Should have been 4 bytes below SP (not above).
	* lightning/ppc/core.h (jit_popr_i): The offset for the load was
	incorrect. Should have been 0 (not +8).
2008-07-10 16:09:05 +02:00
Paolo Bonzini
66c8a682af fix IMULQir and IMULQirr
2008-06-17  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/asm-64.h: Forward IMULQir to IMULQirr,
	fix REXQ order for IMULQirr.
2008-06-17 15:20:23 +02:00
Paolo Bonzini
aa56a6b65f fix _rN vs. _rR
2008-06-17  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/core.h: Fix _rN vs. _rR.
2008-06-17 10:21:52 +02:00
Paolo Bonzini
8b2f05549c move JIT_R1/JIT_R2 to R10/R11 for the x86_64 backend
2008-06-16  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/core.h: Use jit_save in jit_replace.  Move JIT_R
	definition...
	* lightning/i386/core-32.h: ... here; define jit_save so that
	the core.h has no effect on the 32-bit backend.
	* lightning/i386/core-64.h: Place JIT_R1/JIT_R2 in R10/R11,
	place outgoing arguments in the right spot from the beginning,
	define jit_save, fix jit_reg8/jit_reg16.
2008-06-17 09:32:35 +02:00
Paolo Bonzini
6ee7c12349 rewrite x86-64 argument passing to support up to 6 arguments
2008-06-15  Paolo Bonzini  <bonzini@gnu.org>

        * lightning/i386/core-64.h: Rewrite argument passing to
	support up to 6 arguments and generate less code.
2008-06-16 14:09:10 +02:00
Laurent Michel
0b676371fa fix x86-64 jit_movi_l (x, 0) and 16-byte stack alignment in the prolog
2008-06-14  Laurent Michel  <ldm@thorgal.homelinux.org>

	* lightning/i386/core-64.h (jit_movi_l): When the operand is 0,
	the XOR should be on a quadword.
	* lightning/i386/core-64.h (jit_prolog): Keep 16-byte stack
	alignment.
	(jit_ret): Always use LEAVE.
2008-06-16 08:05:56 +02:00
Laurent Michel
297ed204de add (void) casts for C++ compatibility
2008-06-13  Laurent Michel  <ldm@thorgal.homelinux.org>

	* lightning/i386/core-64.h: Add (void) casts for C++ compatibility.
	* lightning/i386/asm.h: Likewise.
2008-06-13 17:14:04 -07:00
Paolo Bonzini
240905434b move x86-64 JIT_V1/JIT_V2 in R12/R13
2008-06-12  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/core.h: Move JIT_V definition...
	* lightning/i386/core-32.h: ... here.
	* lightning/i386/core-64.h: ... and here.  Avoid dancing between
	RSI/RDI and R12/R13, and place JIT_V1/JIT_V2 in R12/R13.
2008-06-12 22:51:50 -07:00
Paolo Bonzini
66aef1c644 detect 32-/64-bit variant of i386 back-end at include time (not configure time)
2008-06-11  Paolo Bonzini  <bonzini@gnu.org>

	* build-aux/lightning.m4: Adjust LIGHTNING_BACKENDS, don't
	use suffix support to distinguish i386/x86_64.
	* lightning/i386/Makefile.frag: Use LIGHTNING_TARGET_FILES
	to distribute *-32.h and *-64.h files now.
	* lightning/i386/asm-i386: Moved to...
	* lightning/i386/asm.h: Include the appropriate subtarget file.
	* lightning/i386/core-i386: Moved to...
	* lightning/i386/core.h: Include the appropriate subtarget file.
	* lightning/i386/fp.h: New, include the appropriate subtarget file.
	* lightning/i386/asm-32: Do not include asm-i386.h.
	* lightning/i386/asm-64.h: Likewise.
	* lightning/i386/core-32: Do not include core-i386.h.
	* lightning/i386/core-64.h: Likewise.
	* lightning/Makefile.am: Adjust for renamed files.

	* configure.ac: Define LIGHTNING_TARGET here.
	* opcode/disass.c: Change list of valid LIGHTNING_TARGET values.

	* lightningize.in: Robustify against missing subtarget files.
2008-06-11 19:00:37 -07:00
Paolo Bonzini
ef7eb772be use MOVLir directly to implement i386 32-bit jit_movi_p
2008-06-11  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/core-32.h: Use MOVLir instead of jit_movi_l
	to implement jit_movi_p.
2008-06-11 12:41:26 -07:00
Paolo Bonzini
e3461957f6 fix stack alignment for Apple 32-bit ABI
2008-06-11  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/core-32.h: Use separate __APPLE__ and SysV
	prolog/ret macros.  Subtract 12 bytes in __APPLE__ case to
	keep stack aligned, and always use LEAVE in the epilog.
2008-06-11 12:37:24 -07:00
Paolo Bonzini
4bc1260c51 fix C++ incompatibility in i386 back-end
2008-06-11  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/core-i386.h: Fix C++ incompatibility.
2008-06-11 08:01:15 -07:00
Laurent Michel
1e9000649c fix jit_replace8 for case when one of the operands is _EAX.
2008-06-10  Laurent Michel  <ldm@engr.uconn.edu>

	* lightning/i386/core-i386.h: Fix jit_replace8 for
	case when one of the operands is _EAX.
2008-06-10 16:47:07 -07:00
Paolo Bonzini
4865ed3451 fix several load/store patterns for x86-64.
2008-03-21  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/core-64.h: Fix jit_{ld,st}{,x}i_{i,l}.
	Remove jit_ld{,x}i_ul.
	* lightning/core-common.h: Make jit_ld{,x}{i,r}_ul
	always a synonym of the _l variant.
	* doc/porting.texi: Document this.
2008-03-21 09:08:38 +01:00
Paolo Bonzini
1014c9bb12 fix uses of jit_qop_ with 4 parameters
2008-03-19  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/core-64.h: Fix uses of jit_qop_.
2008-03-19 15:04:06 +01:00
Paolo Bonzini
f4bf06ad41 add long boolean operations for x86-64
2008-03-19  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/core-64.h: Add boolean operations.
2008-03-19 09:57:13 +01:00
Paolo Bonzini
00f73f17d4 add LEAQmr for x86-64
2008-03-19  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/asm-64.h: Add LEAQmr.
2008-03-19 09:57:12 +01:00
Paolo Bonzini
9a188c1b29 misc. x86-64 bugfixes
2008-03-19  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/core-64.h: Misc bugfixes.
2008-03-19 09:57:11 +01:00
Paolo Bonzini
90e08b1cda add missing x86-64 memory operations
2008-03-19  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/core-i386.c: Remove jit_ldr_i, jit_ldxr_i.
	* lightning/i386/core-32.h: Add jit_ldr_i, jit_ldxr_i.
	* lightning/i386/core-64.h: Add jit_ld{r,xr,i,xi}_{ui,l,ul},
	jit_ldr_i, jit_ldxr_i, jit_str_l, jit_stxr_l.
2008-03-19 09:56:19 +01:00
Paolo Bonzini
91cfad4175 add _s32P
2008-03-19  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/asm-common.h: Add _s32P.
2008-03-19 09:56:05 +01:00
Paolo Bonzini
ee99e520f5 implement long mul/div/mod for x86-64
2008-03-19  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/core-64.h: Implement long mul/div/mod.
2008-03-19 09:56:04 +01:00
Paolo Bonzini
1598681265 cast memory address to long for JCCim
2008-03-19  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/asm-i386.h: Cast memory address to long for JCCim.
2008-03-19 09:56:03 +01:00
Paolo Bonzini
ef5a3ab797 add underscores around __unused__ attribute
2008-03-15  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/asm-common.h: Add underscores around __unused__
	attribute.
2008-03-17 09:21:42 +01:00
Paolo Bonzini
3a199529db warning patrol (allocai.c, ppc)
2008-03-15  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/ppc/core.h: Avoid some "value computed is not used"
	warnings.
	* lightning/ppc/funcs.h: Remove unused variables.
	* lightnings/tests/allocai.c: Silence other warnings.
2008-03-17 09:10:57 +01:00
Paolo Bonzini
15a23d2a7c avoid "value computed is not used" in jit_allocai
2008-03-14  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/core-32.h: Avoid some "value computed is not used"
	warnings; reported by Sam Steingold.
2008-03-16 20:45:27 +01:00
Paolo Bonzini
d369edf15d Fix stxr_c(_EAX, _EBX, _ESI).
2008-03-08  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/core-32.h: Fix stxr_c(_EAX, _EBX, _ESI).
2008-03-08 18:21:07 +01:00
Paolo Bonzini
3b4343ec47 avoid redefinition of _r1
2008-02-13  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/asm-32.h: Avoid redefinition of _r1, reported by
	Sam Steingold.
	* lightning/i386/asm-64.h: Likewise.
2008-02-14 09:55:57 +01:00
Paolo Bonzini
9f2179f572 don't use _VOID symbol, reserved by newlib (cygwin)
2008-02-08  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/asm-i386.h: Don't define _VOID, reported
	by Reini Urban.
2008-02-08 13:30:18 +01:00
Paolo Bonzini
889d7fbf8b use CALLsr, not CALLLsr
2008-01-14  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/core-64.h: Use CALLsr, not CALLLsr.
2008-01-14 08:30:50 +01:00
Paolo Bonzini
07379b8a01 don't truncate function pointers on amd64
2008-01-13  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/core-i386.h: Move jit_calli and jit_callr...
	* lightning/i386/core-32.h: ... here.
	* lightning/i386/core-64.h: Redefine them.
2008-01-13 10:22:29 +01:00
Paolo Bonzini
950b2cefe9 fix i386 floating-point sub(a,0,a)
2008-01-05  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/fp-32.h: Fix sub(a,0,a).
	* lightning/tests/3to2.c: Add new testcases.
	* lightning/tests/3to2.ok: Add new testcases.

git-archimport-id: bonzini@gnu.org--2004b/lightning--stable--1.2--patch-61
2008-01-09 15:52:44 +01:00
Paolo Bonzini
329b8a8a68 add 3to2 test and fix bug
2008-01-02  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/fp-32.h: Fix sub(a,b,a) with a ~= JIT_FPR0.
	* lightning/tests/3to2.c: New.
	* lightning/tests/3to2.ok: New.

git-archimport-id: bonzini@gnu.org--2004b/lightning--stable--1.2--patch-58
2008-01-09 15:52:30 +01:00
Paolo Bonzini
d0d493b417 improve set* encoding for i386, add testcase
2007-08-12  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/core-i386.h: Improve encoding of set* instructions.
	* lightning/i386/core-64.h: Fix jit_bra_l.
	* tests/sete.c: New.
	* tests/sete.ok: New.

git-archimport-id: bonzini@gnu.org--2004b/lightning--stable--1.2--patch-56
git-archimport-id: bonzini@gnu.org--2004b/lightning--stable--1.2--patch-60
2008-01-09 15:50:14 +01:00
Paolo Bonzini
1551f5a787 switch to GPLv3
git-archimport-id: bonzini@gnu.org--2004b/lightning--stable--1.2--patch-55
2008-01-09 15:50:13 +01:00
Paolo Bonzini
b07a8d4ea1 add clean-local target to lightning/Makefile.am
Patches applied:

 * thomas.g.girard@free.fr--2007-archives/smalltalk--stable--2.3--patch-2
   fix lightning clean: target

git-archimport-id: bonzini@gnu.org--2004b/lightning--stable--1.2--patch-53
2008-01-09 15:50:11 +01:00
Paolo Bonzini
19f163bcaf use CVTT instruction, fix lightning/Makefile.am
2006-12-02  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/asm-i386.h: Add CVTTS?2SIL.
	* lightning/i386/asm-64.h: Add CVTTS?2SIQ.
	* lightning/i386/fp-64.h: Use it.

	* lightning/Makefile.am: Place files in nodist_lightning_HEADERS.

git-archimport-id: bonzini@gnu.org--2004b/lightning--stable--1.2--patch-52
2008-01-09 15:50:10 +01:00
Paolo Bonzini
67d0c9a3f1 merge from ludovic
Patches applied:

 * lcourtes@laas.fr--2005-libre/lightning--stable--1.2--patch-38
   Doc: Mention `JIT_R_NUM' and `JIT_V_NUM'.

 * lcourtes@laas.fr--2005-libre/lightning--stable--1.2--patch-43
   Removed C99/C++ comments from `asm-i386.h'.

git-archimport-id: bonzini@gnu.org--2004b/lightning--stable--1.2--patch-50
2008-01-09 15:50:07 +01:00
Paolo Bonzini
58c4dcea43 add floating-point for x86-64
git-archimport-id: bonzini@gnu.org--2004b/lightning--stable--1.2--patch-49
2008-01-09 15:50:06 +01:00
Paolo Bonzini
3a04a40aae merge some bugfixes, give right meaning to jit_retval_[fd]
2006-11-22  Paolo Bonzini  <bonzini@gnu.org>

	* lightning/i386/asm-i386.h: Move x86-64 instructions...
	* lightning/i386/asm-64.h: ... here.
	* lightning/i386/fp-32.h: Fix bugfixes worked around in froofyJIT.
	Add JIT_FPRET.
	* lightning/sparc/fp.h: Likewise.
	* lightning/ppc/fp.h: Likewise.
	* lightning/fp-common.h: Adjust for JIT_FPRET.
	* tests/funcfp.c: Adjust for JIT_FPRET.
	* tests/rpnfp.c: Adjust for JIT_FPRET.

git-archimport-id: bonzini@gnu.org--2004b/lightning--stable--1.2--patch-47
git-archimport-id: bonzini@gnu.org--2004b/lightning--stable--1.2--patch-48
2008-01-09 15:50:05 +01:00