Intel® oneAPI Data Analytics Library
Learn from community members on how to build compute-intensive applications that run efficiently on Intel® architecture.

Cannot load onedal_thread.1.dll

BenOchoa
Beginner
2,523 Views

Under Windows 10 Pro 10.0.19045 using DAL 2023.2.0.49579, when linking to onedal_core_dll.lib (release) or onedal_cored_dll.lib (debug), at runtime onedal_core.1.dll loads fine but the following error occurs.

Intel oneDAL FATAL ERROR: Cannot load onedal_thread.1.dll.

The application also (and primarily) uses IPP 2021.9.0.49457 and MKL 2023.2.0.49500, and is linking to the following:

mkl_intel_lp64_dll.lib
mkl_intel_thread_dll.lib
mkl_core_dll.lib
ippi.lib
ipps.lib
ippcv.lib
ippcc.lib
ippvm.lib
ippcore.lib
onedal_core_dll.lib
libiomp5md.lib

Please help to resolve this issue, as this same code worked fine with older (1-2 years ago; versions unknown) versions of IPP, MKL, and DAL.

Thanks,
Ben

 

Also, it may not be related but while trying to resolve this issue myself, Dependency Walker found a circular dependency when loading onedal_core.1.dll. The function GetLogicalProcessorInformationEx is being imported from API-MS-WIN-CORE-SYSINFO-L1-1-0.DLL, which is importing the function GetLogicalProcessorInformationEx from KERNEL32.DLL, which is importing the function GetLogicalProcessorInformationEx from API-MS-WIN-CORE-SYSINFO-L1-1-0.DLL, etc.

0 Kudos
12 Replies
BenOchoa
Beginner
2,512 Views

I removed all use of IPP and MKL, and still receive the error:

Intel oneDAL FATAL ERROR: Cannot load onedal_thread.1.dll.

0 Kudos
DiyaN_Intel
Moderator
2,484 Views

Hi, 


Thank you for posting in Intel communities.

Please provide the following details so that we could reproduce the issue on our end :


1. Sample reproducer code


2. Exact steps and the commands used


Regards,

Diya


0 Kudos
BenOchoa
Beginner
2,476 Views

Following is an example main.cpp illustrating this issue.

 

#if defined( _MSC_VER )
#pragma warning( push )
// this function or variable may be unsafe
#pragma warning( disable: 4996 )
#endif // _MSC_VER
#include <daal.h>
#if defined( _MSC_VER )
#pragma warning( pop )
#endif // _MSC_VER

int main( int argc, char *argv[] )
{
    const int width = 4;
    const int height = 3;
    const unsigned char image[width * height] = 
    {
        0, 1,  2,  3, 
        4, 5,  6,  7, 
        8, 9, 10, 11
    };
    daal::data_management::NumericTablePtr pData = 
        daal::data_management::HomogenNumericTable<unsigned char>::create( 
            daal::data_management::DictionaryIface::equal, 
            const_cast<unsigned char*>( image ), 1, width * height );

    const float radius = 0;
    const int minObservations = 1;
    daal::algorithms::dbscan::Batch<float> dbscan( radius, minObservations );
    dbscan.input.set( daal::algorithms::dbscan::data, pData );
    dbscan.compute();
    const int numClusters = dbscan.getResult()->get( 
        daal::algorithms::dbscan::nClusters )->getValue<int>( 0, 0 );

    return 0;
}

 

Built using Microsoft Visual Studio Professional 2019 version 16.10.2.

Compiler arguments:

 

/JMC /external:env:"EXTERNAL_INCLUDE" /permissive- /ifcOutput "x64\Debug\" /GS /W3 /Zc:wchar_t /I"C:\Program Files (x86)\Intel\oneAPI\dal\2023.2.0\include" /ZI /Gm- /Od /sdl /Fd"x64\Debug\vc142.pdb" /Zc:inline /fp:precise /D "_DEBUG" /D "_CONSOLE" /D "_UNICODE" /D "UNICODE" /errorReport:prompt /WX- /Zc:forScope /RTC1 /Gd /MDd /FC /Fa"x64\Debug\" /EHsc /nologo /Fo"x64\Debug\" /Fp"x64\Debug\testdaal.pch" /diagnostics:column 

 

Linker arguments:

 

/OUT:"C:\Projects\testdaal\x64\Debug\testdaal.exe" /MANIFEST /NXCOMPAT /PDB:"C:\Projects\testdaal\x64\Debug\testdaal.pdb" /DYNAMICBASE "onedal_cored_dll.lib" "kernel32.lib" "user32.lib" "gdi32.lib" "winspool.lib" "comdlg32.lib" "advapi32.lib" "shell32.lib" "ole32.lib" "oleaut32.lib" "uuid.lib" "odbc32.lib" "odbccp32.lib" /DEBUG /MACHINE:X64 /INCREMENTAL /PGD:"C:\Projects\testdaal\x64\Debug\testdaal.pgd" /SUBSYSTEM:CONSOLE /MANIFESTUAC:"level='asInvoker' uiAccess='false'" /ManifestFile:"x64\Debug\testdaal.exe.intermediate.manifest" /LTCGOUT:"x64\Debug\testdaal.iobj" /ERRORREPORT:PROMPT /ILK:"x64\Debug\testdaal.ilk" /NOLOGO /LIBPATH:"C:\Program Files (x86)\Intel\oneAPI\dal\2023.2.0\lib\intel64" /TLBID:1 

 

