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

SCM Repository

[diderot] Annotation of /branches/vis12/src/compiler/driver/backend.sml
ViewVC logotype

Annotation of /branches/vis12/src/compiler/driver/backend.sml

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1704 - (view) (download)

1 : jhr 1232 (* backend.sml
2 :     *
3 :     * COPYRIGHT (c) 2011 The Diderot Project (http://diderot-language.cs.uchicago.edu)
4 :     * All rights reserved.
5 :     *)
6 :    
7 :     structure BackEnd : sig
8 :    
9 :     val generate : TargetUtil.target_desc -> string * LowIL.program -> unit
10 :    
11 :     end = struct
12 :    
13 :     fun pickBackend target = (case target
14 :     of TargetUtil.TARGET_C => CBackEnd.generate
15 : jhr 1671 | TargetUtil.TARGET_CL => CLBackEnd.generate
16 : jhr 1232 | TargetUtil.TARGET_CUDA => raise Fail "CUDA not supported yet"
17 :     (* end case *))
18 :    
19 : jhr 1704 fun generate {exec, target, parallel, double, debug} = let
20 : jhr 1232 val gen = pickBackend target
21 :     in
22 :     fn (basename, prog) => gen {
23 : jhr 1704 basename=basename, exec=exec,
24 :     double=double, parallel=parallel, debug=debug,
25 :     prog=prog
26 : jhr 1232 }
27 :     end
28 :    
29 :     end

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