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

SCM Repository

[diderot] Diff of /branches/vis15/src/compiler/cfg-ir/ssa-fn.sml
ViewVC logotype

Diff of /branches/vis15/src/compiler/cfg-ir/ssa-fn.sml

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

revision 3843, Tue May 10 15:10:58 2016 UTC revision 3846, Wed May 11 13:35:09 2016 UTC
# Line 113  Line 113 
113    
114      and rhs      and rhs
115        = GLOBAL of global_var            (* read global variable *)        = GLOBAL of global_var            (* read global variable *)
116        | STATE of state_var              (* read strand state variable *)        | STATE of var option * state_var (* read strand state variable; NONE means "self" *)
117        | VAR of var        | VAR of var
118        | LIT of Literal.t        | LIT of Literal.t
119        | OP of Op.rator * var list        | OP of Op.rator * var list
# Line 274  Line 274 
274          fun same (SV{id=a, ...}, SV{id=b, ...}) = Stamp.same(a, b)          fun same (SV{id=a, ...}, SV{id=b, ...}) = Stamp.same(a, b)
275          fun compare (SV{id=a, ...}, SV{id=b, ...}) = Stamp.compare(a, b)          fun compare (SV{id=a, ...}, SV{id=b, ...}) = Stamp.compare(a, b)
276          fun hash (SV{id, ...}) = Stamp.hash id          fun hash (SV{id, ...}) = Stamp.hash id
277          fun toString (SV{name, ...}) = "self." ^ name          fun toString (SV{name, ...}) = name
278        (* properties *)        (* properties *)
279          fun newProp initFn = PropList.newProp (fn (SV{props, ...}) => props, initFn)          fun newProp initFn = PropList.newProp (fn (SV{props, ...}) => props, initFn)
280          fun newFlag () = PropList.newFlag (fn (SV{props, ...}) => props)          fun newFlag () = PropList.newFlag (fn (SV{props, ...}) => props)
# Line 929  Line 929 
929        (* return a string representation of a rhs *)        (* return a string representation of a rhs *)
930          fun toString rhs = (case rhs          fun toString rhs = (case rhs
931                 of GLOBAL x => GlobalVar.toString x                 of GLOBAL x => GlobalVar.toString x
932                  | STATE x => StateVar.toString x                  | STATE(NONE, x) => "self." ^ StateVar.toString x
933                    | STATE(SOME x, y) => String.concat[Var.toString x, ".", StateVar.toString y]
934                  | VAR x => Var.toString x                  | VAR x => Var.toString x
935                  | LIT lit => Literal.toString lit                  | LIT lit => Literal.toString lit
936                  | OP(rator, xs) => String.concat [                  | OP(rator, xs) => String.concat [

Legend:
Removed from v.3843  
changed lines
  Added in v.3846

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