4,499
edits
mNo edit summary |
mNo edit summary |
||
Line 21: | Line 21: | ||
The system implemented [[Phil Abrams]]' [[subscript calculus]] by storing the [[rank]] and [[shape]] of an array, along with delta and offset vectors, separately from its data—that is, the [[ravel]], but not necessarily in [[ravel order]]. This system allowed [[Take]], [[Drop]], [[Reverse]], [[Transpose]], and [[Reshape]] to be implemented only by manipulating the shape and other fields, not the data itself. In combination with APL\3000's [[reference count]]ing system, this allowed even arrays with different shapes to share the same data. Arrays whose data was a linear function of the index were stored as [[arithmetic progression vector]]s, omitting the data entirely. | The system implemented [[Phil Abrams]]' [[subscript calculus]] by storing the [[rank]] and [[shape]] of an array, along with delta and offset vectors, separately from its data—that is, the [[ravel]], but not necessarily in [[ravel order]]. This system allowed [[Take]], [[Drop]], [[Reverse]], [[Transpose]], and [[Reshape]] to be implemented only by manipulating the shape and other fields, not the data itself. In combination with APL\3000's [[reference count]]ing system, this allowed even arrays with different shapes to share the same data. Arrays whose data was a linear function of the index were stored as [[arithmetic progression vector]]s, omitting the data entirely. | ||
Multiple functions could be combined into a single step using [[deferred evaluation|dragalong]] and beating, also designed by Abrams. Dragalong was implemented by walking up a syntax tree to propagate rank and shape information before compilation, while beating refers to subscript calculus optimizations performed during this process. Combined functions such as <source inline>RANK</source>, produced from two adjacent [[Shape]] functions, and <source inline>POLYCAT</source>, from multiple copies of [[Catenate]] could be generated in this step. | Multiple functions could be combined into a single step using [[deferred evaluation|dragalong]] and beating, also designed by Abrams. Dragalong was implemented by walking up a syntax tree to propagate rank and shape information before compilation, while beating refers to subscript calculus optimizations performed during this process. Combined functions such as <source inline lang=apl>RANK</source>, produced from two adjacent [[Shape]] functions, and <source inline lang=apl>POLYCAT</source>, from multiple copies of [[Catenate]] could be generated in this step. | ||
APL\3000's unlimited [[workspace]] size was implemented using a [[wikipedia:virtual memory|virtual memory]] system capable of paging parts of the workspace to disk. The least recently used page was always chosen to be paged out. | APL\3000's unlimited [[workspace]] size was implemented using a [[wikipedia:virtual memory|virtual memory]] system capable of paging parts of the workspace to disk. The least recently used page was always chosen to be paged out. | ||
Line 32: | Line 32: | ||
The following control structures were provided in APLGOL: | The following control structures were provided in APLGOL: | ||
* <source inline>BEGIN statement list END</source> | * <source inline lang=apl>BEGIN statement list END</source> | ||
* <source inline>IF test DO statement</source> | * <source inline lang=apl>IF test DO statement</source> | ||
* <source inline>IF test THEN statement ELSE statement</source> | * <source inline lang=apl>IF test THEN statement ELSE statement</source> | ||
* <source inline>WHILE test DO statement</source> | * <source inline lang=apl>WHILE test DO statement</source> | ||
* <source inline>REPEAT statement list UNTIL test</source> | * <source inline lang=apl>REPEAT statement list UNTIL test</source> | ||
* <source inline>CASE expression OF constant BEGIN ... END CASE</source> | * <source inline lang=apl>CASE expression OF constant BEGIN ... END CASE</source> | ||
Functions were written with the <source inline>PROCEDURE</source> command: | Functions were written with the <source inline lang=apl>PROCEDURE</source> command: | ||
<source>PROCEDURE header: statement list END PROCEDURE</source> | <source lang=apl>PROCEDURE header: statement list END PROCEDURE</source> | ||
An <source inline>ASSERT</source> command was also provided to allow the programmer to check conditions during execution. | An <source inline lang=apl>ASSERT</source> command was also provided to allow the programmer to check conditions during execution. | ||
<source>ASSERT level: boolean expression</source> | <source lang=apl>ASSERT level: boolean expression</source> | ||
The <source inline>level</source> parameter allowed for inline execution. | The <source inline lang=apl>level</source> parameter allowed for inline execution. | ||
== Publications == | == Publications == |