diff options
author | Damien Doligez <damien.doligez-inria.fr> | 2014-08-22 13:45:02 +0000 |
---|---|---|
committer | Damien Doligez <damien.doligez-inria.fr> | 2014-08-22 13:45:02 +0000 |
commit | cbfe627f925ab2bab93bae7a7bc9f6ee6afb8637 (patch) | |
tree | af5ec283ac3175b1ab95dd745dbd05f2298b9da6 /tools/ocamlprof.ml | |
parent | 09ad9c1abbe6bee443a55379223280dab3de4749 (diff) | |
download | ocaml-cbfe627f925ab2bab93bae7a7bc9f6ee6afb8637.tar.gz |
merge changes from branch 4.02 from branching (rev 14852) to 4.02.0+rc1 (rev 15121)
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15125 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
Diffstat (limited to 'tools/ocamlprof.ml')
-rw-r--r-- | tools/ocamlprof.ml | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/tools/ocamlprof.ml b/tools/ocamlprof.ml index 9c2bb489dd..dde248cd48 100644 --- a/tools/ocamlprof.ml +++ b/tools/ocamlprof.ml @@ -86,7 +86,7 @@ let add_incr_counter modul (kind,pos) = | Close -> fprintf !outchan ")"; ;; -let counters = ref (Array.create 0 0) +let counters = ref (Array.make 0 0) (* User defined marker *) let special_id = ref "" @@ -122,7 +122,7 @@ let init_rewrite modes mod_name = cur_point := 0; if !instr_mode then begin fprintf !outchan "module %sProfiling = Profiling;; " modprefix; - fprintf !outchan "let %s%s_cnt = Array.create 000000000" idprefix mod_name; + fprintf !outchan "let %s%s_cnt = Array.make 000000000" idprefix mod_name; pos_len := pos_out !outchan; fprintf !outchan " 0;; Profiling.counters := \ @@ -131,7 +131,7 @@ let init_rewrite modes mod_name = end let final_rewrite add_function = - to_insert := Sort.list (fun x y -> snd x < snd y) !to_insert; + to_insert := List.sort (fun x y -> compare (snd x) (snd y)) !to_insert; prof_counter := 0; List.iter add_function !to_insert; copy (in_channel_length !inchan); |