]> gitweb.factorcode.org Git - factor.git/log
factor.git
12 years agosequences: improve docs for map-sum.
John Benediktsson [Wed, 9 Nov 2011 22:58:37 +0000 (14:58 -0800)]
sequences: improve docs for map-sum.

12 years agoio.files: add file-reader, file-writer mixins
Joe Groff [Wed, 9 Nov 2011 22:43:39 +0000 (14:43 -0800)]
io.files: add file-reader, file-writer mixins
This lets us do some trickery so that the stream-element-type propagates from <file-reader>/<file-writer>. For #376.

12 years agoio:read: don't resize output buffer if unnecessary
Joe Groff [Wed, 9 Nov 2011 22:29:12 +0000 (14:29 -0800)]
io:read: don't resize output buffer if unnecessary
Even with a short-circuit test in the VM primitives, resize still has an overly high runtime cost in tight loops. For #376.

12 years agoio.ports: make read-step TYPED:
Joe Groff [Wed, 9 Nov 2011 22:13:41 +0000 (14:13 -0800)]
io.ports: make read-step TYPED:
Eliminates more dispatch. For #376.

12 years agoio.buffers, io.ports: trim some dispatch
Joe Groff [Wed, 9 Nov 2011 21:31:02 +0000 (13:31 -0800)]
io.buffers, io.ports: trim some dispatch
For #376. Still some work to do.

12 years agotools.profiler.sampling: preliminary docs
Joe Groff [Wed, 9 Nov 2011 19:34:31 +0000 (11:34 -0800)]
tools.profiler.sampling: preliminary docs

12 years agovm: hand SIGALRM to signal pipe if not sampling
Joe Groff [Wed, 9 Nov 2011 07:37:22 +0000 (23:37 -0800)]
vm: hand SIGALRM to signal pipe if not sampling

12 years agodeques: fix help-lint
Joe Groff [Wed, 9 Nov 2011 07:27:33 +0000 (23:27 -0800)]
deques: fix help-lint

12 years agovm: fix build on windows
Joe Groff [Wed, 9 Nov 2011 07:17:51 +0000 (23:17 -0800)]
vm: fix build on windows

12 years agounix.signals: documentation and metadata
Joe Groff [Wed, 9 Nov 2011 07:12:10 +0000 (23:12 -0800)]
unix.signals: documentation and metadata

12 years agovm: make signal pipe nonblocking
Joe Groff [Wed, 9 Nov 2011 06:07:22 +0000 (22:07 -0800)]
vm: make signal pipe nonblocking
On the off chance the Factor end of the signal handler mechanism isn't listening, we don't want to tie up the VM because the pipe's buffer got full.

12 years agotools.profiler.sampling: top-down-max-depth report
Joe Groff [Tue, 8 Nov 2011 22:35:25 +0000 (14:35 -0800)]
tools.profiler.sampling: top-down-max-depth report
Fixes #366

12 years agotools.profiler.sampling: change some names around
Joe Groff [Tue, 8 Nov 2011 22:11:53 +0000 (14:11 -0800)]
tools.profiler.sampling: change some names around
Rename the versions of top-down etc. that take sample data to "top-down*" (from "(top-down)") so they don't look so scary to use. Change "get-raw-profile-data" to "most-recent-profile-data".

12 years agovm: don't send foreign samples to outer space
Joe Groff [Tue, 8 Nov 2011 21:59:12 +0000 (13:59 -0800)]
vm: don't send foreign samples to outer space

12 years agodeques: adding ?peek-front and ?peek-back.
John Benediktsson [Tue, 8 Nov 2011 21:20:56 +0000 (13:20 -0800)]
deques: adding ?peek-front and ?peek-back.

12 years agoio.backend: start signal thread after io-backend
Joe Groff [Tue, 8 Nov 2011 19:54:54 +0000 (11:54 -0800)]
io.backend: start signal thread after io-backend
The c-io-backend can't handle input-ports and raises an error during bootstrap.

12 years agovm: don't pass this to safepoint constructor
Joe Groff [Tue, 8 Nov 2011 19:06:00 +0000 (11:06 -0800)]
vm: don't pass this to safepoint constructor
It's bad juju and MSVC calls us out on it.

