Commit b988f8b0 authored by Julian Kranz's avatar Julian Kranz

Endianness (spelling)

parent 84a06d9d
......@@ -895,7 +895,7 @@ structure C1 = struct
| emitPrim s (GET_CON_ARGprim, [_,e],[FUNvtype (_,_,[t]),_]) = seq [str "((", emitConType s t, str "*) ", emitExp s e , str ")->payload"]
| emitPrim s (VOIDprim, [],_) = str "0 /* void value */"
| emitPrim s (MERGE_ROPEprim, [e],_) = seq [str (#prefix s ^ "merge_rope"), fArgs [emitExp s e]]
| emitPrim s (SET_ENDIANESSprim, es,_) = seq [str (#prefix s ^ "set_endianess"), fArgs (map (emitExp s) es)]
| emitPrim s (SET_ENDIANNESSprim, es,_) = seq [str (#prefix s ^ "set_endianness"), fArgs (map (emitExp s) es)]
| emitPrim s _ = raise CodeGenBug
and addConsume s n = #consumeSizes s := IntListSet.add (!(#consumeSizes s),n)
......@@ -1250,7 +1250,7 @@ structure C1 = struct
C1Templates.mkHook ("reset_heap", str (prefix ^ "reset_heap")),
C1Templates.mkHook ("heap_residency", str (prefix ^ "heap_residency")),
C1Templates.mkHook ("merge_rope", str (prefix ^ "merge_rope")),
C1Templates.mkHook ("endianess", str (prefix ^ "endianess")),
C1Templates.mkHook ("endianness", str (prefix ^ "endianness")),
C1Templates.mkHook ("rope_to_string", str (prefix ^ "rope_to_string")),
C1Templates.mkHook ("rope_length", str (prefix ^ "rope_length")),
C1Templates.mkHook ("destroy", str (prefix ^ "destroy")),
......
......@@ -92,7 +92,7 @@ structure Imp = struct
| GET_CON_ARGprim
| VOIDprim
| MERGE_ROPEprim
| SET_ENDIANESSprim
| SET_ENDIANNESSprim
(* information on how to print primitives, the name is the C name
and the priority is the operator precedence, 0 if not infix *)
......@@ -131,7 +131,7 @@ structure Imp = struct
| prim_info GET_CON_ARGprim = { name = "__get_con_arg", prio = 0 }
| prim_info VOIDprim = { name = "void", prio = 0 }
| prim_info MERGE_ROPEprim = { name = "merge-rope", prio = 0 }
| prim_info SET_ENDIANESSprim = { name = "endianess", prio = 0 }
| prim_info SET_ENDIANNESSprim = { name = "endianness", prio = 0 }
(*
* fun f x =
......
......@@ -245,7 +245,7 @@ structure Primitives = struct
BD.meetVarImpliesVar (bvar content'', bvar content')},
{name="void", ty=UNIT, flow = noFlow},
{name="merge-rope", ty=FUN([ropeVar],STRING), flow = noFlow},
{name="endianess", ty=FUN([ZENO,ZENO],UNIT), flow = noFlow}
{name="endianness", ty=FUN([ZENO,ZENO],UNIT), flow = noFlow}
]
val primitiveSizeConstraints =
......@@ -374,7 +374,7 @@ structure Primitives = struct
[e] => action e
| _ => raise ImpPrimTranslationBug))),
("merge-rope", (t 0, fn args => pr (MERGE_ROPEprim,os,args))),
("endianess", (t 0, fn args => pr (SET_ENDIANESSprim,iiv,unboxI args)))
("endianness", (t 0, fn args => pr (SET_ENDIANNESSprim,iiv,unboxI args)))
]
end
......
......@@ -526,7 +526,7 @@ val / ['1001010110101000'] = nullop WDR
val / ['1001001 d d d d d 0100'] = binop XCH /Z rd5
val decode config = do
set-endianess LITTLE_ENDIAN 2;
set-endianness LITTLE_ENDIAN 2;
update@{rd='',rr='',ck='',cs='',cb='',io='',dq='', config = config};
idx-before <- idxget;
insn <- /;
......
......@@ -199,16 +199,16 @@ val conf data short long = CONF
# the native interface
type obj = OBJ
# Set the endianess of the input.
type endianess =
# Set the endianness of the input.
type endianness =
BIG_ENDIAN
| LITTLE_ENDIAN
val set-endianess kind size = let
val set-endianness kind size = let
val e = case kind of
BIG_ENDIAN : 0
| LITTLE_ENDIAN : 1
end
in
return (endianess e size)
return (endianness e size)
end
......@@ -528,7 +528,7 @@ val sem-lb-lbu ext_op x = do
re <- return (fRE);
movsx 2 bigendian_cpu 1 (var re);
# get depending on the endianess the correct byte out of the word
# get depending on the endianness the correct byte out of the word
byte <- mktemp;
mov 30 (at-offset byte 2) (imm 0);
xorb 2 byte (var vaddr) (var bigendian_cpu);
......@@ -561,7 +561,7 @@ val sem-lh-lhu ext_op x = do
mov 1 bigendian_cpu (var fRE);
shl 2 bigendian_cpu (var bigendian_cpu) (imm 1);
# get depending on the endianess the correct halfword out of the word
# get depending on the endianness the correct halfword out of the word
byte <- mktemp;
mov 30 (at-offset byte 2) (imm 0);
xorb 2 byte (var vaddr) (var bigendian_cpu);
......
......@@ -21,7 +21,7 @@ val config-default-opnd-sz-32 = '10'
val test-opt opt config = if (zx (opt and config)) > 0 then '1' else '0'
val decode config = do
set-endianess LITTLE_ENDIAN 1;
set-endianness LITTLE_ENDIAN 1;
update @{tab=void};
main config
end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment