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 1096, Tue Feb 26 16:59:02 2002 UTC revision 1250, Fri Jul 5 14:22:42 2002 UTC
# Line 14  Line 14 
14    
15  ----------------------------------------------------------------------  ----------------------------------------------------------------------
16  Name: Matthias Blume  Name: Matthias Blume
17    Date: 2002/07/05 10:25:00 EDT
18    Tag: blume-20020705-btimp
19    Description:
20    
21    Exported structure BTImp from $smlnj/viscomp/debugprof.cm so that
22    other clients can set up backtracing support.
23    
24    ----------------------------------------------------------------------
25    Name: Matthias Blume
26    Date: 2002/06/25 17:23:00 EDT
27    Tag: blume-20020625-fpmax
28    Description:
29    
30    Fixed a bug in translation of INLMAX (and INLMIN) for the floating-point
31    case.  (The sense of the isNaN test was reversed -- which made min and
32    max always return their first argument.)
33    
34    ----------------------------------------------------------------------
35    Name: Matthias Blume
36    Date: 2002/06/11
37    Tag: blume-20020611-unixpath
38    Description:
39    
40    Back-ported OS.Path.{from,to}UnixPath from idlbasis-devel branch.
41    
42    ----------------------------------------------------------------------
43    Name: Matthias Blume
44    Date: 2002/06/10 16:35:00 EDT
45    Tag: blume-20020610-ieeereal
46    Description:
47    
48    I back-ported my implementation of IEEEReal.fromString from the
49    idlbasis-devel branch so that we can test it.
50    
51    Another small change is that ppDec tries to give more information
52    than just "<sig>" in the case of functors.  However, this code is
53    broken in some mysterious way if the functor's body's signature
54    has not been declared by ascription but gets inferred from the
55    implementation.  This needs fixing...
56    
57    ----------------------------------------------------------------------
58    Name: Matthias Blume
59    Date: 2002/05/31
60    Tag: blume-20020531-btrace-mode
61    Description:
62    
63    Resurrected SMLofNJ.Internals.BTrace.mode.  (It accidentally fell by
64    the wayside when I switched over to using Controls everywhere.)
65    
66    ----------------------------------------------------------------------
67    Name: Lal George
68    Date: 2002/05/23 12:21:40 EDT
69    Tag: george-20020523-visual-labels
70    Description:
71    
72    Labels are now displayed in the graphical output to make
73    the fall-through and target blocks obvious.
74    
75    ----------------------------------------------------------------------
76    Name: Matthias Blume
77    Date: 2002/05/22 11:03:00 EDT
78    Tag: blume-20020522-shrink
79    Description:
80    
81    John tweaked yesterday's fix for 1131 to handle an out-of-memory
82    situation that comes up when allocating huge arrays.
83    
84    ----------------------------------------------------------------------
85    Name: Matthias Blume
86    Date: 2002/05/21 16:00:00 EDT
87    Tag: Release_110_40
88    Description:
89    
90    New working release (110.40).  New bootfiles.
91    
92    [Also: John Reppy fixed GC bug 1131.]
93    
94    ----------------------------------------------------------------------
95    Name: Matthias Blume
96    Date: 2002/05/21 12:35:00 EDT
97    Tag: blume-20020521-cmdoc
98    Description:
99    
100    CM documentation update.
101    
102    ----------------------------------------------------------------------
103    Name: Matthias Blume
104    Date: 2002/05/21 10:55:00 EDT
105    Tag: blume-20020521-misc
106    Description:
107    
108    - John tweaked runtime to be silent on heap export (except when
109      GC messages are on).
110    - I added a few more things (cross-compiling versions of CMB) to
111      config/preloads (as suggestions).
112    
113    ----------------------------------------------------------------------
114    Name: Matthias Blume
115    Date: 2002/05/20 22:25:00 EDT
116    Tag: blume-20020520-controls
117    Description:
118    
119    - Added ControlUtil structure to control-lib.cm.
120    - Use it throughout.
121    - Used Controls facility to define MLRISC controls (as opposed to
122      registering MLRISC control ref cells with Controls after the fact)
123    - Fixed messed-up controls priorities.
124    
125    * Removed again all the stuff from config/preloads that one wouldn't
126      be able to preload at the time the initial heap image is built.
127      (Many libraries, e.g., CML, do not exist yet at this time.  The
128       only libraries that can be preloaded via config/preloads are those
129       that come bundled with the bootfiles.)
130    
131    ----------------------------------------------------------------------
132    Name: Matthias Blume
133    Date: 2002/05/20 10:59:00 EDT
134    Tag: blume-20020520-preloads
135    Description:
136    
137    Added a lot of commented-out suggestions for things to be included
138    in config/preloads.
139    
140    ----------------------------------------------------------------------
141    Name: Allen Leung
142    Date: 2002/05/18 14:20:00 EDT
143    Tag: leunga-20020518-mdl
144    Description:
145    
146    o Made the mdl tool stuff compile and run again.
147    o I've disabled all the stuff that depends on RTL specifications; they
148      are all badly broken anyway.
149    
150    ----------------------------------------------------------------------
151    Name: Matthias Blume
152    Date: 2002/05/17 16:49:00 EDT
153    Tag: blume-20020517-controls
154    Description:
155    
156    0. John Reppy made several modifications to the SML/NJ library.
157       In particular, there is a shiny new controls-lib.cm.
158    
159    1. Pushed new controls interface through compiler so that everything
160       compiles again.
161    
162    2. Added FormatComb and FORMAT_COMB to the CML version of the
163       SML/NJ library (so that CML compiles again).
164    
165    3. Modified init scripts because XXX_DEFAULT environment variables
166       are no longer with us.  (Boot-time initialization is now done
167       using the same environment variables that are also used for
168       startup-time initialization of controls.)
169    
170    ----------------------------------------------------------------------
171    Name: Lal George
172    Date: 2002/05/15 09:20:10 EDT
173    Tag: george-20020515-pseudo-op-decls
174    Description:
175    
176            All pseudo-ops emitted before the first segment declaration
177    such as TEXT, DATA, and BSS directives are assumed to be global
178    declarations and are emitted first in the assembly file. This is
179    useful in a number of situations where one has pseudo-ops that are not
180    specific to any segment, and also works around the constraint that one
181    cannot have client pseudo-ops in the TEXT segment.
182    
183            Because no segment is associated with these declarations it is
184    an error to allocate any space or objects before the first segment
185    directive and an exception will be raised. However, we cannot make
186    this check for client pseudo-ops.
187    
188            These top level declarations are a field in the CFG graph_info.
189    In theory you can continue to add to this field after the CFG has been
190    built -- provided you know what you are doing;-)
191    
192    ----------------------------------------------------------------------
193    Name: Matthias Blume
194    Date: 2002/05/13 16:40:00 EDT
195    Tag: blume-20020513-pp-etc
196    Description:
197    
198    A few minor bugfixes:
199    
200      - Stopgap measure for bug recently reported by Elsa Gunter (ppDec).
201        (Bogus printouts for redefined bindings still occur.  Compiler
202        bug should no longer occur now.  We need to redo the prettyprinter
203        from scratch.)
204    
205      - CM pathname printer now also adds escape sequences for ( and )
206    
207      - commend and docu fixes for ml-nlffi
208    
209    ----------------------------------------------------------------------
210    Name: Matthias Blume
211    Date: 2002/05/10 16:40:00 EDT
212    Tag: blume-20020510-erg-textio
213    Description:
214    
215    Applied the following bugfix provided by Emden Gansner:
216    
217        Output is corrupted when outputSubstr is used rather than output.
218    
219        The problem occurs when a substring
220    
221            ss = (s, dataStart, dataLen)
222    
223        where dataStart > 0, fills a stream buffer with avail bytes left.
224        avail bytes of s, starting at index dataStart, are copied into the
225        buffer, the buffer is flushed, and then the remaining dataLen-avail
226        bytes of ss are copied into the beginning of the buffer. Instead of
227        starting this copy at index dataStart+avail in s, the current code
228        starts the copy at index avail.
229    
230        Fix:
231        In text-io-fn.sml, change line 695 from
232             val needsFlush = copyVec(v, avail, dataLen-avail, buf, 0)
233        to
234             val needsFlush = copyVec(v, dataStart+avail, dataLen-avail, buf, 0)
235    
236    ----------------------------------------------------------------------
237    Name: Matthias Blume
238    Date: 2002/04/12 13:55:00 EDT
239    Tag: blume-20020412-assyntax
240    Description:
241    
242    1. Grabbed newer assyntax.h from the XFree86 project.
243    2. Fiddled with how to compile X86.prim.asm without warnings.
244    3. (Very) Minor cleanup in CM.
245    
246    ----------------------------------------------------------------------
247    Name: Matthias Blume
248    Date: 2002/04/01 (no joke!) 17:07:00 EST
249    Tag: blume-20020401-x86div
250    Description:
251    
252    Added full support for div/mod/rem/quot on the x86, using the machine
253    instruction's two results (without clumsily recomputing the remainder)
254    directly where appropriate.
255    
256    Some more extensive power-of-two support was added to the x86 instruction
257    selector (avoiding expensive divs, mods, and muls where they can be
258    replaced with cheaper shifts and masks).  However, this sort of thing
259    ought to be done earlier, e.g., within the CPS optimizer so that
260    all architectures benefit from it.
261    
262    The compiler compiles to a fixed point, but changes might be somewhat
263    fragile nevertheless.  Please, report any strange things that you might
264    see wrt. div/mod/quot/rem...
265    
266    ----------------------------------------------------------------------
267    Name: Matthias Blume
268    Date: 2002/03/29 17:22:00
269    Tag: blume-20020329-div
270    Description:
271    
272    Fixed my broken div/mod logic.  Unfortunately, this means that the
273    inline code for div/mod now has one more comparison than before.
274    Fast paths (quotient > 0 or remainder = 0) are not affected, though.
275    The problem was with quotient = 0, because that alone does not tell
276    us which way the rounding went.  One then has to look at whether
277    remainder and divisor have the same sign...  :(
278    
279    Anyway, I replaced the bootfiles with fresh ones...
280    
281    ----------------------------------------------------------------------
282    Name: Matthias Blume
283    Date: 2002/03/29 14:10:00 EST
284    Tag: blume-20020329-inlprims
285    Description:
286    
287    NEW BOOTFILES!!!    Version number bumped to 110.39.3.
288    
289    Primops have changed. This means that the bin/boot-file formats have
290    changed as well.
291    
292    To make sure that there is no confusion, I made a new version.
293    
294    
295    CHANGES:
296    
297    * removed REMT from mltree (remainder should never overflow).
298    
299    * added primops to deal with divisions of all flavors to the frontend
300    
301    * handled these primops all the way through so they map to their respective
302      MLRISC support
303    
304    * used these primops in the implementation of Int, Int32, Word, Word32
305    
306    * removed INLDIV, INLMOD, and INLREM as they are no longer necessary
307    
308    * parameterized INLMIN, INLMAX, and INLABS by a numkind
309    
310    * translate.sml now deals with all flavors of INL{MIN,MAX,ABS}, including
311      floating point
312    
313    * used INL{MIN,MAX,ABS} in the implementation of Int, Int32, Word, Word32,
314      and Real (but Real.abs maps to a separate floating-point-only primop)
315    
316    
317    TODO items:
318    
319    * Hacked Alpha32 instruction selection, disabling the selection of REMx
320      instructions because the machine instruction encoder cannot handle
321      them.  (Hppa, PPC, and Sparc instruction selection did not handle
322      REM in the first place, and REM is supported by the x86 machine coder.)
323    
324    * Handle DIV and MOD with DIV_TO_NEGINF directly in the x86 instruction
325      selection phase.  (The two can be streamlined because the hardware
326      delivers both quotient and remainder at the same time anyway.)
327    
328    * Think about what to do with "valOf(Int32.minInt) div ~1" and friends.
329      (Currently the behavior is inconsistent both across architectures and
330      wrt. the draft Basis spec.)
331    
332    * Word8 should eventually be handled natively, too.
333    
334    * There seems to be one serious bug in mltree-gen.sml.  It appears, though,
335      as if there currently is no execution path that could trigger it in
336      SML/NJ.  (The assumptions underlying functions arith and promotable do not
337      hold for things like multiplication and division.)
338    
339    ----------------------------------------------------------------------
340    Name: Matthias Blume
341    Date: 2002/03/27 16:27:00 EST
342    Tag: blume-20020327-mlrisc-divisions
343    Description:
344    
345    Added support for all four division operations (ML's div, mod, quot,
346    and rem) to MLRISC.  In the course of doing so, I also rationalized
347    the naming (no more annoying switch-around of DIV and QUOT), by
348    parameterizing the operation by div_rounding_mode (which can be either
349    DIV_TO_ZERO or DIV_TO_NEGINF).
350    
351    The generic MLTreeGen functor takes care of compiling all four
352    operations down to only round-to-zero div.
353    
354    Missing pieces:
355    
356      * Doing something smarter than relying on MLTreeGen on architectures
357        like, e.g., the x86 where hardware division delivers both quotient and
358        remainder at the same time.  With this, the implementation of the
359        round-to-neginf operations could be further streamlined.
360    
361      * Remove inlining support for div/mod/rem from the frontend and replace it
362        with primops that get carried through to the backend.  Do this for all
363        int and word types.
364    
365    ----------------------------------------------------------------------
366    Name: Matthias Blume
367    Date: 2002/03/25 17:25:00 EST
368    Tag: blume-20020325-divmod
369    Description:
370    
371    I improved (hopefully without breaking them) the implementation of Int.div,
372    Int.mod, and Int.rem.   For this, the code in translate.sml now takes
373    advantage of the following observations:
374    
375      Let  q = x quot y      r = x rem y
376           d = x div  y      m = x mod y
377    
378    where "quot" is the round-to-zero version of integer division that
379    hardware usually provides.  Then we have:
380    
381         r = x - q * y        where neither the * nor the - will overflow
382         d = if q >= 0 orelse x = q * y then q else q - 1
383                              where neither the * nor the - will overflow
384         m = if q >= 0 orelse r = 0 then r else r + y
385                              where the + will not overflow
386    
387    This results in substantial simplification of the generated code.
388    The following table shows the number of CFG nodes and edges generated
389    for
390            fun f (x, y) = x OPER y
391            (* with OPER \in div, mod, quot, rem *)
392    
393    
394        OPER | nodes(old) | edges(old) | nodes(new) | edges(new)
395        --------------------------------------------------------
396         div |         24 |         39 |         12 |         16
397         mod |         41 |         71 |         12 |         16
398        quot |          8 |         10 |          8 |         10
399         rem |         10 |         14 |          8 |         10
400    
401    
402    ----------------------------------------------------------------------
403    Name: Matthias Blume
404    Date: 2002/03/25 22:06:00 EST
405    Tag: blume-20020325-cprotobug
406    Description:
407    
408    Fixed a bug in cproto (c prototype decoder).
409    
410    ----------------------------------------------------------------------
411    Name: Matthias Blume
412    Date: 2002/03/25 16:00:00 EST
413    Tag: blume-20020325-raw-primops
414    Description:
415    
416    I did some cleanup to Allen's new primop code and
417    replaced yesterday's bootfiles with new ones.
418    (But they are stored in the same place.)
419    
420    ----------------------------------------------------------------------
421    Name: Matthias Blume
422    Date: 2002/03/24 22:40:00 EST
423    Tag: blume-20020324-bootfiles
424    Description:
425    
426    Made the bootfiles that Allen asked for.
427    
428    ----------------------------------------------------------------------
429    Name: Allen Leung
430    Date: 2002/03/23 15:50:00 EST
431    Tag: leunga-20020323-flint-cps-rcc-primops
432    Description:
433    
434      1. Changes to FLINT primops:
435    
436        (* make a call to a C-function;
437         * The primop carries C function prototype information and specifies
438         * which of its (ML-) arguments are floating point. C prototype
439         * information is for use by the backend, ML information is for
440         * use by the CPS converter. *)
441      | RAW_CCALL of { c_proto: CTypes.c_proto,
442                       ml_args: ccall_type list,
443                       ml_res_opt: ccall_type option,
444                       reentrant : bool
445                     } option
446       (* Allocate uninitialized storage on the heap.
447        * The record is meant to hold short-lived C objects, i.e., they
448        * are not ML pointers.  With the tag, the representation is
449        * the same as RECORD with tag tag_raw32 (sz=4), or tag_fblock (sz=8)
450        *)
451      | RAW_RECORD of {tag:bool,sz:int}
452      and ccall_type = CCALL_INT32 | CCALL_REAL64 | CCALL_ML_PTR
453    
454      2.  These CPS primops are now overloaded:
455    
456           rawload of {kind:numkind}
457           rawstore of {kind:numkind}
458    
459          The one argument form is:
460    
461             rawload {kind} address
462    
463          The two argument form is:
464    
465             rawload {kind} [ml object, byte-offset]
466    
467      3. RAW_CCALL/RCC now takes two extra arguments:
468    
469         a. The first is whether the C call is reentrant, i.e., whether
470            ML state should be saved and restored.
471         b. The second argument is a string argument specifying the name of
472            library and the C function.
473    
474         These things are currently not handled in the code generator, yet.
475    
476      4. In CProto,
477    
478         An encoding type of "bool" means "ml object" and is mapped into
479         C prototype of PTR.  Note that "bool" is different than "string",
480         even though "string" is also mapped into PTR, because "bool"
481         is assigned an CPS type of BOGt, while "string" is assigned INT32t.
482    
483      5. Pickler/unpicker
484    
485         Changed to handle RAW_RECORD and newest RAW_CCALL
486    
487      6. MLRiscGen,
488    
489         1. Changed to handle the new rawload/rawstore/rawrecord operators.
490         2. Code for handling C Calls has been moved to a new module CPSCCalls,
491            in the file CodeGen/cpscompile/cps-c-calls.sml
492    
493      7. Added the conditional move operator
494    
495             condmove of branch
496    
497         to cps.  Generation of this is still buggy so it is currently
498         disabled.
499    
500    ----------------------------------------------------------------------
501    Name: Lal George
502    Date: 2002/03/22 14:18:25 EST
503    Tag: george-20020322-cps-branch-prob
504    Description:
505    
506    Implemented the Ball-Larus branch prediction-heuristics, and
507    incorporated graphical viewers for control flow graphs.
508    
509    Ball-Larus Heuristics:
510    ---------------------
511    See the file compiler/CodeGen/cpscompile/cpsBranchProb.sml.
512    
513    By design it uses the Dempster-Shafer theory for combining
514    probabilities.  For example, in the function:
515    
516        fun f(n,acc) = if n = 0 then acc else f(n-1, n*acc)
517    
518    the ball-larus heuristics predicts that the n=0 is unlikely
519    (OH-heuristic), and the 'then' branch is unlikely because of the
520    RH-heuristic -- giving the 'then' branch an even lower combined
521    probability using the Dempster-Shafer theory.
522    
523    Finally, John Reppy's loop analysis in MLRISC, further lowers the
524    probability of the 'then' branch because of the loop in the else
525    branch.
526    
527    
528    Graphical Viewing:
529    ------------------
530    I merely plugged in Allen's graphical viewers into the compiler. The
531    additional code is not much. At the top level, saying:
532    
533            Control.MLRISC.getFlag "cfg-graphical-view" := true;
534    
535    will display the graphical view of the control flow graph just before
536    back-patching.  daVinci must be in your path for this to work. If
537    daVinci is not available, then the default viewer can be changed
538    using:
539    
540            Control.MLRISC.getString "viewer"
541    
542    which can be set to "dot" or "vcg" for the corresponding viewers. Of
543    course, these viewers must be in your path.
544    
545    The above will display the compilation unit at the level of clusters,
546    many of which are small, boring, and un-interesting. Also setting:
547    
548            Control.MLRISC.getInt "cfg-graphical-view_size"
549    
550    will display clusters that are larger than the value set by the above.
551    
552    
553    ----------------------------------------------------------------------
554    Name: Matthias Blume
555    Date: 2002/03/21 22:20:00 EST
556    Tag: blume-20020321-kmp-bugfix
557    Description:
558    
559    Changed the interface to the KMP routine in PreString and fixed
560    a minor bug in one place where it was used.
561    
562    ----------------------------------------------------------------------
563    Name: Allen Leung
564    Date: 2002/03/21 20:30:00 EST
565    Tag: leunga-20020321-cfg
566    Description:
567    
568      Fixed a potential problem in cfg edge splitting.
569    
570    ----------------------------------------------------------------------
571    Name: Allen Leung
572    Date: 2002/03/21 17:15:00 EST
573    Tag: leunga-20020321-x86-fp-cfg
574    Description:
575    
576      1. Recoded the buggy parts of x86-fp.
577    
578         a. All the block reordering code has been removed.
579            We now depend on the block placement phases to do this work.
580    
581         b. Critical edge splitting code has been simplified and moved into the
582            CFG modules, as where they belong.
583    
584         Both of these were quite buggy and complex.  The code is now much, much
585         simpler.
586    
587      2. X86 backend.
588    
589         a. Added instructions for 64-bit support.  Instruction selection for
590            64-bit has not been committed, however, since that
591            requires changes to MLTREE which haven't been approved by
592            Lal and John.
593    
594         b. Added support for FUCOMI and FUCOMIP when generating code for
595            PentiumPro and above.  We only generate these instructions in
596            the fast-fp mode.
597    
598         c. Added cases for JP and JNP in X86FreqProps.
599    
600      3. CFG
601    
602         CFG now has a bunch of methods for edge splitting and merging.
603    
604      4. Machine description.
605    
606         John's simplification of MLTREE_BASIS.fcond broke a few machine
607         description things:
608    
609         rtl-build.{sig,sml} and hppa.mdl fixed.
610    
611         NOTE: the machine description stuff in the repository is still broken.
612               Again, I can't put my fixes in because that involves
613               changes to MLTREE.
614    
615    ----------------------------------------------------------------------
616    Name: Matthias Blume
617    Date: 2002/03/20 15:55:00 EST
618    Tag: blume-20020320-kmp
619    Description:
620    
621    Implemented Knuth-Morris-Pratt string matching in PreString and used
622    it for String.isSubstring, Substring.isSubstring, and
623    Substring.position.
624    
625    (Might need some stress-testing.  Simple examples worked fine.)
626    
627    ----------------------------------------------------------------------
628    Name: Matthias Blume
629    Date: 2002/03/19 16:37:00 EST
630    Tag: blume-20020319-witnesses
631    Description:
632    
633    Added a structure C.W and functions convert/Ptr.convert to ml-nlffi-lib.
634    
635    This implements a generic mechanism for changing constness qualifiers
636    anywhere within big C types without resorting to outright "casts".
637    (So far, functions such as C.rw/C.ro or C.Ptr.rw/C.Ptr.ro only let you
638    modify the constness at the outermost level.)
639    The implementation of "convert" is based on the idea of "witness"
640    values -- values that are not used by the operation but whose types
641    "testify" to their applicability.  On the implementation side, "convert"
642    is simply a projection (returning its second curried argument).  With
643    cross-module inlining, it should not result in any machine code being
644    generated.
645    
646    ----------------------------------------------------------------------
647    Name: Matthias Blume
648    Date: 2002/03/15 16:40:00 EST
649    Tag: blume-20020315-basis
650    Description:
651    
652    Provided (preliminary?) implementations for
653    
654      {String,Substring}.{concatWith,isSuffix,isSubstring}
655    
656    and
657    
658      Substring.full
659    
660    Those are in the Basis spec but they were missing in SML/NJ.
661    
662    ----------------------------------------------------------------------
663    Name: Matthias Blume
664    Date: 2002/03/14 21:30:00 EST
665    Tag: blume-20020314-controls
666    Description:
667    
668    Controls:
669    ---------
670    
671    1. Factored out the recently-added Controls : CONTROLS stuff and put
672       it into its own library $/controls-lib.cm.  The source tree for
673       this is under src/smlnj-lib/Controls.
674    
675    2. Changed the names of types and functions in this interface, so they
676       make a bit more "sense":
677    
678          module -> registry
679          'a registry -> 'a group
680    
681    3. The interface now deals in ref cells only.  The getter/setter interface
682       is (mostly) gone.
683    
684    4. Added a function that lets one register an already-existing ref cell.
685    
686    5. Made the corresponding modifications to the rest of the code so that
687       everything compiles again.
688    
689    6. Changed the implementation of Controls.MLRISC back to something closer
690       to the original.  In particular, this module (and therefore MLRISC)
691       does not depend on Controls.  There now is some link-time code in
692       int-sys.sml that registers the MLRISC controls with the Controls
693       module.
694    
695    CM:
696    ---
697    
698      * One can now specify the lambda-split aggressiveness in init.cmi.
699    
700    ----------------------------------------------------------------------
701    Name: Allen Leung
702    Date: 2002/03/13 17:30:00 EST
703    Tag: leunga-20020313-x86-fp-unary
704    Description:
705    
706    Bug fix for:
707    
708    > leunga@weaselbane:~/Yale/tmp/sml-dist{21} bin/sml
709    > Standard ML of New Jersey v110.39.1 [FLINT v1.5], March 08, 2002
710    > - fun f(x,(y,z)) = Real.~ y;
711    > [autoloading]
712    > [autoloading done]
713    >       fchsl   (%eax), 184(%esp)
714    > Error: MLRisc bug: X86MCEmitter.emitInstr
715    >
716    > uncaught exception Error
717    >   raised at: ../MLRISC/control/mlriscErrormsg.sml:16.14-16.19
718    
719    The problem was that the code generator did not generate any fp registers
720    in this case, and the ra didn't know that it needed to run the X86FP phase to
721    translate the pseudo fp instruction.   This only happened with unary fp
722    operators in certain situations.
723    
724    ----------------------------------------------------------------------
725    Name: Matthias Blume
726    Date: 2002/03/13 14:00:00 EST
727    Tag: blume-20020313-overload-etc
728    Description:
729    
730    1. Added _overload as a synonym for overload for backward compatibility.
731       (Control.overloadKW must be true for either version to be accepted.)
732    
733    2. Fixed bug in install script that caused more things to be installed
734       than what was requested in config/targets.
735    
736    3. Made CM aware of the (_)overload construct so that autoloading
737       works.
738    
739    ----------------------------------------------------------------------
740    Name: Matthias Blume
741    Date: 2002/03/12 22:03:00 EST
742    Tag: blume-20020312-url
743    Description:
744    
745    Forgot to update BOOT and srcarchiveurl.
746    
747    ----------------------------------------------------------------------
748    Name: Matthias Blume
749    Date: 2002/03/12 17:30:00 EST
750    Tag: blume-20020312-version110392
751    Description:
752    
753    Yet another version number bump (because of small changes to the
754    binfile format).  Version number is now 110.39.2.  NEW BOOTFILES!
755    
756    Changes:
757    
758      The new pid generation scheme described a few weeks ago was overly
759      complicated.  I implemented a new mechanism that is simpler and
760      provides a bit more "stability":  Once CM has seen a compilation
761      unit, it keeps its identity constant (as long as you do not delete
762      those crucial CM/GUID/* files).  This means that when you change
763      an interface, compile, then go back to the old interface, and
764      compile again, you arrive at the original pid.
765    
766      There now also is a mechanism that instructs CM to use the plain
767      environment hash as a module's pid (effectively making its GUID
768      the empty string).  For this, "noguid" must be specified as an
769      option to the .sml file in question within its .cm file.
770      This is most useful for code that is being generated by tools such
771      as ml-nlffigen (because during development programmers tend to
772      erase the tool's entire output directory tree including CM's cached
773      GUIDs).  "noguid" is somewhat dangerous (since it can be used to locally
774      revert to the old, broken behavior of SML/NJ, but in specific cases
775      where there is no danger of interface confusion, its use is ok
776      (I think).
777    
778      ml-nlffigen by default generates "noguid" annotations.  They can be
779      turned off by specifying -guid in its command line.
780    
781    ----------------------------------------------------------------------
782    Name: Lal George
783    Date: 2002/03/12 12 14:42:36 EST
784    Tag: george-20020312-frequency-computation
785    Description:
786    
787    Integrated jump chaining and static block frequency into the
788    compiler. More details and numbers later.
789    
790    ----------------------------------------------------------------------
791    Name: Lal George
792    Date: 2002/03/11 11 22:38:53 EST
793    Tag: george-20020311-jump-chain-elim
794    Description:
795    
796    Tested the jump chain elimination on all architectures (except the
797    hppa).  This is on by default right now and is profitable for the
798    alpha and x86, however, it may not be profitable for the sparc and ppc
799    when compiling the compiler.
800    
801    The gc test will typically jump to a label at the end of the cluster,
802    where there is another jump to an external cluster containing the actual
803    code to invoke gc. This is to allow factoring of common gc invocation
804    sequences. That is to say, we generate:
805    
806            f:
807               testgc
808               ja   L1      % jump if above to L1
809    
810            L1:
811               jmp L2
812    
813    
814    After jump chain elimination the 'ja L1' instructions is converted to
815    'ja L2'. On the sparc and ppc, many of the 'ja L2' instructions may end
816    up being implemented in their long form (if L2 is far away) using:
817    
818            jbe     L3      % jump if below or equal to L3
819            jmp     L2
820         L3:
821            ...
822    
823    
824    For large compilation units L2  may be far away.
825    
826    
827    ----------------------------------------------------------------------
828    Name: Matthias Blume
829    Date: 2002/03/11 13:30:00 EST
830    Tag: blume-20020311-mltreeeval
831    Description:
832    
833    A functor parameter was missing.
834    
835    ----------------------------------------------------------------------
836    Name: Allen Leung
837    Date: 2002/03/11 10:30:00 EST
838    Tag: leunga-20020311-runtime-string0
839    Description:
840    
841       The representation of the empty string now points to a
842    legal null terminated C string instead of unit.  It is now possible
843    to convert an ML string into C string with InlineT.CharVector.getData.
844    This compiles into one single machine instruction.
845    
846    ----------------------------------------------------------------------
847    Name: Allen Leung
848    Date: 2002/03/10 23:55:00 EST
849    Tag: leunga-20020310-x86-call
850    Description:
851    
852       Added machine generation for CALL instruction (relative displacement mode)
853    
854    ----------------------------------------------------------------------
855    Name: Matthias Blume
856    Date: 2002/03/08 16:05:00
857    Tag: blume-20020308-entrypoints
858    Description:
859    
860    Version number bumped to 110.39.1.  NEW BOOTFILES!
861    
862    Entrypoints: non-zero offset into a code object where execution should begin.
863    
864    - Added the notion of an entrypoint to CodeObj.
865    - Added reading/writing of entrypoint info to Binfile.
866    - Made runtime system bootloader aware of entrypoints.
867    - Use the address of the label of the first function given to mlriscGen
868      as the entrypoint.  This address is currently always 0, but it will
869      not be 0 once we turn on block placement.
870    - Removed the linkage cluster code (which was The Other Way(tm) of dealing
871      with entry points) from mlriscGen.
872    
873    ----------------------------------------------------------------------
874    Name: Allen Leung
875    Date: 2002/03/07 20:45:00 EST
876    Tag: leunga-20020307-x86-cmov
877    Description:
878    
879       Bug fixes for CMOVcc on x86.
880    
881       1. Added machine code generation for CMOVcc
882       2. CMOVcc is now generated in preference over SETcc on PentiumPro or above.
883       3. CMOVcc cannot have an immediate operand as argument.
884    
885    ----------------------------------------------------------------------
886    Name: Matthias Blume
887    Date: 2002/03/07 16:15:00 EST
888    Tag: blume-20020307-controls
889    Description:
890    
891    This is a very large but mostly boring patch which makes (almost)
892    every tuneable compiler knob (i.e., pretty much everything under
893    Control.* plus a few other things) configurable via both the command
894    line and environment variables in the style CM did its configuration
895    until now.
896    
897    Try starting sml with '-h' (or, if you are brave, '-H')
898    
899    To this end, I added a structure Controls : CONTROLS to smlnj-lib.cm which
900    implements the underlying generic mechanism.
901    
902    The interface to some of the existing such facilities has changed somewhat.
903    For example, the MLRiscControl module now provides mkFoo instead of getFoo.
904    (The getFoo interface is still there for backward-compatibility, but its
905    use is deprecated.)
906    
907    The ml-build script passes -Cxxx=yyy command-line arguments through so
908    that one can now twiddle the compiler settings when using this "batch"
909    compiler.
910    
911    TODO items:
912    
913    We should go through and throw out all controls that are no longer
914    connected to anything.  Moreover, we should go through and provide
915    meaningful (and correct!) documentation strings for those controls
916    that still are connected.
917    
918    Currently, multiple calls to Controls.new are accepted (only the first
919    has any effect).  Eventually we should make sure that every control
920    is being made (via Controls.new) exactly once.  Future access can then
921    be done using Controls.acc.
922    
923    Finally, it would probably be a good idea to use the getter-setter
924    interface to controls rather than ref cells.  For the time being, both
925    styles are provided by the Controls module, but getter-setter pairs are
926    better if thread-safety is of any concern because they can be wrapped.
927    
928    *****************************************
929    
930    One bug fix: The function blockPlacement in three of the MLRISC
931    backpatch files used to be hard-wired to one of two possibilities at
932    link time (according to the value of the placementFlag).  But (I
933    think) it should rather sense the flag every time.
934    
935    *****************************************
936    
937    Other assorted changes (by other people who did not supply a HISTORY entry):
938    
939    1. the cross-module inliner now works much better (Monnier)
940    2. representation of weights, frequencies, and probabilities in MLRISC
941       changed in preparation of using those for weighted block placement
942       (Reppy, George)
943    
944    ----------------------------------------------------------------------
945    Name: Lal George
946    Date: 2002/03/07 14:44:24 EST 2002
947    Tag: george-20020307-weighted-block-placement
948    
949    Tested the weighted block placement optimization on all architectures
950    (except the hppa) using AMPL to generate the block and edge frequencies.
951    Changes were required in the machine properties to correctly
952    categorize trap instructions. There is an MLRISC flag
953    "weighted-block-placement" that can be used to enable weighted block
954    placement, but this will be ineffective without block/edge
955    frequencies (coming soon).
956    
957    
958    ----------------------------------------------------------------------
959    Name: Lal George
960    Date: 2002/03/05 17:24:48 EST
961    Tag: george-20020305-linkage-cluster
962    
963    In order to support the block placement optimization, a new cluster
964    is generated as the very first cluster (called the linkage cluster).
965    It contains a single jump to the 'real' entry point for the compilation
966    unit. Block placement has no effect on the linkage cluster itself, but
967    all the other clusters  have full freedom in the manner in which they
968    reorder blocks or functions.
969    
970    On the x86 the typical linkage code that is generated is:
971       ----------------------
972            .align 2
973       L0:
974            addl    $L1-L0, 72(%esp)
975            jmp     L1
976    
977    
978            .align  2
979       L1:
980       ----------------------
981    
982    72(%esp) is the memory location for the stdlink register. This
983    must contain the address of the CPS function being called. In the
984    above example, it contains the address of  L0; before
985    calling L1 (the real entry point for the compilation unit), it
986    must contain the address for L1, and hence
987    
988            addl $L1-L0, 72(%esp)
989    
990    I have tested this on all architectures except the hppa.The increase
991    in code size is of course negligible
992    
993    ----------------------------------------------------------------------
994    Name: Allen Leung
995    Date: 2002/03/03 13:20:00 EST
996    Tag: leunga-20020303-mlrisc-tools
997    
998      Added #[ ... ] expressions to mlrisc tools
999    
1000    ----------------------------------------------------------------------
1001    Name: Matthias Blume
1002    Date: 2002/02/27 12:29:00 EST
1003    Tag: blume-20020227-cdebug
1004    Description:
1005    
1006    - made types in structure C and C_Debug to be equal
1007    - got rid of code duplication (c-int.sml vs. c-int-debug.sml)
1008    - there no longer is a C_Int_Debug (C_Debug is directly derived from C)
1009    
1010    ----------------------------------------------------------------------
1011    Name: Matthias Blume
1012  Date: 2002/02/26 12:00:00 EST  Date: 2002/02/26 12:00:00 EST
1013  Tag: blume-20020226-ffi  Tag: blume-20020226-ffi
1014  Description:  Description:
# Line 124  Line 1119 
1119         TOTAL                                   2375.26u  57.21s  48.00g         TOTAL                                   2375.26u  57.21s  48.00g
1120    
1121  As you can see the old cps spill module suffers from some serious  As you can see the old cps spill module suffers from some serious
1122  performance problem but since I cannot decipher the old code fully,  performance problem.  But since I cannot decipher the old code fully,
1123  innstead of patching the problems up, I'm reimplementing it  instead of patching the problems up, I'm reimplementing it
1124  with a different algorithm.  The new code is more modular,  with a different algorithm.  The new code is more modular,
1125  smaller when compiled, and substantially faster  smaller when compiled, and substantially faster
1126  (O(n log n) time and O(n) space).  Timing of the new spill module:  (O(n log n) time and O(n) space).  Timing of the new spill module:

Legend:
Removed from v.1096  
changed lines
  Added in v.1250

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