Hi Charles,

sorry for the late response. Currently there is no way of getting the 
internal index. You can, however, edit viennacl/ocl/backend.hpp and add 
a public member function in viennacl::ocl::backend returning the index.

Best regards,
Karli



On 01/29/2016 04:00 PM, Charles Determan wrote:
> While trying to figure out the device index I thought the following
> would work:
>
> viennacl::ocl::current_context().current_device_id_
>
> but apparently the `current_device_id_` is private (which didn't appear
> to be the case in the context.hpp file).  Perhaps a simple method for
> its' accession?  If this functionality doesn't exist I can likely write
> this.
>
> I still have made no headway on the context index.
>
> Regards,
> Charles
>
> On Thu, Jan 28, 2016 at 1:30 PM, Charles Determan <cdeterma...@gmail.com
> <mailto:cdeterma...@gmail.com>> wrote:
>
>     A user can switch contexts easily with
>
>     long id = 1;
>     viennacl::ocl::switch_context(id);
>
>     Is there a way to determine the current context index?  In this case
>     it would return 1?
>
>     The corollary for platform is:
>
>     viennacl::ocl::current_context().platform_index()
>
>
>     I also don't see a method for device_index() either.  But it is
>     possible I am simply overlooking this somewhere in the documentation.
>
>     Regards,
>     Charles
>
>
>
>
> ------------------------------------------------------------------------------
> Site24x7 APM Insight: Get Deep Visibility into Application Performance
> APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
> Monitor end-to-end web transactions and take corrective actions now
> Troubleshoot faster and improve end-user experience. Signup Now!
> http://pubads.g.doubleclick.net/gampad/clk?id=267308311&iu=/4140
>
>
>
> _______________________________________________
> ViennaCL-devel mailing list
> ViennaCL-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/viennacl-devel
>


------------------------------------------------------------------------------
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311&iu=/4140
_______________________________________________
ViennaCL-devel mailing list
ViennaCL-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/viennacl-devel

Reply via email to