Home My Page Projects Code Snippets Project Openings SML/NJ
Summary Activity Forums Tracker Lists Tasks Docs Surveys News SCM Files

SCM Repository

[smlnj] Diff of /sml/trunk/HISTORY
ViewVC logotype

Diff of /sml/trunk/HISTORY

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1168, Fri Mar 22 19:19:32 2002 UTC revision 1212, Tue May 21 16:34:29 2002 UTC
# Line 13  Line 13 
13  Description:  Description:
14    
15  ----------------------------------------------------------------------  ----------------------------------------------------------------------
16    Name: Matthias Blume
17    Date: 2002/05/21 12:35:00 EDT
18    Tag: blume-20020521-cmdoc
19    Description:
20    
21    CM documentation update.
22    
23    ----------------------------------------------------------------------
24    Name: Matthias Blume
25    Date: 2002/05/21 10:55:00 EDT
26    Tag: blume-20020521-misc
27    Description:
28    
29    - John tweaked runtime to be silent on heap export (except when
30      GC messages are on).
31    - I added a few more things (cross-compiling versions of CMB) to
32      config/preloads (as suggestions).
33    
34    ----------------------------------------------------------------------
35    Name: Matthias Blume
36    Date: 2002/05/20 22:25:00 EDT
37    Tag: blume-20020520-controls
38    Description:
39    
40    - Added ControlUtil structure to control-lib.cm.
41    - Use it throughout.
42    - Used Controls facility to define MLRISC controls (as opposed to
43      registering MLRISC control ref cells with Controls after the fact)
44    - Fixed messed-up controls priorities.
45    
46    * Removed again all the stuff from config/preloads that one wouldn't
47      be able to preload at the time the initial heap image is built.
48      (Many libraries, e.g., CML, do not exist yet at this time.  The
49       only libraries that can be preloaded via config/preloads are those
50       that come bundled with the bootfiles.)
51    
52    ----------------------------------------------------------------------
53    Name: Matthias Blume
54    Date: 2002/05/20 10:59:00 EDT
55    Tag: blume-20020520-preloads
56    Description:
57    
58    Added a lot of commented-out suggestions for things to be included
59    in config/preloads.
60    
61    ----------------------------------------------------------------------
62    Name: Allen Leung
63    Date: 2002/05/18 14:20:00 EDT
64    Tag: leunga-20020518-mdl
65    Description:
66    
67    o Made the mdl tool stuff compile and run again.
68    o I've disabled all the stuff that depends on RTL specifications; they
69      are all badly broken anyway.
70    
71    ----------------------------------------------------------------------
72    Name: Matthias Blume
73    Date: 2002/05/17 16:49:00 EDT
74    Tag: blume-20020517-controls
75    Description:
76    
77    0. John Reppy made several modifications to the SML/NJ library.
78       In particular, there is a shiny new controls-lib.cm.
79    
80    1. Pushed new controls interface through compiler so that everything
81       compiles again.
82    
83    2. Added FormatComb and FORMAT_COMB to the CML version of the
84       SML/NJ library (so that CML compiles again).
85    
86    3. Modified init scripts because XXX_DEFAULT environment variables
87       are no longer with us.  (Boot-time initialization is now done
88       using the same environment variables that are also used for
89       startup-time initialization of controls.)
90    
91    ----------------------------------------------------------------------
92    Name: Lal George
93    Date: 2002/05/15 09:20:10 EDT
94    Tag: george-20020515-pseudo-op-decls
95    Description:
96    
97            All pseudo-ops emitted before the first segment declaration
98    such as TEXT, DATA, and BSS directives are assumed to be global
99    declarations and are emitted first in the assembly file. This is
100    useful in a number of situations where one has pseudo-ops that are not
101    specific to any segment, and also works around the constraint that one
102    cannot have client pseudo-ops in the TEXT segment.
103    
104            Because no segment is associated with these declarations it is
105    an error to allocate any space or objects before the first segment
106    directive and an exception will be raised. However, we cannot make
107    this check for client pseudo-ops.
108    
109            These top level declarations are a field in the CFG graph_info.
110    In theory you can continue to add to this field after the CFG has been
111    built -- provided you know what you are doing;-)
112    
113    ----------------------------------------------------------------------
114    Name: Matthias Blume
115    Date: 2002/05/13 16:40:00 EDT
116    Tag: blume-20020513-pp-etc
117    Description:
118    
119    A few minor bugfixes:
120    
121      - Stopgap measure for bug recently reported by Elsa Gunter (ppDec).
122        (Bogus printouts for redefined bindings still occur.  Compiler
123        bug should no longer occur now.  We need to redo the prettyprinter
124        from scratch.)
125    
126      - CM pathname printer now also adds escape sequences for ( and )
127    
128      - commend and docu fixes for ml-nlffi
129    
130    ----------------------------------------------------------------------
131    Name: Matthias Blume
132    Date: 2002/05/10 16:40:00 EDT
133    Tag: blume-20020510-erg-textio
134    Description:
135    
136    Applied the following bugfix provided by Emden Gansner:
137    
138        Output is corrupted when outputSubstr is used rather than output.
139    
140        The problem occurs when a substring
141    
142            ss = (s, dataStart, dataLen)
143    
144        where dataStart > 0, fills a stream buffer with avail bytes left.
145        avail bytes of s, starting at index dataStart, are copied into the
146        buffer, the buffer is flushed, and then the remaining dataLen-avail
147        bytes of ss are copied into the beginning of the buffer. Instead of
148        starting this copy at index dataStart+avail in s, the current code
149        starts the copy at index avail.
150    
151        Fix:
152        In text-io-fn.sml, change line 695 from
153             val needsFlush = copyVec(v, avail, dataLen-avail, buf, 0)
154        to
155             val needsFlush = copyVec(v, dataStart+avail, dataLen-avail, buf, 0)
156    
157    ----------------------------------------------------------------------
158    Name: Matthias Blume
159    Date: 2002/04/12 13:55:00 EDT
160    Tag: blume-20020412-assyntax
161    Description:
162    
163    1. Grabbed newer assyntax.h from the XFree86 project.
164    2. Fiddled with how to compile X86.prim.asm without warnings.
165    3. (Very) Minor cleanup in CM.
166    
167    ----------------------------------------------------------------------
168    Name: Matthias Blume
169    Date: 2002/04/01 (no joke!) 17:07:00 EST
170    Tag: blume-20020401-x86div
171    Description:
172    
173    Added full support for div/mod/rem/quot on the x86, using the machine
174    instruction's two results (without clumsily recomputing the remainder)
175    directly where appropriate.
176    
177    Some more extensive power-of-two support was added to the x86 instruction
178    selector (avoiding expensive divs, mods, and muls where they can be
179    replaced with cheaper shifts and masks).  However, this sort of thing
180    ought to be done earlier, e.g., within the CPS optimizer so that
181    all architectures benefit from it.
182    
183    The compiler compiles to a fixed point, but changes might be somewhat
184    fragile nevertheless.  Please, report any strange things that you might
185    see wrt. div/mod/quot/rem...
186    
187    ----------------------------------------------------------------------
188    Name: Matthias Blume
189    Date: 2002/03/29 17:22:00
190    Tag: blume-20020329-div
191    Description:
192    
193    Fixed my broken div/mod logic.  Unfortunately, this means that the
194    inline code for div/mod now has one more comparison than before.
195    Fast paths (quotient > 0 or remainder = 0) are not affected, though.
196    The problem was with quotient = 0, because that alone does not tell
197    us which way the rounding went.  One then has to look at whether
198    remainder and divisor have the same sign...  :(
199    
200    Anyway, I replaced the bootfiles with fresh ones...
201    
202    ----------------------------------------------------------------------
203    Name: Matthias Blume
204    Date: 2002/03/29 14:10:00 EST
205    Tag: blume-20020329-inlprims
206    Description:
207    
208    NEW BOOTFILES!!!    Version number bumped to 110.39.3.
209    
210    Primops have changed. This means that the bin/boot-file formats have
211    changed as well.
212    
213    To make sure that there is no confusion, I made a new version.
214    
215    
216    CHANGES:
217    
218    * removed REMT from mltree (remainder should never overflow).
219    
220    * added primops to deal with divisions of all flavors to the frontend
221    
222    * handled these primops all the way through so they map to their respective
223      MLRISC support
224    
225    * used these primops in the implementation of Int, Int32, Word, Word32
226    
227    * removed INLDIV, INLMOD, and INLREM as they are no longer necessary
228    
229    * parameterized INLMIN, INLMAX, and INLABS by a numkind
230    
231    * translate.sml now deals with all flavors of INL{MIN,MAX,ABS}, including
232      floating point
233    
234    * used INL{MIN,MAX,ABS} in the implementation of Int, Int32, Word, Word32,
235      and Real (but Real.abs maps to a separate floating-point-only primop)
236    
237    
238    TODO items:
239    
240    * Hacked Alpha32 instruction selection, disabling the selection of REMx
241      instructions because the machine instruction encoder cannot handle
242      them.  (Hppa, PPC, and Sparc instruction selection did not handle
243      REM in the first place, and REM is supported by the x86 machine coder.)
244    
245    * Handle DIV and MOD with DIV_TO_NEGINF directly in the x86 instruction
246      selection phase.  (The two can be streamlined because the hardware
247      delivers both quotient and remainder at the same time anyway.)
248    
249    * Think about what to do with "valOf(Int32.minInt) div ~1" and friends.
250      (Currently the behavior is inconsistent both across architectures and
251      wrt. the draft Basis spec.)
252    
253    * Word8 should eventually be handled natively, too.
254    
255    * There seems to be one serious bug in mltree-gen.sml.  It appears, though,
256      as if there currently is no execution path that could trigger it in
257      SML/NJ.  (The assumptions underlying functions arith and promotable do not
258      hold for things like multiplication and division.)
259    
260    ----------------------------------------------------------------------
261    Name: Matthias Blume
262    Date: 2002/03/27 16:27:00 EST
263    Tag: blume-20020327-mlrisc-divisions
264    Description:
265    
266    Added support for all four division operations (ML's div, mod, quot,
267    and rem) to MLRISC.  In the course of doing so, I also rationalized
268    the naming (no more annoying switch-around of DIV and QUOT), by
269    parameterizing the operation by div_rounding_mode (which can be either
270    DIV_TO_ZERO or DIV_TO_NEGINF).
271    
272    The generic MLTreeGen functor takes care of compiling all four
273    operations down to only round-to-zero div.
274    
275    Missing pieces:
276    
277      * Doing something smarter than relying on MLTreeGen on architectures
278        like, e.g., the x86 where hardware division delivers both quotient and
279        remainder at the same time.  With this, the implementation of the
280        round-to-neginf operations could be further streamlined.
281    
282      * Remove inlining support for div/mod/rem from the frontend and replace it
283        with primops that get carried through to the backend.  Do this for all
284        int and word types.
285    
286    ----------------------------------------------------------------------
287    Name: Matthias Blume
288    Date: 2002/03/25 17:25:00 EST
289    Tag: blume-20020325-divmod
290    Description:
291    
292    I improved (hopefully without breaking them) the implementation of Int.div,
293    Int.mod, and Int.rem.   For this, the code in translate.sml now takes
294    advantage of the following observations:
295    
296      Let  q = x quot y      r = x rem y
297           d = x div  y      m = x mod y
298    
299    where "quot" is the round-to-zero version of integer division that
300    hardware usually provides.  Then we have:
301    
302         r = x - q * y        where neither the * nor the - will overflow
303         d = if q >= 0 orelse x = q * y then q else q - 1
304                              where neither the * nor the - will overflow
305         m = if q >= 0 orelse r = 0 then r else r + y
306                              where the + will not overflow
307    
308    This results in substantial simplification of the generated code.
309    The following table shows the number of CFG nodes and edges generated
310    for
311            fun f (x, y) = x OPER y
312            (* with OPER \in div, mod, quot, rem *)
313    
314    
315        OPER | nodes(old) | edges(old) | nodes(new) | edges(new)
316        --------------------------------------------------------
317         div |         24 |         39 |         12 |         16
318         mod |         41 |         71 |         12 |         16
319        quot |          8 |         10 |          8 |         10
320         rem |         10 |         14 |          8 |         10
321    
322    
323    ----------------------------------------------------------------------
324    Name: Matthias Blume
325    Date: 2002/03/25 22:06:00 EST
326    Tag: blume-20020325-cprotobug
327    Description:
328    
329    Fixed a bug in cproto (c prototype decoder).
330    
331    ----------------------------------------------------------------------
332    Name: Matthias Blume
333    Date: 2002/03/25 16:00:00 EST
334    Tag: blume-20020325-raw-primops
335    Description:
336    
337    I did some cleanup to Allen's new primop code and
338    replaced yesterday's bootfiles with new ones.
339    (But they are stored in the same place.)
340    
341    ----------------------------------------------------------------------
342    Name: Matthias Blume
343    Date: 2002/03/24 22:40:00 EST
344    Tag: blume-20020324-bootfiles
345    Description:
346    
347    Made the bootfiles that Allen asked for.
348    
349    ----------------------------------------------------------------------
350    Name: Allen Leung
351    Date: 2002/03/23 15:50:00 EST
352    Tag: leunga-20020323-flint-cps-rcc-primops
353    Description:
354    
355      1. Changes to FLINT primops:
356    
357        (* make a call to a C-function;
358         * The primop carries C function prototype information and specifies
359         * which of its (ML-) arguments are floating point. C prototype
360         * information is for use by the backend, ML information is for
361         * use by the CPS converter. *)
362      | RAW_CCALL of { c_proto: CTypes.c_proto,
363                       ml_args: ccall_type list,
364                       ml_res_opt: ccall_type option,
365                       reentrant : bool
366                     } option
367       (* Allocate uninitialized storage on the heap.
368        * The record is meant to hold short-lived C objects, i.e., they
369        * are not ML pointers.  With the tag, the representation is
370        * the same as RECORD with tag tag_raw32 (sz=4), or tag_fblock (sz=8)
371        *)
372      | RAW_RECORD of {tag:bool,sz:int}
373      and ccall_type = CCALL_INT32 | CCALL_REAL64 | CCALL_ML_PTR
374    
375      2.  These CPS primops are now overloaded:
376    
377           rawload of {kind:numkind}
378           rawstore of {kind:numkind}
379    
380          The one argument form is:
381    
382             rawload {kind} address
383    
384          The two argument form is:
385    
386             rawload {kind} [ml object, byte-offset]
387    
388      3. RAW_CCALL/RCC now takes two extra arguments:
389    
390         a. The first is whether the C call is reentrant, i.e., whether
391            ML state should be saved and restored.
392         b. The second argument is a string argument specifying the name of
393            library and the C function.
394    
395         These things are currently not handled in the code generator, yet.
396    
397      4. In CProto,
398    
399         An encoding type of "bool" means "ml object" and is mapped into
400         C prototype of PTR.  Note that "bool" is different than "string",
401         even though "string" is also mapped into PTR, because "bool"
402         is assigned an CPS type of BOGt, while "string" is assigned INT32t.
403    
404      5. Pickler/unpicker
405    
406         Changed to handle RAW_RECORD and newest RAW_CCALL
407    
408      6. MLRiscGen,
409    
410         1. Changed to handle the new rawload/rawstore/rawrecord operators.
411         2. Code for handling C Calls has been moved to a new module CPSCCalls,
412            in the file CodeGen/cpscompile/cps-c-calls.sml
413    
414      7. Added the conditional move operator
415    
416             condmove of branch
417    
418         to cps.  Generation of this is still buggy so it is currently
419         disabled.
420    
421    ----------------------------------------------------------------------
422  Name: Lal George  Name: Lal George
423  Date: 2002/03/22 14:18:25 EST  Date: 2002/03/22 14:18:25 EST
424  Tag: blume-20020321-cps-branch-prob  Tag: george-20020322-cps-branch-prob
425  Description:  Description:
426    
427  Implemented the Ball-Larus branch prediction-heuristic, and  Implemented the Ball-Larus branch prediction-heuristics, and
428  incorporated graphical viewers for control flow graphs.  incorporated graphical viewers for control flow graphs.
429    
430  Ball-Larus Heuristic:  Ball-Larus Heuristics:
431  ---------------------  ---------------------
432  See the file compiler/CodeGen/cpscompile/cpsBranchProb.sml.  See the file compiler/CodeGen/cpscompile/cpsBranchProb.sml.
433    
# Line 33  Line 439 
439  the ball-larus heuristics predicts that the n=0 is unlikely  the ball-larus heuristics predicts that the n=0 is unlikely
440  (OH-heuristic), and the 'then' branch is unlikely because of the  (OH-heuristic), and the 'then' branch is unlikely because of the
441  RH-heuristic -- giving the 'then' branch an even lower combined  RH-heuristic -- giving the 'then' branch an even lower combined
442  probability using the Dempster-Shater theory.  probability using the Dempster-Shafer theory.
443    
444  Finally, John Reppy's loop analysis in MLRISC, further lowers the  Finally, John Reppy's loop analysis in MLRISC, further lowers the
445  probability of the 'then' branch because of the loop in the else  probability of the 'then' branch because of the loop in the else

Legend:
Removed from v.1168  
changed lines
  Added in v.1212

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0