commit-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Commit-gnuradio] r7944 - in gnuradio/branches/developers/eb/gcell-wip/s


From: eb
Subject: [Commit-gnuradio] r7944 - in gnuradio/branches/developers/eb/gcell-wip/src/lib: . spu
Date: Wed, 5 Mar 2008 14:34:52 -0700 (MST)

Author: eb
Date: 2008-03-05 14:34:52 -0700 (Wed, 05 Mar 2008)
New Revision: 7944

Modified:
   gnuradio/branches/developers/eb/gcell-wip/src/lib/qa_job_manager.cc
   gnuradio/branches/developers/eb/gcell-wip/src/lib/spu/gc_main.c
   gnuradio/branches/developers/eb/gcell-wip/src/lib/spu/gc_spu_jd_queue.c
Log:
work-in-progress

Modified: gnuradio/branches/developers/eb/gcell-wip/src/lib/qa_job_manager.cc
===================================================================
--- gnuradio/branches/developers/eb/gcell-wip/src/lib/qa_job_manager.cc 
2008-03-05 21:06:43 UTC (rev 7943)
+++ gnuradio/branches/developers/eb/gcell-wip/src/lib/qa_job_manager.cc 
2008-03-05 21:34:52 UTC (rev 7944)
@@ -730,10 +730,10 @@
 void
 qa_job_manager::t14_body()
 {
-  return;
+  //return;
 
   //static const int NJOBS = 64;
-  static const int NJOBS = 256;
+  static const int NJOBS = 128;
   static const int LEN_PER_JOB = 1021;
   unsigned char    buf[NJOBS * LEN_PER_JOB];
   gc_job_desc_t          *jd[NJOBS];

Modified: gnuradio/branches/developers/eb/gcell-wip/src/lib/spu/gc_main.c
===================================================================
--- gnuradio/branches/developers/eb/gcell-wip/src/lib/spu/gc_main.c     
2008-03-05 21:06:43 UTC (rev 7943)
+++ gnuradio/branches/developers/eb/gcell-wip/src/lib/spu/gc_main.c     
2008-03-05 21:34:52 UTC (rev 7944)
@@ -217,7 +217,7 @@
   if (t == mask){      // got a match, generate dma
     mfc_put(dc_ls_base + offset, dc_ea_base + offset, len, dc_put_tag, 0, 0);
   }
-  else {
+  else {               // bisect
     len >>= 1;
     d_and_c(offset, len);
     d_and_c(offset + len, len);
@@ -286,19 +286,9 @@
       // Do we have any "put" args?  If so ensure that previous
       // dma from this buffer is complete
 
-      if (0){
-       printf("dir_union       = %#x\n", jd->sys.direction_union);
-       printf("put_in_progress = %#x\n", put_in_progress);
-      }
-
       if ((jd->sys.direction_union & GCJD_DMA_PUT)
          && (put_in_progress & PBI_MASK(pbi))){
 
-       if (0){
-         printf("pj:  waiting for tag_mask 0x%08x\n", 1 << put_tag);
-
-       }
-
        mfc_write_tag_mask(1 << put_tag);       // the tag we're interested in
        mfc_read_tag_status_all();              // wait for DMA to complete
        put_in_progress &= ~(PBI_MASK(pbi));
@@ -343,7 +333,7 @@
          }
 
          // add to dma get list 
-         // FIXME (someday) the dma lists is where the JS_BAD_EAH limitation 
comes from
+         // FIXME (someday) the dma list is where the JS_BAD_EAH limitation 
comes from
 
          while (dma_len != 0){
            int n = MIN(dma_len, MFC_MAX_DMA_SIZE);
@@ -541,8 +531,12 @@
 
   comp_info.job_id[comp_info.ncomplete++] = jd->sys.job_id;
 
+#if 0 // FIXME
+  flush_completion_info();
+#else
   if (comp_info.ncomplete == GC_CI_NJOBS)
     flush_completion_info();
+#endif  
 }
 
 static void
@@ -629,10 +623,17 @@
      unsigned long long envp __attribute__((unused)))
 {
   gc_sys_tag = mfc_tag_reserve();      // allocate a tag for our misc DMA 
operations
+  get_tag  = mfc_tag_reserve();
   ci_tags  = mfc_multi_tag_reserve(2);
   put_tags = mfc_multi_tag_reserve(2);
-  get_tag  = mfc_tag_reserve();
 
+#if 0  
+  printf("gc_sys_tag = %d\n", gc_sys_tag);
+  printf("get_tag    = %d\n", get_tag);
+  printf("ci_tags    = %d\n", ci_tags);
+  printf("put_tags   = %d\n", put_tags);
+#endif
+
   // dma the args in
   mfc_get(&spu_args, argp, sizeof(spu_args), gc_sys_tag, 0, 0);
   mfc_write_tag_mask(1 << gc_sys_tag); // the tag we're interested in

Modified: 
gnuradio/branches/developers/eb/gcell-wip/src/lib/spu/gc_spu_jd_queue.c
===================================================================
--- gnuradio/branches/developers/eb/gcell-wip/src/lib/spu/gc_spu_jd_queue.c     
2008-03-05 21:06:43 UTC (rev 7943)
+++ gnuradio/branches/developers/eb/gcell-wip/src/lib/spu/gc_spu_jd_queue.c     
2008-03-05 21:34:52 UTC (rev 7944)
@@ -62,6 +62,7 @@
   // copy in job descriptor at head of queue
   *item_ea = local_q.head;
   mfc_get(item, local_q.head, sizeof(gc_job_desc_t), gc_sys_tag, 0, 0);
+  mfc_write_tag_mask(1 << gc_sys_tag); // the tag we're interested in
   mfc_read_tag_status_all();           // wait for DMA to complete
 
   local_q.head = item->sys.next;
@@ -72,11 +73,16 @@
 
   // copy the queue structure back out
   mfc_put(&local_q, q, sizeof(gc_jd_queue_t), gc_sys_tag, 0, 0);
+  mfc_write_tag_mask(1 << gc_sys_tag); // the tag we're interested in
   mfc_read_tag_status_all();           // wait for DMA to complete
 
-  // FIXME do we need to order stores in EA or can we just clear the
+  // Q: FIXME do we need to order stores in EA or can we just clear the
   // local copy of the mutex above and blast it out, removing the need
   // for this explicit unlock?
+  //
+  // A: Manual says it's better to use an atomic op rather than
+  // a normal DMA, and that a putlluc is better than a putllc if
+  // you can use it.
 
   _mutex_unlock(q + offsetof(gc_jd_queue_t, mutex));
   return true;





reply via email to

[Prev in Thread] Current Thread [Next in Thread]