12 years agounix.process: take raise from unix.ffi
Joe Groff [Tue, 8 Nov 2011 18:42:51 +0000 (10:42 -0800)]
unix.process: take raise from unix.ffi
And fix introduced ambiguity between unix.ffi:kill and unix.process:kill

12 years agonew module unix.signals: app-level signal handlers
Joe Groff [Tue, 8 Nov 2011 18:15:44 +0000 (10:15 -0800)]
new module unix.signals: app-level signal handlers
example:

IN: scratchpad USING: unix.ffi unix.signals ;
Loading resource:basis/unix/signals/signals.factor
IN: scratchpad [ V{ "Me not that kind of orc!" "Me busy, leave me alone!" "Work work" "Zug zug" } pop print flush ] SIGINFO add-signal-handler
IN: scratchpad load: 0.60  cmd: factor 41541 running 0.28u 0.16s
Zug zug
load: 0.71  cmd: factor 41541 running 0.28u 0.16s
Work work
load: 0.71  cmd: factor 41541 running 0.28u 0.16s
Me busy, leave me alone!
load: 0.73  cmd: factor 41541 running 0.28u 0.16s
Me not that kind of orc!

12 years agovm: more commentary on lock_console() stuff
Joe Groff [Tue, 8 Nov 2011 16:52:52 +0000 (08:52 -0800)]
vm: more commentary on lock_console() stuff

12 years agoio.backend.unix: startup hook for signal-pipe
Joe Groff [Tue, 8 Nov 2011 07:07:00 +0000 (23:07 -0800)]
io.backend.unix: startup hook for signal-pipe

12 years agovm: don't mask SIGTTIN from stdin_loop
Joe Groff [Tue, 8 Nov 2011 06:19:18 +0000 (22:19 -0800)]
vm: don't mask SIGTTIN from stdin_loop
Fixes #360

12 years agoio.backend.unix: init-signal-pipe function
Joe Groff [Tue, 8 Nov 2011 05:14:41 +0000 (21:14 -0800)]
io.backend.unix: init-signal-pipe function
Currently just reads off signal numbers and drops them.

12 years agovm: interrupt stdin_loop when entering fep
Joe Groff [Tue, 8 Nov 2011 05:12:11 +0000 (21:12 -0800)]
vm: interrupt stdin_loop when entering fep
The stdin_loop thread will keep trying to consume input unless we stop it by sending it a signal. Use SIGUSR2 to stop the read syscall and a mutex to hold up the loop while the fep is active.

12 years agovm: write signals to pipe immediately
Joe Groff [Tue, 8 Nov 2011 02:53:07 +0000 (18:53 -0800)]
vm: write signals to pipe immediately
The whole point is to wake up the mx without waiting for the next safepoint derp

12 years agovm: move bignum.cpp includes to master.hpp
Joe Groff [Tue, 8 Nov 2011 01:44:21 +0000 (17:44 -0800)]
vm: move bignum.cpp includes to master.hpp
That way they get PCHed

12 years agovm: enqueue signals for FEP signals too
Joe Groff [Mon, 7 Nov 2011 22:05:31 +0000 (14:05 -0800)]
vm: enqueue signals for FEP signals too
Although SIGINT still can't interrupt the current Factor thread in a sane way, this will at least wake up the run loop when waiting for input and fix #348 when implemented at the application level.

12 years agoGNUmakefile: use PCH so compiler goes faster
Joe Groff [Mon, 7 Nov 2011 21:50:52 +0000 (13:50 -0800)]
GNUmakefile: use PCH so compiler goes faster
Also add more accurate dependencies on headers so "make" works right when headers change

12 years agovm: write async signals to pipe for multiplexer
Joe Groff [Mon, 7 Nov 2011 20:51:49 +0000 (12:51 -0800)]
vm: write async signals to pipe for multiplexer
also factor out safepoint logic into its own file

12 years agoio.launcher.windows: update tests for prompt
Joe Groff [Tue, 8 Nov 2011 08:09:25 +0000 (00:09 -0800)]
io.launcher.windows: update tests for prompt

12 years agovm: switch atomic::add to atomic::fetch_add
Joe Groff [Tue, 8 Nov 2011 01:58:53 +0000 (17:58 -0800)]
vm: switch atomic::add to atomic::fetch_add
Win32 only provides fetch-and-add, not add-and-fetch, and we don't really care. Rename the functions so the order of operations is clear.