This compiles and links without error but at runtime results in

 

Intel oneDAL FATAL ERROR: Cannot load onedal_thread.1.dll.

 

though onedal_core.1.dll loads fine prior to this fatal error.

0 Kudos
DiyaN_Intel
Moderator
2,334 Views

Hi, 

 

Thank you for providing all the details.

We were able to reproduce the issue from our end.

 

Please make these necessary changes to make your program work in Microsoft Visual Studio 

 

1. Please set the properties as Debug and x64 both in the Visual Studio editor as well as on the properties page of the project, while changing your Include and library directories.

DiyaN_Intel_0-1691394409579.png

 

 

2. In the properties of Visual Studio please make these changes :

 

  a. In the configuration properties --->>C++ --->>General--->> Add the below path 

C:\Program Files (x86)\Intel\oneAPI\dal\2023.2.0\include

DiyaN_Intel_1-1691394668006.png

 

  b. In the configuration properties--- >> C++ --->> Linker -->> Input --->>> Add this library in the Additional Dependencies

onedal_cored_dll.lib

DiyaN_Intel_3-1691394899854.png

 

  c. In configuration properties ---> vc++ directories--->In the library directories,  Add the below path

C:\Program Files (x86)\Intel\oneAPI\dal\2023.2.0\lib\intel64

DiyaN_Intel_5-1691395150226.png

 

After making all the above changes, your program should work fine.

DiyaN_Intel_6-1691395237243.png

If this resolves your issue, make sure to accept this as a solution. 

This would help others with similar issues. Thank you!

 

Regards, 

Diya

 

 

0 Kudos
BenOchoa
Beginner
2,315 Views

Please carefully look at the compiler and linker arguments in my previous post and you will see this is already configured correctly.  Again, this is not a compile- or link-time error.  This is a runtime error, where onedal_core.1.dll loads fine but onedal_thread.1.dll does not load.

0 Kudos
DiyaN_Intel
Moderator
2,229 Views

Hi, 


We are investigating your issue at our end and working on this internally. We will get back to you with an update soon.


Regards, 

Diya


0 Kudos
asin
Moderator
2,120 Views

Hi Ben,


My name is Alex and I have picked up your case. I escalated this issue to the DAL team and they are working on reproducing your issue. I will update you along the way.


Best,

Alex


0 Kudos
asin
Moderator
2,082 Views

Hi Ben,


Our engineering team is not able to reproduce your issue on versions DAL 2023.2.0.49579 and 2023.2.0.49396 using the following cmake configs:


----------------------------------------------------------------------------------------------

# without cmake oneDAL module

cmake_minimum_required(VERSION 3.21)

project (Test)


add_executable(Test test.cpp)

target_include_directories(Test PRIVATE $ENV{DALROOT}/include)

target_link_directories(Test PRIVATE $ENV{DALROOT}/lib/intel64)

target_link_directories(Test PRIVATE $ENV{TBBROOT}/lib/intel64/vc14)

target_link_libraries(Test PUBLIC onedal_cored_dll.1.lib tbb12.lib tbbmalloc.lib)


----------------------------------------------------------------------------------------------

cmake_minimum_required(VERSION 3.21)

project (Test)


set(CMAKE_BUILD_TYPE Release)

set(ONEDAL_USE_DPCPP no)

set(ONEDAL_INTERFACE no)

set(LINK_TYPE "so")


find_package(oneDAL REQUIRED)


add_executable(Test test.cpp)


target_include_directories(Test PRIVATE ${oneDAL_INCLUDE_DIRS})

target_compile_options(Test PRIVATE ${ONEDAL_CUSTOM_COMPILE_OPTIONS})

target_link_libraries(Test PRIVATE ${oneDAL_IMPORTED_TARGETS})

target_link_options(Test PRIVATE ${ONEDAL_CUSTOM_LINK_OPTIONS})

set_target_properties(Test PROPERTIES RUNTIME_OUTPUT_DIRECTORY .)


----------------------------------------------------------------------------------------------


Can you try these and see if the error persists?


0 Kudos
BenOchoa
Beginner
2,066 Views

Thanks, Alex, but I did not build DAL from source.  I downloaded DAL 2023.2.0.49579 from https://www.intel.com/content/www/us/en/developer/tools/oneapi/onedal-download.html  Can the engineering team reproduce the runtime error from this release build?

0 Kudos
asin
Moderator
2,009 Views

Hi Ben,


We are still working on reproducing the issue and I will give you an update soon.


Thanks,

Alex


0 Kudos
asin
Moderator
1,825 Views

Hi Ben,


Unfortunately, the engineering team is unable to reproduce your issue on DAL from oneAPI Base Kit 2023.2.0.49579 given the information you provided.  Can you provide additional information?


Best,

Alex


0 Kudos
asin
Moderator
1,774 Views

Hi Ben,


I have not heard from you for some time, so this ticket will be closed. If you need further assistance, please create a new ticket.


Thank you,

Alex


0 Kudos
Reply