From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Andy Wingo Newsgroups: gmane.lisp.guile.devel Subject: Re: Patches for wip-rtl Date: Tue, 23 Apr 2013 12:13:05 +0200 Message-ID: <87fvyhimha.fsf@pobox.com> References: <871ua2jo4l.fsf@pobox.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1366711998 13798 80.91.229.3 (23 Apr 2013 10:13:18 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 23 Apr 2013 10:13:18 +0000 (UTC) Cc: guile-devel To: Noah Lavine Original-X-From: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Tue Apr 23 12:13:22 2013 Return-path: Envelope-to: guile-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1UUaDw-0003bR-5X for guile-devel@m.gmane.org; Tue, 23 Apr 2013 12:13:20 +0200 Original-Received: from localhost ([::1]:39466 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UUaDv-0008SW-O7 for guile-devel@m.gmane.org; Tue, 23 Apr 2013 06:13:19 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:59089) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UUaDq-0008Qm-Ee for guile-devel@gnu.org; Tue, 23 Apr 2013 06:13:16 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UUaDl-0002LZ-Ee for guile-devel@gnu.org; Tue, 23 Apr 2013 06:13:14 -0400 Original-Received: from a-pb-sasl-quonix.pobox.com ([208.72.237.25]:35720 helo=sasl.smtp.pobox.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UUaDl-0002LI-9P for guile-devel@gnu.org; Tue, 23 Apr 2013 06:13:09 -0400 Original-Received: from sasl.smtp.pobox.com (unknown [127.0.0.1]) by a-pb-sasl-quonix.pobox.com (Postfix) with ESMTP id B75FCB3A3; Tue, 23 Apr 2013 06:13:08 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=pobox.com; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type; s=sasl; bh=yZr2btq2ZMHlf7j10IgoYDTaHH4=; b=KPJ6eW xBgRLwo+J+mcQ3TPE+DvCVOEBeVrmBKDLKNe3PSwHAM/SwFE/1t0VEpUPfMvfyzd zJ2A+ELYI8XpB116uY/lC4eGDAY+fqB3U5fBno922VKbZ/Qq40ZyfPLyBvVAIhWu yWENYkAYmP/+/wGrIGSc+37i8TNdu8+c3foxQ= DomainKey-Signature: a=rsa-sha1; c=nofws; d=pobox.com; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type; q=dns; s=sasl; b=PQ2kPEwO/mfAAAxa8BN+7Q6hSZL4o6Rk KrXk0MY2Gl7QbguU3nBCZUQEdwjN9WIE848b4RZQ03Py5mUqzdquLVIN3Kpt0OY7 JWXzSXKh4iIG5sVEoKgSN+2MnSAk1w3l2sllWB+XEzGFwL6I1WD7LH+sdW6cz1dC LSDs3sZvVEM= Original-Received: from a-pb-sasl-quonix.pobox.com (unknown [127.0.0.1]) by a-pb-sasl-quonix.pobox.com (Postfix) with ESMTP id B06E6B3A2; Tue, 23 Apr 2013 06:13:08 -0400 (EDT) Original-Received: from badger (unknown [88.160.190.192]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by a-pb-sasl-quonix.pobox.com (Postfix) with ESMTPSA id 1D57AB3A1; Tue, 23 Apr 2013 06:13:07 -0400 (EDT) In-Reply-To: (Noah Lavine's message of "Mon, 22 Apr 2013 22:38:02 -0400") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2 (gnu/linux) X-Pobox-Relay-ID: 65332D9C-ABFE-11E2-A637-C8310E5B5709-02397024!a-pb-sasl-quonix.pobox.com X-detected-operating-system: by eggs.gnu.org: Solaris 10 X-Received-From: 208.72.237.25 X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Developers list for Guile, the GNU extensibility library" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Original-Sender: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.devel:16291 Archived-At: Heya, On Tue 23 Apr 2013 04:38, Noah Lavine writes: > I assume you're talking about the box-ref and box-set! stuff with > checking for non-variables, right? I agree in general, but those > instructions could plausibly be emitted for any code that uses module > introspection to get its own variable objects, right? Ah I see what you mean. There are two uses of variables in the VM: one for calls to variable-ref or variable-set, and the other for internal use. For the internal uses, we know the variable should indeed be a variable and so we should emit the checks. For calls to variable-ref / variable-set, I think it would be best if somehow the compiler could replace those calls with (if (call variable? x) (primcall box-ref x) (call error ...)). Dunno. WDYT? > One thing that would be interesting - and I don't know if we do this > now - is using different VMs for different parts of the > code. Specifically, if the REPL ran in a different VM than user code, > then the REPL wouldn't die in these cases. That might also enable > cool debugging things, like single-stepping the user VM and examining > its registers. I noticed that we already have support for changing the > active VM. What do you think? We can do that already to a degree... probably the best "fallback" that we have is the stack VM, actually. What happens if you install traps on the VM that call stack VM procedures and then you run an RTL function? I would think that you should be able to do something useful there. Just a thought! Andy -- http://wingolog.org/