12 years agolists: make lmap behave row-polymorphically
Joe Groff [Mon, 7 Nov 2011 18:37:13 +0000 (10:37 -0800)]
lists: make lmap behave row-polymorphically
Fix contributed by @bremac. Fixes #355.

12 years agocompiler.cfg: Change low-level IR constructors from ##foo to <##foo>
Doug Coleman [Mon, 7 Nov 2011 07:00:03 +0000 (23:00 -0800)]
compiler.cfg: Change low-level IR constructors from ##foo to <##foo>

12 years agocompiler.tree: Renamed high-level IR node constructors to <#foo> from #foo. Moving...
Doug Coleman [Mon, 7 Nov 2011 04:41:31 +0000 (20:41 -0800)]
compiler.tree: Renamed high-level IR node constructors to <#foo> from #foo. Moving towards making classes/word names not conflict.

12 years agovm: readable feps for more types
Joe Groff [Mon, 7 Nov 2011 04:26:10 +0000 (20:26 -0800)]
vm: readable feps for more types

12 years agovm: print type names instead of numbers in fep
Joe Groff [Mon, 7 Nov 2011 03:56:47 +0000 (19:56 -0800)]
vm: print type names instead of numbers in fep

12 years agolint: Add a word to find redundant word props like 'inline [flushable|foldable]'
Doug Coleman [Mon, 7 Nov 2011 03:33:07 +0000 (19:33 -0800)]
lint: Add a word to find redundant word props like 'inline [flushable|foldable]'

12 years agomath.functions: flushable and foldable don't do anything on inline words because...
Doug Coleman [Mon, 7 Nov 2011 03:25:53 +0000 (19:25 -0800)]
math.functions: flushable and foldable don't do anything on inline words because flushable and foldable work on call sites (#call nodes), and inlined words are inlined into another word's call site; they don't generate their own #call node.

12 years agocompiler.tree.dead-code: Rewrite /mod to /i or mod in the dead-code pass in the high...
Doug Coleman [Mon, 7 Nov 2011 03:20:33 +0000 (19:20 -0800)]
compiler.tree.dead-code: Rewrite /mod to /i or mod in the dead-code pass in the high level optimizer. Fixes #279.

12 years agotools.deploy.backend: fix vocab manifest parse
Joe Groff [Mon, 7 Nov 2011 02:57:12 +0000 (18:57 -0800)]
tools.deploy.backend: fix vocab manifest parse
We were absent-mindedly passing the VOCABS: line off as a vocab name itself. vocabs.loader doesn't put up with that anymore.

12 years agoRename lookup to lookup-word.
Doug Coleman [Sun, 6 Nov 2011 23:57:24 +0000 (15:57 -0800)]
Rename lookup to lookup-word.

12 years agowebapps.help: Load the navbar from a Factor word instead of hardcoding it into the...
Doug Coleman [Sun, 6 Nov 2011 20:16:46 +0000 (12:16 -0800)]
webapps.help: Load the navbar from a Factor word instead of hardcoding it into the template so that the glossary link works.

12 years agohtml.components: For the t:html tag, only wrap strings in unescaped so that other...
Doug Coleman [Sun, 6 Nov 2011 20:15:00 +0000 (12:15 -0800)]
html.components: For the t:html tag, only wrap strings in unescaped so that other objects can render.

12 years agowebapps.help: Change webapps.help search from post to get. Fixes #343.
Doug Coleman [Sat, 5 Nov 2011 07:07:16 +0000 (00:07 -0700)]
webapps.help: Change webapps.help search from post to get. Fixes #343.

12 years agohelp.html: fix glossary link.
Doug Coleman [Sat, 5 Nov 2011 07:05:58 +0000 (00:05 -0700)]
help.html: fix glossary link.

12 years agoMake edit-vocab work on an unloaded vocabulary.
Doug Coleman [Sat, 5 Nov 2011 06:33:18 +0000 (23:33 -0700)]
Make edit-vocab work on an unloaded vocabulary.

