]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
Fix Neon Scheduler ocaml description.
authorJulian Brown <julian@codesourcery.com>
Tue, 12 Jan 2010 11:50:36 +0000 (11:50 +0000)
committerRamana Radhakrishnan <ramana@gcc.gnu.org>
Tue, 12 Jan 2010 11:50:36 +0000 (11:50 +0000)
For

2010-01-12  Julian Brown  <julian@codesourcery.com>

        * config/arm/neon-schedgen.ml (Utils): Don't try to
        open missing module.
        (find_with_result): New.

From-SVN: r155835

gcc/ChangeLog
gcc/config/arm/neon-schedgen.ml

index 4d8cfb3cfd49975e92b802ee0aa15d1f84b1662f..17d322413c5d07f5e8f0b119705f212112480c57 100644 (file)
@@ -1,3 +1,9 @@
+2010-01-12  Julian Brown  <julian@codesourcery.com>
+
+        * config/arm/neon-schedgen.ml (Utils): Don't try to
+       open missing module.
+        (find_with_result): New.
+
 2010-01-12  Jakub Jelinek  <jakub@redhat.com>
 
        PR debug/42662
index e564742011d5b3acfe389ee1f40f827a65ee9116..d735ea06bdacbf83a8e5ebfc643f475cbd24904e 100644 (file)
      and at present we do not emit specific guards.)
 *)
 
-open Utils
+let find_with_result fn lst =
+  let rec scan = function
+      [] -> raise Not_found
+    | l::ls -> 
+      match fn l with
+          Some result -> result
+       | _ -> scan ls in
+    scan lst
 
 let n1 = 1 and n2 = 2 and n3 = 3 and n4 = 4 and n5 = 5 and n6 = 6
     and n7 = 7 and n8 = 8 and n9 = 9