Raymond Toy [Sun, 24 Jun 2012 16:46:32 +0000]
Merge branch 'tcall-convention' of https://github.com/ellerh/cmucl into tcall-convention
Helmut Eller [Sat, 23 Jun 2012 17:41:24 +0000]
Remove TYPED-CALL-LOCAL vop.
The XEP no longer calls the unboxed entry point, so we don't this kind
of local call anymore.
Helmut Eller [Sat, 23 Jun 2012 17:32:50 +0000]
New file with tests for the unboxed calling convention.
Helmut Eller [Sat, 23 Jun 2012 17:20:15 +0000]
Be more careful when creating adapters.
* code/fdefinition.lisp (generate-adapter-function): Simply use :typed
convention instead of the :typed-no-xep. I removed :typed-no-xep as
it was probably a premature optimisation. Also switch directly to
full-call convention instead of trying to stay with typed convention.
(check-function-redefinition): Handle the case when the new function
doesn't have a typed entry point.
Helmut Eller [Sat, 23 Jun 2012 17:14:59 +0000]
For typed-call-named force new-fp into register.
We use the lea instruction so new-fp needs to be in a register.
Helmut Eller [Sat, 23 Jun 2012 17:12:45 +0000]
Lift restriction on number of return values.
Apparently we can return values on the stack just fine.
Don't allow ftypes with function-type-wild-args.
Helmut Eller [Sat, 23 Jun 2012 17:10:41 +0000]
Fix off-by-one error when choosing argument registers.
* compiler/x86/call.lisp (make-typed-call-tns): Use < not <= when
comparing with register-arg-count.
Helmut Eller [Sat, 23 Jun 2012 17:10:02 +0000]
Handle multiple-value-call with fixed numer of values.
* compiler/ir2tran.lisp (%typed-call-ir2-convert-optimizer): Don't use
multiple-value-call-named if the the callee returns a fixed number
of values. typed-call-named + move-continuation-result seems to
handle the multiple-value-call case just fine.
Helmut Eller [Sat, 23 Jun 2012 17:06:38 +0000]
Don't use typed calling convention with wild-args-type.
This shouldn't happen normally, but it did happen when I enabled the
typed calling convention for all defuns.
* compiler/ir1opt.lisp (recognize-known-call): Look at the ftype more
closesly. Also ignore known functions.
Helmut Eller [Sat, 23 Jun 2012 17:02:27 +0000]
Stop freaking out if *check-consistency* is T.
Make the checks aware of the typed entry point.
Helmut Eller [Sat, 23 Jun 2012 16:53:56 +0000]
No longer wire arg TNs of typed entry.
The XEP no longer calls the typed entry so we don't need wired locations.
* compiler/gtn.lisp (assign-typed-lambda-var-tns): Deleted.
(assign-normal-lambda-var-tns): Renamed back to assign-lambda-var-tns.
(typed-entry-point-type): Take the ftype from the optional-dispatch or
the main entry
* compiler/ir2tran.lisp (init-typed-entry-point-environment): Now move
args from wired locations to locations chosen by GTN. This seems to
cause fewer problem during packing.
Helmut Eller [Sat, 23 Jun 2012 16:51:24 +0000]
Take the type for the fasl file from the optional-dispatch.
Helmut Eller [Sat, 23 Jun 2012 16:45:36 +0000]
Don't delete the typed entry point as long as a XEP is there.
* compiler/envanal.lisp (environment-analyze): Don't delete the typed
entry point even if it has no references.
* compiler/ir1util.lisp (delete-optional-dispatch): But here delete
the typed entry too.
Helmut Eller [Sat, 23 Jun 2012 16:42:08 +0000]
Make typed entry point part of optional-dispatch.
Previously the typed entry point was a lambda with a marker in the
lambda-plist. Now the typed entry point is part of a
optional-dispatch struct. The previous approach kinda worked for
simple cases, but it was getting awkward when references to the XEP
had to be back-patched. The new approach seems to work better; it's
nice that both the main entry and the XEP can be reached from the
optional-dispatch.
* compiler/node.lisp (optional-dispatch): Add new slots. The typedp
slot is set during ir1trans and the actual entry point is generated
at the same time as the XEP. Doing it a little later lets the types
settle a bit better.
* compiler/ir1tran.lisp (ir1-convert-lambda): Create a hairy lambda
when for the typed calling convention.
(ir1-convert-hairy-args): Add new argument typedp and pass it to
constructor.
* compiler/locall.lisp (generate-typed-entry): New function
(make-xep-lambda): Remove the code for the old strategy.
(make-external-entry-point): Generate the typed entry point if typed
is true.
Raymond Toy [Sat, 23 Jun 2012 15:24:44 +0000]
Merge branch 'tcall-convention' of https://github.com/ellerh/cmucl into eller-typed-call
Helmut Eller [Fri, 22 Jun 2012 10:30:47 +0000]
Don't need fop-fset for typed entry points.
Helmut Eller [Fri, 22 Jun 2012 10:29:18 +0000]
Disable local inline expansion into typed entry points.
* compiler/locall.lisp (maybe-expand-local-inline): Treat
typed entry points like external entry points.
Helmut Eller [Fri, 22 Jun 2012 10:13:22 +0000]
Handle unused arguments.
* compiler/ir2tran.lisp (ir2-convert-local-typed-call): Skip over
unsed args.
Helmut Eller [Fri, 22 Jun 2012 10:09:49 +0000]
In %defun, closures and known functions are problematic.
For now, disable the typed convention for them.
Helmut Eller [Fri, 22 Jun 2012 10:07:35 +0000]
Be more careful when searching the typed entry point of functions.
The function might be a closure and we can't access the code object
for those.
Helmut Eller [Wed, 20 Jun 2012 09:00:39 +0000]
In the cross-build Make-rule, build PCL too.
Helmut Eller [Wed, 20 Jun 2012 08:59:48 +0000]
Load files into cross-compiler.
Helmut Eller [Wed, 20 Jun 2012 08:57:03 +0000]
Some small improvements in the linker code.
* code/fdenition.lisp (find-typed-entry-point): Enable sharing of
callsite objects if the types match.
(generate-adapter-function): Bind *derive-function-types* for stricter
type checks.
(check-function-redefinition): Handle case where the new function
doesn't have an entry point. Also use (:adapter <foo>) as name for
adapter functions.
(patch-fdefn): Take name as optional argument.
Helmut Eller [Wed, 20 Jun 2012 08:53:06 +0000]
Add support for wild/unknown return types.
* compiler/x86/call.lisp (make-typed-call-tns): If the number
of return values is not fixed return the symbol :unknown instead
of a list of TNs.
* compiler/gtn.lisp (return-info-for-typed-entry-point): For
:unknown number of return values use the standard return convention.
* compiler/ir2tran.lisp ([ir2convert] %typed-call): Generate
different code for :unknown number of return values.
* compiler/x86/call.lisp ([vop] typed-call-named): Take an additional
info argument NRESULTS that indicates that we should use standard
return convention.
* compiler/x86/call.lisp ([vop] multiple-typed-call-named): New vop.
Helmut Eller [Sun, 17 Jun 2012 19:04:47 +0000]
Pass XBOOTFILE as argument to cross-build-world.sh
Helmut Eller [Sun, 17 Jun 2012 19:02:17 +0000]
Use compile-file instead of comf in boot file.
Helmut Eller [Sun, 17 Jun 2012 19:01:17 +0000]
Use :typed-no-xep convention when creating for adapters.
Helmut Eller [Sun, 17 Jun 2012 18:02:47 +0000]
Call :typed-no-xep functions like the :typed convention.
This probably doesn't come up in practise but may be useful for
testing.
Helmut Eller [Sun, 17 Jun 2012 17:59:12 +0000]
Handle new cases for the :typed-no-xep.
Some lambdas are now both external-entry-point-p and
typed-entry-point-p and we need to handle those cases a bit more
carefully.
Helmut Eller [Sun, 17 Jun 2012 17:54:35 +0000]
Don't create a XEP for the :typed-no-xep calling convention.
The :typed-no-xep convention is intended for adapter functions where
the general XEP would not be used. Naming is a bit confusing now
as those typed entry points actually have the lambda-kind :external
so external-entry-point-p and typed-entry-point-p both return true.
Helmut Eller [Sun, 17 Jun 2012 07:39:25 +0000]
Add unsafe setter %set-fdefn-name.
That's useful for debugging.
Helmut Eller [Sat, 16 Jun 2012 21:56:30 +0000]
In comf, enter the debugger before Error Aborts.
Helmut Eller [Sat, 16 Jun 2012 21:52:11 +0000]
Add bootfiles/20c/tccxboot.lisp and using for the build.
In tools/cross-scripts/cross-x86-x86.lisp remove
the code that imports symbols from OLD-X86 into X86.
We don't want genesis to dump the OLD-X86 package.
Helmut Eller [Sat, 16 Jun 2012 21:50:25 +0000]
Add runtime support for linking.
For now that code lives in code/fdefinition.lisp.
Helmut Eller [Sat, 16 Jun 2012 21:46:25 +0000]
Add a new fop to find typed entries at load-time.
The function of a %type-call is loaded with the new vop.
Helmut Eller [Sat, 16 Jun 2012 21:42:41 +0000]
Generate special ir2 for %typed-calls.
Define the vop and export it.
Helmut Eller [Sat, 16 Jun 2012 21:38:13 +0000]
Update some places that require type/name of XEPs.
The functional-entry-function of a XEP may now be a typed entry point
but the old code assumed that its the main lambda.
Helmut Eller [Sat, 16 Jun 2012 21:31:53 +0000]
Add a function typed-entry-point-p to abstract a bit from representation.
Helmut Eller [Sat, 16 Jun 2012 21:26:58 +0000]
In probable-type-check-p, request type checking for the new convention.
With the typed convention the type checks should be performed in
the caller (normal :full calls check types in the callee).
:simple checks will be performed by he move-arg vops the
:hairy cases are done checkgen.
Helmut Eller [Sat, 16 Jun 2012 21:18:05 +0000]
In recognize-known-call, look at the calling-convention.
If basic-combination-kind to the function-finfo of %typed-call.
Struct accessors/setters are handled similarily. The problem with
this approach is that we can't have transforms/optmizers etc. when the
type calling convention is used. Add a function-info attribute to
handle that case (not implemented yet).
Helmut Eller [Fri, 15 Jun 2012 19:59:57 +0000]
Boot hack: define calling-convention before compiling compiler.
Helmut Eller [Fri, 15 Jun 2012 19:59:08 +0000]
Use x86-make-number-stack-pointer-tn instead of make-number-stack-pointer-tn.
Raymond Toy [Fri, 15 Jun 2012 19:52:24 +0000]
Change min_av_mem_age to be an int instead of double. No floating
point operations should occur in allocation or GC now, except when
printing stats.
Helmut Eller [Fri, 15 Jun 2012 19:28:28 +0000]
Compile target:code/exports before comcom.
Apparently needed now that export no longer acts at compile time.
Raymond Toy [Fri, 15 Jun 2012 19:19:47 +0000]
Update to asdf 2.22. Testsuite for asdf, using 2012-06, passes fine.
Helmut Eller [Fri, 15 Jun 2012 18:28:43 +0000]
Remove some random (load "target:code/exports").
Helmut Eller [Fri, 15 Jun 2012 18:25:51 +0000]
Add a new info type: calling-convention
Make defuns with a calling-convention declaration
known the info db.
Helmut Eller [Fri, 15 Jun 2012 18:23:39 +0000]
Export new vops from VM package.
Helmut Eller [Fri, 15 Jun 2012 18:22:10 +0000]
Create actual entry in code object for typed entry.
Also make it possible to call the typed entry from XEP.
Helmut Eller [Fri, 15 Jun 2012 18:10:06 +0000]
Assign lambda vars to the TNs as indicated by make-typed-call-tns.
For lambdas with the (entry-point :typed) declaration we wire
the arguments to the locations as dictated by the typed convention.
Helmut Eller [Fri, 15 Jun 2012 18:03:30 +0000]
Create special entry point if indicated.
If a lambda has a (calling-convention :typed) declartion
we create a the special entry point.
Helmut Eller [Fri, 15 Jun 2012 17:58:32 +0000]
Add a new vm-support-routine: make-typed-call-tns
This defines register/representation to use for a given function type.
Helmut Eller [Fri, 15 Jun 2012 17:51:22 +0000]
Add declarations: calling-convention and entry-point.
We use two new declarations for lambda to choose the
calling convention.
Raymond Toy [Tue, 12 Jun 2012 03:54:47 +0000]
Oops. Didn't mean for the gencgc.o rule to get included.
Helmut Eller [Mon, 11 Jun 2012 20:34:57 +0000]
Add my Makefile.
Raymond Toy [Sat, 2 Jun 2012 22:02:00 +0000]
Add comments about using clang instead of gcc on x86.
Raymond Toy [Fri, 1 Jun 2012 04:25:33 +0000]
Don't set dimension of array to 1 for the rest slots of a primitive
object.
Raymond Toy [Fri, 1 Jun 2012 02:55:27 +0000]
Update translation template.
Raymond Toy [Wed, 30 May 2012 03:17:47 +0000]
Update.
Raymond Toy [Wed, 30 May 2012 02:57:28 +0000]
Revert :file-attribute changes.
Raymond Toy [Mon, 28 May 2012 22:49:32 +0000]
Update with new :FILE-ATTRIBUTE external format, contributed by
Douglas Crosher.
Raymond Toy [Mon, 28 May 2012 16:47:36 +0000]
Remove extra closing parenthesis.
Raymond Toy [Mon, 28 May 2012 16:19:17 +0000]
Merge branch 'master' into ext-format-file-attribute
Raymond Toy [Mon, 28 May 2012 16:18:47 +0000]
Update with changes.
Raymond Toy [Mon, 28 May 2012 16:11:46 +0000]
Fix ticket:60
src/compiler/main.lisp:
o Remove special treatment of EXPORT (and others) in the compiler. I
think we only need to treat IN-PACKAGE and DEFPACKAGE specially.
src/contrib/defsyste/defsystem.lisp:
o Add FIND-SYSTEM to the defpackage export list for MAKE.
src/tools/hemcom.lisp:
o Add defpackage for hemlock-internals since export no longer has the
compile-time effect.
Raymond Toy [Sat, 26 May 2012 18:13:01 +0000]
Fix so this can build on 8-bit cmucl.
o Clean up reader conditionals in MAKE-FD-STREAM.
o Add dummy %SET-FD-STREAM-EXTERNAL-FORMAT for non-unicode.
Raymond Toy [Sat, 26 May 2012 16:13:34 +0000]
Use concatenate instead of format because format isn't available when
compiling.
Raymond Toy [Sat, 26 May 2012 15:24:55 +0000]
Debugger needs to open file with the appropriate external format.
Patch from Douglas.
Raymond Toy [Sat, 26 May 2012 15:24:22 +0000]
Add all the emacs format encodings. From Douglas.
Raymond Toy [Sat, 26 May 2012 05:50:38 +0000]
* {{{COMPILE-FILE}}} should not signal an error when given a list for
{{{:EXTERNAL-FORMAT}}}. Lists are needed to specify a composing
external format like {{{:DOS}}} or {{{:MAC}}}.
Raymond Toy [Sat, 26 May 2012 05:49:18 +0000]
First cut at :file-attribute external-format that determines the
format from the file contents ala emacs.
Raymond Toy [Fri, 25 May 2012 03:27:37 +0000]
Clear matching current exceptions when enabling new exceptions. This
prevents the exception from being resignaled immediately.
src/code/float-trap.lisp:
o Clear current and accrued exception bits that match any new enabled
exceptions specified by :traps.
src/general-info/release-20d.txt:
o Update.
Raymond Toy [Thu, 10 May 2012 06:14:00 +0000]
Add popcnt instruction and use it in logcount vop if :sse3 is a
feature.
* src/compiler/x86/arith.lisp
* Add vop for logcount that uses popcnt instruction.
* src/compiler/x86/insts.lisp
* Define popcnt instruction (but only for :sse3)
* src/general-info/release-20d.txt:
* Update.
Raymond Toy [Sun, 6 May 2012 06:33:11 +0000]
Link to www.cmucl.org.
Raymond Toy [Tue, 1 May 2012 03:10:53 +0000]
Update with more info that was left out.
Raymond Toy [Tue, 1 May 2012 03:08:50 +0000]
Update to ASDF2 2.21.
Raymond Toy [Tue, 1 May 2012 03:07:49 +0000]
Update.
Raymond Toy [Wed, 25 Apr 2012 20:48:32 +0000]
Handle case where we run out of octets in the middle of a two-octet
code.
Raymond Toy [Wed, 25 Apr 2012 05:20:39 +0000]
First cut at an external format for EUC-KR.
Raymond Toy [Wed, 25 Apr 2012 05:20:09 +0000]
Add some comments on what INVERT-TABLE (and GET-INVERSE) does and what
it returns.
Raymond Toy [Wed, 25 Apr 2012 05:09:39 +0000]
Fix typo in iso8859-2 external format.
* src/pcl/simple-streams/external-formats/iso8859-2.lisp:
* Fix typo.
* src/general-info/release-20d.txt:
* Update.
Raymond Toy [Wed, 25 Apr 2012 05:05:35 +0000]
Correct the type declarations for the state (for BOM).
Raymond Toy [Sat, 21 Apr 2012 21:06:44 +0000]
Fix some typos, change url to cmucl.org and add url to
trac.common-lisp.net/cmucl.
Raymond Toy [Sat, 21 Apr 2012 02:44:04 +0000]
Fix bug in handling the state BOM marker and also extend to work
composing external formats. The state BOM marker also needs to
indicate how long the BOM is.
* src/code/stream.lisp
* Handle the BOM marker correctly for composed format.
* Handle the new values for the state BOM marker.
* src/pcl/simple-streams/external-formats/utf-16.lisp
* Change BOM state marker to +2 and -2 instead of 1 and 2 to
indicate the length of the BOM.
* src/pcl/simple-streams/external-formats/utf-32.lisp
* Change BOM state marker to +4 and -4 instead of 1 and 2 to
indicate the length of the BOM.
Raymond Toy [Fri, 20 Apr 2012 16:35:43 +0000]
Oops. Debugging print accidentally left in.
Raymond Toy [Fri, 20 Apr 2012 16:34:48 +0000]
UTF-16-BE and UTF-16-LE external formats were returning the incorrect
number of octets for surrogate pairs. Two was returned instead of
four.
* src/pcl/simple-streams/external-formats/utf-16-be.lisp:
* src/pcl/simple-streams/external-formats/utf-16-le.lisp:
* Return correct number of octets
* src/general-info/release-20d.txt
* Update.
Raymond Toy [Fri, 20 Apr 2012 15:41:14 +0000]
Test for state change was wrong.
Raymond Toy [Thu, 19 Apr 2012 06:53:31 +0000]
Fix ticket:58. Handle the BOM character for utf-16 and utf-32. This
is a bit of a hack.
* src/code/stream.lisp:
* Check the state to see if a BOM was read. This critically depends
on knowing the format of the state variable for utf16 and utf32
formats, but the stream code shouldn't have to know the state
internals.
* src/general-info/release-20d.txt
* Update.
Raymond Toy [Thu, 19 Apr 2012 04:38:46 +0000]
Add many additional aliases to match glibc iconv aliases. Donated by
Douglas Crosher.
* src/pcl/simple-streams/external-formats/aliases
* Add additional aliases.
* src/general-info/release-20d.txt:
* Update
Raymond Toy [Wed, 18 Apr 2012 22:02:31 +0000]
Fix typo in external format for utf-32.
utf-32.lisp::
* Fix typo.
release-20d.txt::
* Update.
Raymond Toy [Fri, 30 Mar 2012 01:53:33 +0000]
Clarify a comment.
Raymond Toy [Thu, 29 Mar 2012 04:14:12 +0000]
Add comments, clean up code a little.
Raymond Toy [Thu, 29 Mar 2012 04:11:18 +0000]
Microoptimization: (logand x #xffffffff) can be just a register move
without and'ing. (If x is a signed-byte 32.)
Raymond Toy [Tue, 27 Mar 2012 23:38:23 +0000]
Update.
Raymond Toy [Tue, 27 Mar 2012 23:20:18 +0000]
Add contrib for packed SSE2 operations.
src/contrib/contrib.lisp:
o Define the module
src/contrib/packed-sse2/compile-packed-sse2.lisp:
o New file to compile the contrib.
src/contrib/packed-sse2/packed-sse2.lisp:
o New file implementing the packed sse2 vops and functions.
Raymond Toy [Tue, 27 Mar 2012 23:19:03 +0000]
Oops. Long-standing bug that cmu-contribs was defined so it couldn't
be loaded to get the other contribs.
Raymond Toy [Tue, 27 Mar 2012 21:22:11 +0000]
Set the generator costs for the complex multiply vops to be the number
of instructions. This gives the sse3 complex multiply vop a chance to
be used if SSE3 is available. (The user needs to :SSE3 to *FEATURES*
for this to work. The core of CMUCL only assumes SSE2 is available.)
Alex Goncharov [Sun, 4 Mar 2012 17:09:30 +0000]
.gitignore: add build-*
Raymond Toy [Sat, 3 Mar 2012 16:46:19 +0000]
Really update to 6.1.0!
Raymond Toy [Sat, 3 Mar 2012 15:46:53 +0000]
Update for snapshot.