Home My Page Projects Code Snippets Project Openings diderot
Summary Activity Tracker Tasks SCM

SCM Repository

[diderot] Diff of /branches/pure-cfg/src/compiler/c-target/runtime-names.sml
ViewVC logotype

Diff of /branches/pure-cfg/src/compiler/c-target/runtime-names.sml

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

revision 1171, Tue May 10 14:08:35 2011 UTC revision 1172, Tue May 10 15:57:48 2011 UTC
# Line 15  Line 15 
15    (* globals that specify the target characteristics.  These should be initialized    (* globals that specify the target characteristics.  These should be initialized
16     * when the program object is created.     * when the program object is created.
17     *)     *)
18        val doublePrecision = ref false
19      val gVectorWid = ref 4      val gVectorWid = ref 4
20      val gIntTy = ref CLang.int32      val gIntTy = ref CLang.int32
21      val gRealTy = ref CLang.float      val gRealTy = ref CLang.float
# Line 23  Line 24 
24      val gIntFormat = ref "?"      val gIntFormat = ref "?"
25    
26    (* initialize globals based on target precision *)    (* initialize globals based on target precision *)
27      fun initTargetSpec () = if !Controls.doublePrecision      fun initTargetSpec double = (
28              doublePrecision := double;
29              if double
30            then (            then (
31              gVectorWid := 2;              gVectorWid := 2;
32              gIntTy := CLang.int64;              gIntTy := CLang.int64;
# Line 37  Line 40 
40              gRealTy := CLang.float;              gRealTy := CLang.float;
41              gRealSuffix := "f";              gRealSuffix := "f";
42              gIntSuffix := "i";              gIntSuffix := "i";
43              gIntFormat := "%d")                gIntFormat := "%d"))
44    
45      fun addRealSuffix stem = stem ^ !gRealSuffix      fun addRealSuffix stem = stem ^ !gRealSuffix
46      fun addVecSuffix stem n = concat[stem, Int.toString n, !gRealSuffix]      fun addVecSuffix stem n = concat[stem, Int.toString n, !gRealSuffix]

Legend:
Removed from v.1171  
changed lines
  Added in v.1172

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