12 years agocpu.x86.*.bootstrap: save flags in signal-handlers
Joe Groff [Fri, 4 Nov 2011 18:56:01 +0000 (11:56 -0700)]
cpu.x86.*.bootstrap: save flags in signal-handlers

12 years agocpu.x86.bootstrap: cell -> bootstrap-cell
Joe Groff [Fri, 4 Nov 2011 18:54:40 +0000 (11:54 -0700)]
cpu.x86.bootstrap: cell -> bootstrap-cell

12 years agocpu.x86.assembler: PUSHF, POPF instructions
Joe Groff [Fri, 4 Nov 2011 18:23:11 +0000 (11:23 -0700)]
cpu.x86.assembler: PUSHF, POPF instructions

12 years agocpu.x86.64.bootstrap: save all the regs on signal
Joe Groff [Fri, 4 Nov 2011 17:01:39 +0000 (10:01 -0700)]
cpu.x86.64.bootstrap: save all the regs on signal
Appears to fix another sporadic crash from mason on x86-64. There's no reason to cut corners here, really.

12 years agoFix bootstrap. Add missing using on io.serial.linux. Fixes #351.
Doug Coleman [Fri, 4 Nov 2011 13:08:02 +0000 (06:08 -0700)]
Fix bootstrap. Add missing using on io.serial.linux. Fixes #351.

12 years agounix.ffi: add signal constants
Joe Groff [Fri, 4 Nov 2011 07:24:18 +0000 (00:24 -0700)]
unix.ffi: add signal constants

12 years agoswitch back to gcc from clang since it goes faster
Joe Groff [Fri, 4 Nov 2011 07:09:30 +0000 (00:09 -0700)]
switch back to gcc from clang since it goes faster

12 years agocpu.x86.bootstrap: don't safepoint in a safepoint
Joe Groff [Fri, 4 Nov 2011 03:19:01 +0000 (20:19 -0700)]
cpu.x86.bootstrap: don't safepoint in a safepoint
Safepointing in the signal-handler primitive causes a crash if the safepoint is guarded and the signal being handled was raised by a safepoint. Put our own RET in the subprimitive to bail out before the standard epilog gets written out. This tentatively appears to fix #349.

12 years agomakefile: add macosx-x86-fat target
Joe Groff [Fri, 4 Nov 2011 01:43:45 +0000 (18:43 -0700)]
makefile: add macosx-x86-fat target

12 years agoMove io.serial.unix to io.serial.linux, add platforms files. Move termios into io...
Doug Coleman [Thu, 3 Nov 2011 23:25:53 +0000 (16:25 -0700)]
Move io.serial.unix to io.serial.linux, add platforms files. Move termios into io.serial.linux.ffi vocab.

12 years agomason.release.branch: fix test
Joe Groff [Thu, 3 Nov 2011 22:40:24 +0000 (15:40 -0700)]
mason.release.branch: fix test

12 years agostack-checker.known-words: add ffi-signal-handlers
Joe Groff [Thu, 3 Nov 2011 22:20:42 +0000 (15:20 -0700)]
stack-checker.known-words: add ffi-signal-handlers

12 years agocpu.x86.32.bootstrap: typo
Joe Groff [Thu, 3 Nov 2011 20:07:13 +0000 (13:07 -0700)]
cpu.x86.32.bootstrap: typo

12 years agouse gcc-4.2 on OS X 10.5, or clang on Xcode 4
Joe Groff [Thu, 3 Nov 2011 19:17:54 +0000 (12:17 -0700)]
use gcc-4.2 on OS X 10.5, or clang on Xcode 4

12 years agoUpdate emacs for editors protocol.
Doug Coleman [Thu, 3 Nov 2011 19:02:06 +0000 (12:02 -0700)]
Update emacs for editors protocol.

12 years agovm: always generate safepoints in jit
Joe Groff [Thu, 3 Nov 2011 18:57:23 +0000 (11:57 -0700)]
vm: always generate safepoints in jit
Even if there's no stack frame we still need to safepoint before leaving the function. Fixes #332.

12 years agovm: restore sigaltstack setup on unix
Joe Groff [Thu, 3 Nov 2011 18:50:23 +0000 (11:50 -0700)]
vm: restore sigaltstack setup on unix
#ifdef __OpenBSD__ is different from #ifndef __OpenBSD

