[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

*To*: <srfi-32@xxxxxxxxxxxxxxxxx>*Subject*: Param ordering; < and <=*From*: "Ben Goetter (in the field)" <goetter@xxxxxxxxxx>*Date*: Mon, 22 Jul 2002 07:12:07 -0700*Delivered-to*: srfi-32@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx*Importance*: Normal*Organization*: The Mazama Network

"Operation currying" is a nice turn of phrase. Chez gets the parameter order right by taking the opportunity to make its SORT parameter order agree with Scheme's MAP, FOR-EACH, and APPLY. Yes, this is incompatible with Common Lisp, but it means that I-- I mean, a Scheme programmer-- will guess the parameter sequence correctly. Numerically, op< is less expensive than op<=. Assuming that a fixnum (lambda (x y) (< x y)) compiles to a signed-comparison sequence like (x86) MOV ax, [esp-4] ; y SUB ax, [esp-8] ; (< x y) JL g01 MOV ax, BOOLEAN_T ; #t JMP g02 g01: MOV ax, BOOLEAN_F ; #f g02: On the x86 and ARM, JL (BLT) tests two flag bits, whereas JLE (BLE) tests three. (For unsigned comparisons, JB (BCC) tests one flag bit, whereas JBE (BLS) tests two.)

**Follow-Ups**:**Re: Param ordering; < and <=***From:*felix

**Why***From:*shivers

**Re: Param ordering; < and <=***From:*David Feuer

- Prev by Date:
**cell recycling; reference implementation; param ordering; fresh lists** - Next by Date:
**Re: cell recycling; reference implementation; param ordering; fresh lists** - Previous by thread:
**Re: cell recycling; reference implementation; param ordering; fresh lists** - Next by thread:
**Re: Param ordering; < and <=** - Index(es):