Date: Fri, 26 Feb 1999 14:15:17 -0500 (EST) From: Michael Milendorf (Godin) - Sun BOS Firmware Subject: Item #458: 64-bit Extension Wordset is incomplete P1275 Open Firmware Working Group Proposal -- Proposal #:458 Ver 1.0 Title: 64-Bit Extension Wordset is incomplete Author: Michael Milendorf Date: February, 23, 1999 Ed/Tech: Technical Synopsis: 64-Bit Extension set lacks comparison, arithmetic, logical and shift operations. Doc & Version: IEEE Draft Std P1275.6/D5 Standard for Boot Firmware 64 Bit Extensions Problem: The 64-Bit Extension wordset as described in P1275.6/D5 represents neither the "core" set, i.e. an absolute minimum number of words which can not be defined through other FCode words, nor the "complete" set, which represents all 64-bit class basic operations needed to deal with 64-bit data, but rather something in between. The current document looks like an unfinished and incomplete set of words. Proposal: Acknowledging that all of the suggested additional 64-Bit extensions (as well as some of already existing extensions) could be defined in FCode, for the sake of the speed and simplicity, and for the reason of having "complete" set of basic operations, the existing 64-Bit Extension set of words could be complemented with the following additional words to manipulate 64-Bit data: x+ ( o1 o2 -- o3 ) F 0x255 Add o1 to o2 x- ( o1 o2 -- o3 ) F 0x256 Subtract o2 from o3 x* ( o1 o2 -- o3 ) F 0x257 Multiply o1 by o2 x/ ( o1 o2 -- o3 ) F 0x258 Divide o2 by o1, return quotient x< ( o1 o2 -- flag ) F 0x259 Return true if o1 is less than o2 x<= ( o1 o2 -- flag ) F 0x25a Return true if o1 is less than or equal to o2 x= ( o1 o2 -- flag ) F 0x25b Return true if o1 is equal to o2 x<> ( o1 o2 -- flag ) F 0x25c Return true if o1 is not equal to o2 x>= ( o1 o2 -- flag ) F 0x25d Return true if o1 is greater than or equal to o2 x> ( o1 o2 -- flag ) F 0x25e Return true of o1 is greater than o2 x-and ( o1 o2 -- o3 ) F 0x25f Return bitwise logical "and" of o1 and o2 x-or ( o1 o2 -- o3 ) F 0x260 Return bitwise logical "inclusive-or" of o1 and o2 x-xor ( o1 o2 -- o3 ) F 0x261 Return bitwise logical "exclusive-or" of o1 and o2 x-invert ( o1 -- o2 ) F 0x262 Invert all bits of o1 xlshift ( o1 u -- o2 ) F 0x263 Shift o1 left by u bit-places. Zero-fill low bits xrshift ( o1 u -- o2 ) F 0x264 Shift o1 right by u bit-places. Zero-fill high bits x>>a ( o1 u -- o2 ) F 0x265 Arithmetic shift o1 right by u bit-places x-mod ( o1 o2 -- rem ) F 0x266 Divide o1 by o2; return remainder [ P1275 Item #458 -- Received: Fri Feb 26 11:17:04 PST 1999 ]