Actions

icon Post
text/html Subscribe
text/html Unsubscribe

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

Re: [vsipl++] [patch] Share ALF w/CML; Fix vmul_c kernel


  • To: Jules Bergmann <jules@xxxxxxxxxxxxxxxx>
  • Subject: Re: [vsipl++] [patch] Share ALF w/CML; Fix vmul_c kernel
  • From: Stefan Seefeld <stefan@xxxxxxxxxxxxxxxx>
  • Date: Wed, 14 May 2008 08:40:07 -0400

Jules Bergmann wrote:
This patch initializes VSIPL++'s ALF handle from CML (CML patch required) so that VSIPL++'s kernels can work. It also rehabilitates the VSIPL++ interleaved complex vmul kernel.

Next step is to disable VSIPL++ and CML ALF caching, so that VSIPL++ and CML do not get in each other's way.

#ifdef VSIP_IMPL_HAVE_CML
     cml_init();
+    (void)num_accelerators;
+    alf_ = cml_impl_alf_handle();
+    num_accelerators_ = query(ALF_QUERY_NUM_ACCEL);
 #else
     int status = alf_init(0, &alf_);
     assert(status >= 0);
- if (num_accelerators) - {
-      set_num_accelerators(num_accelerators);
-      assert(status >= 0);
-    }
+
+    set_num_accelerators(num_accelerators);
 #endif

Shouldn't we pass the 'num_accelerators' argument down to cml_init() ? Otherwise there is no way to mandate how many SPUs to use from SV++. Or am I missing something ?

+++ src/vsip/opt/cbe/spu/GNUmakefile.inc.in	(working copy)
@@ -34,6 +34,8 @@
spe_kernels := lib/svpp_kernels.so +libs += $(spe_kernels)
+
 CC_SPU := @CC_SPU@
 CXX_SPU := @CXX_SPU@
 EMBED_SPU := @EMBED_SPU@
@@ -112,6 +114,7 @@
 -include src/vsip/opt/cbe/alf/src/spu/GNUmakefile.inc

I just noticed this inclusion, which I missed to remove in my previous patch. (The '-' at the beginning makes 'make' ignore the failure, so we didn't see it.) Can you please remove this line when you commit the patch ? The alf/ subdirectory doesn't exist any more...


The patch looks good otherwise. Thanks,

		Stefan

--
Stefan Seefeld
CodeSourcery
stefan@xxxxxxxxxxxxxxxx
(650) 331-3385 x718