diff options
Diffstat (limited to 'asmcomp/power/proc.ml')
-rw-r--r-- | asmcomp/power/proc.ml | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/asmcomp/power/proc.ml b/asmcomp/power/proc.ml index 203e8a9ef4..77e37deda0 100644 --- a/asmcomp/power/proc.ml +++ b/asmcomp/power/proc.ml @@ -224,6 +224,17 @@ let max_register_pressure = function Iextcall(_, _) -> [| 15; 18 |] | _ -> [| 23; 30 |] +(* Pure operations (without any side effect besides updating their result + registers). *) + +let op_is_pure = function + | Icall_ind | Icall_imm _ | Itailcall_ind | Itailcall_imm _ + | Iextcall _ | Istackoffset _ | Istore _ | Ialloc _ + | Iintop(Icheckbound) | Iintop_imm(Icheckbound, _) -> false + | Ispecific(Imultaddf | Imultsubf) -> true + | Ispecific _ -> false + | _ -> true + (* Layout of the stack *) let num_stack_slots = [| 0; 0 |] |