12 years agoAdd back the using for nested-comments. Wo shi ben dan...
Doug Coleman [Thu, 3 Nov 2011 18:47:57 +0000 (11:47 -0700)]
Add back the using for nested-comments. Wo shi ben dan...

12 years agoMake the require-hook throw an error if the vocabulary does not exist in the dictiona...
Doug Coleman [Thu, 3 Nov 2011 18:34:41 +0000 (11:34 -0700)]
Make the require-hook throw an error if the vocabulary does not exist in the dictionary or on disk. Move require docs to vocabs. Add unit tests for require. Fixes #339.

12 years agowebapp.help: making fonts more consistent. See #310.
John Benediktsson [Thu, 3 Nov 2011 15:30:44 +0000 (08:30 -0700)]
webapp.help: making fonts more consistent. See #310.

12 years agotools.profiler.sampling: mess with formatting more
Joe Groff [Thu, 3 Nov 2011 07:14:18 +0000 (00:14 -0700)]
tools.profiler.sampling: mess with formatting more

12 years agotools.profiler.sampling: cross-section report
Joe Groff [Thu, 3 Nov 2011 06:57:15 +0000 (23:57 -0700)]
tools.profiler.sampling: cross-section report
Also add depth to top-down reporting so we can tell what parameter to give cross-section

12 years agovm: reserve some more special-objects
Joe Groff [Thu, 3 Nov 2011 05:15:52 +0000 (22:15 -0700)]
vm: reserve some more special-objects
Need a jit-safepoint object to deal with #332, and ffi-signal-handler words for immediate signal handling during FFI calls

12 years agodlists: fix compile error
Doug Coleman [Thu, 3 Nov 2011 04:56:06 +0000 (21:56 -0700)]
dlists: fix compile error

12 years agotools.profiler.sampling: twiddle output format
Joe Groff [Thu, 3 Nov 2011 04:40:31 +0000 (21:40 -0700)]
tools.profiler.sampling: twiddle output format

12 years agovm: sample pc on windows
Joe Groff [Thu, 3 Nov 2011 04:18:31 +0000 (21:18 -0700)]
vm: sample pc on windows

12 years agovm: fix MSVC warnings
Joe Groff [Thu, 3 Nov 2011 03:26:53 +0000 (20:26 -0700)]
vm: fix MSVC warnings

12 years agoTweak the dlist equal? word.
Doug Coleman [Thu, 3 Nov 2011 02:53:40 +0000 (19:53 -0700)]
Tweak the dlist equal? word.

12 years agoImplement equal? on dlists. Fixes #338.
Doug Coleman [Thu, 3 Nov 2011 02:07:37 +0000 (19:07 -0700)]
Implement equal? on dlists. Fixes #338.

12 years agovocabs.loader: Fix spacing. Remove unit test.
Doug Coleman [Thu, 3 Nov 2011 01:17:14 +0000 (18:17 -0700)]
vocabs.loader: Fix spacing. Remove unit test.

12 years agoimages.loader.gtk: typo
Joe Groff [Thu, 3 Nov 2011 02:02:27 +0000 (19:02 -0700)]
images.loader.gtk: typo

12 years agoremove lingering mentions of macosx-ppc
Joe Groff [Thu, 3 Nov 2011 01:40:27 +0000 (18:40 -0700)]
remove lingering mentions of macosx-ppc

12 years agoHandle auto-user in fuel-connection.el. Fix suggested by Eungju Park.
Doug Coleman [Thu, 3 Nov 2011 01:13:31 +0000 (18:13 -0700)]
Handle auto-user in fuel-connection.el. Fix suggested by Eungju Park.

12 years agoRename (load-vocab) to (require), add tags.txt for "p" vocab loader test. Code format...
Doug Coleman [Thu, 3 Nov 2011 01:07:22 +0000 (18:07 -0700)]
Rename (load-vocab) to (require), add tags.txt for "p" vocab loader test. Code formatting.

12 years agoio.backend.unix.macosx: Remove duplicate USE:
Doug Coleman [Thu, 3 Nov 2011 00:47:15 +0000 (17:47 -0700)]
io.backend.unix.macosx: Remove duplicate USE:

