From cc69ceed6b756def2ed1df705b3db2c6a0278034 Mon Sep 17 00:00:00 2001 From: Kevin Tew Date: Thu, 18 Nov 2010 07:39:35 -0700 Subject: [PATCH] [Parallel-Build] Better error logging for failed match --- collects/setup/parallel-build.rkt | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/collects/setup/parallel-build.rkt b/collects/setup/parallel-build.rkt index 79cf3fff2a..50796f83e1 100644 --- a/collects/setup/parallel-build.rkt +++ b/collects/setup/parallel-build.rkt @@ -25,7 +25,11 @@ ['DONE (when (or (not (zero? (string-length out))) (not (zero? (string-length err)))) ((collects-queue-append-error jobqueue) cc "making" null out err "output"))]) - (when last ((collects-queue-printer jobqueue) (current-output-port) "made" "~a" cc-name )))])) + (when last ((collects-queue-printer jobqueue) (current-output-port) "made" "~a" cc-name )))] + [else + (eprintf "work-done match cc failed.\n") + (eprintf "trying to match:\n~a\n" (list work msg))])) + ;; assigns a collection to each worker to be compiled ;; when it runs out of collections, steals work from other workers collections (define (get-job jobqueue workerid) @@ -70,7 +74,11 @@ (build-job cc file #t)] [(cons (list cc (cons file ft) subs) tail) (hash-set! w-hash id (cons (list cc ft subs) tail)) - (build-job cc file #f)])) + (build-job cc file #f)] + [else + (eprintf "get-job match cc failed.\n") + (eprintf "trying to match:\n~a\n" cc)])) + (match (hash-ref!/true w-hash workerid take-cc) [#f (match (hash/first-pair w-hash)