offload error: cannot get device 0 handle (error code 2)

offload error: cannot get device 0 handle (error code 2)

Hello ,

I have a setup of 2 MIC cards on one node, if lets say MIC 0 is not up while MIC 1 is up, Then on executing code, it gives me following error.

      offload error: cannot get device 0 handle (error code 2).

     On offload statement like this  :

      #pragma offload target(mic:-1) inout(a : length(size) alloc_if(1) free_if(0)) in(size)


        #pragma offload target(mic:1) inout(a : length(size) alloc_if(1) free_if(0)) in(size)

It would be helpful if there is any complied document for all types of offload error, its reason and possible solution to it.

Thanks in advance.

2 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

You appear to be using the Composer XE 2013 Update 1 2013.1.117 (or earlier) where the offload RTL initialized all cards configured in the system, booted or not.

Beginning with the Composer XE 2013 Update 2 (2013.2.146), and still true with the current Update 3 release (2013.3.163), only cards that are actually booted and usable are initialized.

You should upgrade your Composer to the Update 3 as soon as convenient.

As a work around, you can set the environment variable OFFLOAD_DEVICES=1 to restrict initialization/execution to the physical card 1 that you know is available.

A related note, users may control card initialization using OFFLOAD_INIT. Refer to the User’s Guide for information about both environment variables.

We are working on documenting and improving offload related errors. The content of errors has been rather dynamic over the course of developing the offload feature thus complicating documenting those but the intent is to provide those in the documentation in the future.

Hope that helps.

Leave a Comment

Please sign in to add a comment. Not a member? Join today