12 years agoFix unit tests to give the sampling profiler something to profile.
Doug Coleman [Thu, 3 Nov 2011 00:46:50 +0000 (17:46 -0700)]
Fix unit tests to give the sampling profiler something to profile.

12 years agoFix require-hook
Doug Coleman [Thu, 3 Nov 2011 00:25:54 +0000 (17:25 -0700)]
Fix require-hook

12 years agoAdd stack effects for the sampling profiler
Doug Coleman [Thu, 3 Nov 2011 00:20:18 +0000 (17:20 -0700)]
Add stack effects for the sampling profiler

12 years agooops, typo in factor.sh
Joe Groff [Thu, 3 Nov 2011 00:18:26 +0000 (17:18 -0700)]
oops, typo in factor.sh

12 years agoremove BSD,solaris,etc. misc platform support code
Joe Groff [Thu, 3 Nov 2011 00:13:31 +0000 (17:13 -0700)]
remove BSD,solaris,etc. misc platform support code

12 years agoUnbreakify the new profiler, add a couple of unit tests to demonstrate displaying...
Doug Coleman [Thu, 3 Nov 2011 00:01:43 +0000 (17:01 -0700)]
Unbreakify the new profiler, add a couple of unit tests to demonstrate displaying output.

12 years agoAdd a unit test vocabulary for vocabs.loadeer.
Doug Coleman [Wed, 2 Nov 2011 23:47:53 +0000 (16:47 -0700)]
Add a unit test vocabulary for vocabs.loadeer.

12 years agoKeep the profiling results even when the quotation throws an exception.
Doug Coleman [Wed, 2 Nov 2011 23:47:27 +0000 (16:47 -0700)]
Keep the profiling results even when the quotation throws an exception.

12 years agoUse -reuseview in jedit by default.
Doug Coleman [Wed, 2 Nov 2011 23:47:10 +0000 (16:47 -0700)]
Use -reuseview in jedit by default.

12 years agoClean up formatting, rename load-vocab-hook to require-hook. Add a unit test for...
Doug Coleman [Wed, 2 Nov 2011 23:30:00 +0000 (16:30 -0700)]
Clean up formatting, rename load-vocab-hook to require-hook. Add a unit test for vocabs.loader.

12 years agoActually let the user pick an editor after editor protocol change.
Doug Coleman [Wed, 2 Nov 2011 20:41:46 +0000 (13:41 -0700)]
Actually let the user pick an editor after editor protocol change.

12 years agosequences: relate max, min, supremum, infimum docs
Joe Groff [Wed, 2 Nov 2011 20:43:06 +0000 (13:43 -0700)]
sequences: relate max, min, supremum, infimum docs
Suggested by @yac. Closes #321.

12 years agovm: count samples during unoptimized compiler
Joe Groff [Wed, 2 Nov 2011 06:40:46 +0000 (23:40 -0700)]
vm: count samples during unoptimized compiler

12 years agovm: fix scrub-league assert abuse
Joe Groff [Wed, 2 Nov 2011 06:02:14 +0000 (23:02 -0700)]
vm: fix scrub-league assert abuse

12 years agovm: forgot to add atomic.hpp
Joe Groff [Wed, 2 Nov 2011 04:16:40 +0000 (21:16 -0700)]
vm: forgot to add atomic.hpp

12 years agohashtables.identity: test assoc-like
Joe Groff [Wed, 2 Nov 2011 04:09:23 +0000 (21:09 -0700)]
hashtables.identity: test assoc-like

12 years agovm: separate 'current_gc_p' from 'current_gc'
Joe Groff [Wed, 2 Nov 2011 04:01:40 +0000 (21:01 -0700)]
vm: separate 'current_gc_p' from 'current_gc'
The 'current_gc' handle doesn't need to be volatile, just the state of GC-ness

12 years agovm: add atomic::load and atomic::store functions
Joe Groff [Wed, 2 Nov 2011 04:00:46 +0000 (21:00 -0700)]
vm: add atomic::load and atomic::store functions
Abstract out the fence-and-load and store-and-fence patterns

12 years agotools.profiler.sampling: fix stack effect name
Joe Groff [Wed, 2 Nov 2011 03:28:17 +0000 (20:28 -0700)]
tools.profiler.sampling: fix stack effect name