From owner-svn-src-stable@freebsd.org Thu Sep 12 06:26:23 2019 Return-Path: Delivered-To: svn-src-stable@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 1E1C6EC933; Thu, 12 Sep 2019 06:26:23 +0000 (UTC) (envelope-from tsoome@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 46TTLQ6mWGz3Nvn; Thu, 12 Sep 2019 06:26:22 +0000 (UTC) (envelope-from tsoome@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id C702D1AAB9; Thu, 12 Sep 2019 06:26:22 +0000 (UTC) (envelope-from tsoome@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id x8C6QMAN072740; Thu, 12 Sep 2019 06:26:22 GMT (envelope-from tsoome@FreeBSD.org) Received: (from tsoome@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id x8C6QMx7072738; Thu, 12 Sep 2019 06:26:22 GMT (envelope-from tsoome@FreeBSD.org) Message-Id: <201909120626.x8C6QMx7072738@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: tsoome set sender to tsoome@FreeBSD.org using -f From: Toomas Soome Date: Thu, 12 Sep 2019 06:26:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-12@freebsd.org Subject: svn commit: r352241 - in stable/12/stand/ficl: . softwords X-SVN-Group: stable-12 X-SVN-Commit-Author: tsoome X-SVN-Commit-Paths: in stable/12/stand/ficl: . softwords X-SVN-Commit-Revision: 352241 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 12 Sep 2019 06:26:23 -0000 Author: tsoome Date: Thu Sep 12 06:26:22 2019 New Revision: 352241 URL: https://svnweb.freebsd.org/changeset/base/352241 Log: MFC r351865, r351837: ficl: add xemit word ficl: add uIsGreater word (needed for xemit) We need xemit to support userboot.so loading images from CURRENT. Modified: stable/12/stand/ficl/softwords/softcore.fr stable/12/stand/ficl/words.c Directory Properties: stable/12/ (props changed) Modified: stable/12/stand/ficl/softwords/softcore.fr ============================================================================== --- stable/12/stand/ficl/softwords/softcore.fr Thu Sep 12 06:20:20 2019 (r352240) +++ stable/12/stand/ficl/softwords/softcore.fr Thu Sep 12 06:26:22 2019 (r352241) @@ -199,6 +199,14 @@ set-current \ stop hiding words a-addr 0 b-addr b-u strcat ; +: xemit ( xchar -- ) + dup 0x80 u< if emit exit then \ special case ASCII + 0 swap 0x3F + begin 2dup u> while + 2/ >r dup 0x3F and 0x80 or swap 6 rshift r> + repeat 0x7F xor 2* or + begin dup 0x80 u< 0= while emit repeat drop + ; previous \ lose hidden words from search order Modified: stable/12/stand/ficl/words.c ============================================================================== --- stable/12/stand/ficl/words.c Thu Sep 12 06:20:20 2019 (r352240) +++ stable/12/stand/ficl/words.c Thu Sep 12 06:26:22 2019 (r352241) @@ -1930,6 +1930,18 @@ static void isGreater(FICL_VM *pVM) return; } +static void uIsGreater(FICL_VM *pVM) +{ + FICL_UNS u1, u2; +#if FICL_ROBUST > 1 + vmCheckStack(pVM, 2, 1); +#endif + u2 = stackPopUNS(pVM->pStack); + u1 = stackPopUNS(pVM->pStack); + PUSHINT(FICL_BOOL(u1 > u2)); + return; +} + static void bitwiseAnd(FICL_VM *pVM) { CELL x, y; @@ -4975,6 +4987,7 @@ void ficlCompileCore(FICL_SYSTEM *pSys) dictAppendWord(dp, "type", type, FW_DEFAULT); dictAppendWord(dp, "u.", uDot, FW_DEFAULT); dictAppendWord(dp, "u<", uIsLess, FW_DEFAULT); + dictAppendWord(dp, "u>", uIsGreater, FW_DEFAULT); dictAppendWord(dp, "um*", umStar, FW_DEFAULT); dictAppendWord(dp, "um/mod", umSlashMod, FW_DEFAULT); dictAppendWord(dp, "unloop", unloopCo, FW_COMPILE);