Juan Jose Garcia Ripoll
c2e2171dc0
Avoid recursive invocation of C1EXPR by allowing the C1 processors to act like macros, returning new forms to be processed. Remove also the CATCH for compiler errors, since we now rely on conditions for signal handling.
2011-12-27 12:36:52 +01:00
Juan Jose Garcia Ripoll
c4966bd006
base-char maps to unsigned char, not to "char".
2011-11-18 16:53:37 +01:00
Juan Jose Garcia Ripoll
69cc872fe5
The compiler only defines the FFI type unsigned-long-long when it exists.
2011-08-27 19:29:49 +02:00
Juan Jose Garcia Ripoll
c762dea2e7
Remove debug statements in cmpffi.lsp
2011-07-30 12:21:33 +02:00
Juan Jose Garcia Ripoll
4bf3b2ba21
Types uint8-t and int8-t were missing from the list of integer types.
2011-07-28 22:25:59 +02:00
Juan Jose Garcia Ripoll
7c434a97f3
The C compiler keeps the number of bits of every C integer type
2011-07-27 23:34:23 +02:00
Juan Jose Garcia Ripoll
43dd4b50fa
In C-INLINE forms, ## is replaced with a single hash # character.
2010-10-17 16:49:45 +02:00
Alexander Gavrilov
03049ee7e2
Make boxed SSE packs untyped for all purposes but printing.
...
Now the following rules hold:
- (type-of pack) = SSE-PACK
- (typep pack '*-SSE-PACK) = T
The compiler is tweaked to unbox unidentified packs as
__m128i (integer), assuming that a cast would be inserted
later if that is not what was needed.
2010-10-03 23:43:52 +02:00
Alexander Gavrilov
8f835233d6
Enable automatic coercion of SSE subtypes via _mm_cast* intrinsics.
...
Assume that any sse-pack subtype matches any other one in inline
expansion matcher, and insert casts when required.
This uses intrinsics that are present only in the recent versions
of compilers, so add fallback inline definitions to a header file.
2010-10-03 23:42:57 +02:00
Alexander Gavrilov
dcf08cd6c0
Warn about automatic boxing of SSE values in the compiler.
...
Since the whole point of SSE is high performance, boxing
defeats the purpose and should be immediately flagged.
Also enable marking functions so that the compiler warns
if they are not inlined.
2010-08-20 20:29:03 +02:00
Alexander Gavrilov
c348b6f948
Implement boxing and unboxing of SSE values in the compiler.
...
This makes the SSE types marginally usable via c-inline:
(defun foo (xx yy)
(let ((sum (ffi:c-inline
(xx yy) (:float-sse-pack :float-sse-pack)
:float-sse-pack
"_mm_add_ps(#0,#1)" :one-liner t)))
(ffi:c-inline (sum) (:float-sse-pack) :float-sse-pack
"_mm_mul_ps(#0,_mm_set1_ps(3.0))" :one-liner t)))
2010-08-20 20:29:03 +02:00
Juan Jose Garcia Ripoll
0abe27afb1
The object associated to the VV location is now stored in it
2010-06-05 23:16:17 +02:00
Juan Jose Garcia Ripoll
32a2e741c5
Place parenthesis around a coerced location
2010-06-03 21:46:49 +02:00
Juan Jose Garcia Ripoll
0d78102b09
More precise type inference for C-INLINE forms which return more than one value
2010-05-28 21:35:04 +02:00
Juan Jose Garcia Ripoll
8eb1456342
New functions to determine whether a type is a C number type
2010-05-28 15:50:28 +02:00
Juan Jose Garcia Ripoll
910e79852e
Instead of using system property lists, create dispatch tables for handling the C1, T1, C2 forms and others.
2010-05-26 12:12:57 +02:00
Juan Jose Garcia Ripoll
71946d2f3b
LOC-REPRESENTATION-TYPE now understands also jumps
2010-05-16 20:33:11 +02:00
Juan Jose Garcia Ripoll
554c43ab67
When in unsafe mode, do not use the checked functions to perform C<->Lisp type coercions
2010-05-15 16:56:53 +02:00
Juan Jose Garcia Ripoll
6f9321e3b0
C-INLINE forms get the side effects field from its expansion
2010-05-13 11:29:50 +02:00
Juan Jose Garcia Ripoll
9e46f3d357
Introduce policy aliases, interned some declaration names in EXT and replaced some of those names with more meaningful ones.
2010-05-09 19:41:04 +02:00
Juan Jose Garcia Ripoll
a701663b62
Compiler policies are now defined as flags
2010-05-08 13:31:40 +02:00
Juan Jose Garcia Ripoll
fb55d5151d
The special form C-INLINE was destructively manipulating its arguments.
2010-05-08 00:35:18 +02:00
Juan Jose Garcia Ripoll
d8abf4d4b7
Use hash tables to store representation type properties.
2010-05-08 00:31:53 +02:00
Juan Jose Garcia Ripoll
6a57070b93
ECL defines the feature :LONG-LONG when this type is in the C compiler
2010-04-23 19:39:58 +02:00
Juan Jose Garcia Ripoll
cbc50ceab2
The newline character has to be _before_ each string in clines
2010-03-13 09:46:36 +01:00
Juan Jose Garcia Ripoll
3102c32ef4
FFI:CLINES admits @lisp-object notation in the strings.
2010-03-13 01:16:50 +01:00
Juan Jose Garcia Ripoll
3b412f3b3a
Relax coercion errors. Sometimes lousy programmers just leave code branches that are
...
not going to be executed and will cause the wrong type.
2009-08-04 19:28:44 +02:00
Juan Jose Garcia Ripoll
69725f20c6
The compiler now emits more accurate conversions from and to C types using the new functions (See CHANGELOG for the problem solved)
2009-07-15 15:19:43 +02:00
Juan Jose Garcia Ripoll
d2e864e74a
Allow c-inline, one-liner forms to output values in the VALUES register.
2009-07-09 10:36:01 +02:00
Juan Jose Garcia Ripoll
0ea425866c
Organize the code in INLINE-ARGS, factoring out parts that can be used in call-global-loc and allowing the use of temporary variables which are not of type :cl-object.
2009-07-04 17:17:50 +02:00
Juan Jose Garcia Ripoll
d73d12ae35
Replaced some calls to ERROR with CMPERR so that they can be trapped by the user. Changed the implementation of WITH-COMPILER-ENV to avoid that all COMPILER-ERRORs are re-signaled as compiler internal errors.
2009-06-25 11:01:41 +02:00
Juan Jose Garcia Ripoll
5008fdd45f
Big patch for introducing NaNs and infinities.
2009-06-04 15:55:13 +02:00
Juan Jose Garcia Ripoll
d4c9460c32
Fix the criteria for using inlined expansions from sysfun.lsp.
2009-03-06 23:51:17 +01:00
Juan Jose Garcia Ripoll
150398b8b1
Extended strings are now arrays of 32-bit integers.
2009-02-07 19:54:34 +01:00
Juan Jose Garcia Ripoll
c9b36e4005
Merged the new_signals branch.
2008-12-23 12:08:29 +01:00
Juan Jose Garcia Ripoll
2f4aa7aa96
The unsafe inline forms for CHAR/CHAR-SET do not handle Unicode strings properly.
2008-12-08 14:39:28 +01:00
Juan Jose Garcia Ripoll
7c5ab4f1fb
Some functions now take a cl_env_ptr argument, becoming better isolated.
2008-10-11 22:32:54 +02:00
Juan Jose Garcia Ripoll
3684f6c8e2
Fixed typo
2008-09-05 00:03:57 +02:00
Juan Jose Garcia Ripoll
a3785ea2a3
Remove debug statement.
2008-09-04 23:48:09 +02:00
Juan Jose Garcia Ripoll
82b5a84391
The syntax for the saved variables in a C-INLINE form conflicts with things like "@(return 0) = ..."
2008-09-04 23:36:55 +02:00
jjgarcia
e86c6ec83d
Teach the compiler how to coerce (unsigned-)short
2008-08-28 09:13:27 +00:00
jjgarcia
2ef8b05d4b
Added support for long double types in the compiler
2008-08-02 18:30:48 +00:00
jgarcia
4e46efac3f
Automatically generate type checks for arguments of a lambda form if the safety settings are high enough
2008-05-12 08:16:44 +00:00
jgarcia
a59f90871a
Emacs modelines for better editing
2008-02-02 19:14:05 +00:00
jgarcia
aa3dfe4058
Prefix most functions with 'ecl_' to avoid name collisions when embedding ECL in other libraries
2007-01-18 11:46:07 +00:00
jgarcia
16644c4382
Extend the location type LCL to include a representation type
2007-01-06 15:58:11 +00:00
jgarcia
21482f1c44
Remove unused variable
2007-01-06 15:22:39 +00:00
jgarcia
d2bc1e2b32
Fix typo in the compiler and include FOREIGN-DATA as fundamental data type in SUBTYPEP
2007-01-05 19:00:01 +00:00
jgarcia
644193ed56
Unicode support via wctype.h for most character handling functions.
2006-11-10 21:01:48 +00:00
jgarcia
8958390eae
MAKE-STRING with Unicode accepts arbitrary type specifiers. New function ecl_base_char_code() used to coerce objects to char and unsigned
2006-10-27 21:40:34 +00:00