Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Avoid dependence on specific python versions #47

Merged
merged 10 commits into from
Aug 30, 2024

Conversation

h-vetinari
Copy link
Member

It's clear from the recipe that python is only used as a build tool here, not because anything needs to be built per python version. This should be reflected in the recipe, because it avoids trying to build intel-opencl-rt for various python versions, c.f.

image

It also leads to other problems, because our migration infrastructure thinks this feedstock needs to be migrated per python version, which leads to pointless PRs like #46, resp. problems with false positives for cycles in the build graph

@conda-forge-webservices
Copy link
Contributor

Hi! This is the friendly automated conda-forge-linting service.

I just wanted to let you know that I linted all conda-recipes in your PR (recipe/meta.yaml) and found it was in an excellent condition.

@beckermr
Copy link
Member

This star may help these builds, but it won't fix the issue in the bot. The bot ignores the python versions when computing the graph.

@beckermr
Copy link
Member

IIUIC need a python boostrapping package with at least different name here (e.g., a python-dev maybe with purely static linking or something) in order to fix the bot's graph.

@isuruf
Copy link
Member

isuruf commented Aug 29, 2024

@conda-forge-admin , rerender

@beckermr
Copy link
Member

Yep moving python to build will do the trick too! Thanks @isuruf!

Copy link

Hi! This is the friendly automated conda-forge-webservice.

I tried to rerender for you, but it looks like there was nothing to do.

This message was generated by GitHub actions workflow run https://github.com/conda-forge/intel-compiler-repack-feedstock/actions/runs/10623445769.

@h-vetinari
Copy link
Member Author

h-vetinari commented Aug 29, 2024

Well, this fails even with a swapfile...

SYCL CPU RT Warning: Cannot load TBB from neither Windows registry key nor CPU runtime configuration file (cl.cfg / cl.fpga_emu.cfg) in C:\bld\intel-compiler-repack_1724973392069\_test_env\Library\bin\intel-ocl-cpu\ location. The Error message is: Windows error code: 126.
You can ask your administrator to configure TBB library location to CL_CONFIG_TBB_DLL_PATH item in the configuration files.
Or you need to check Windows registry key under HKEY_LOCAL_MACHINE\SOFTWARE\Intel\oneAPI\TBB\ location. The version items under this location are installed TBB on this machine. The required TBB version is 2021.13.0. You can install the required TBB if it is not listed in Windows registry.
Traceback (most recent call last):
  File "C:\bld\intel-compiler-repack_1724973392069\test_tmp\demo.py", line 9, in <module>
    ctx = cl.create_some_context()
          ^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\bld\intel-compiler-repack_1724973392069\_test_env\Lib\site-packages\pyopencl\__init__.py", line 1696, in create_some_context
    return Context(devices)
           ^^^^^^^^^^^^^^^^
pyopencl._cl.RuntimeError: Context failed: OUT_OF_HOST_MEMORY

However, the OOM looks spurious, because the real issue seems to be that the build requires a newer tbb (2021.13.0) than what ends up in the environment:

TEST START: C:\bld\win-64\intel-opencl-rt-2024.2.0-h27e31e5_979.conda

[...]

The following NEW packages will be INSTALLED:

    intel-cmplr-lib-rt:        2024.2.0-hbb528cf_979        local      
    intel-cmplr-lic-rt:        2024.2.0-h57928b3_979        local
    intel-opencl-rt:           2024.2.0-h27e31e5_979        local      
    intel-openmp:              2024.2.1-h57928b3_1083       conda-forge
    pyopencl:                  2024.2.7-py312hbaa7e33_0     conda-forge
    python:                    3.12.5-h889d299_0_cpython    conda-forge
    tbb:                       2021.12.0-hc790b64_4         conda-forge
                                    ^^
                                    !!

Xref conda-forge/tbb-feedstock#133

@oleksandr-pavlyk
Copy link
Contributor

The error pyopencl._cl.RuntimeError: Context failed: OUT_OF_HOST_MEMORY indicates that CPU driver was not able to find tbbmalloc12.dll library, most likely due to failure to modify cl.cfg file.

The script set_tbb_dll_path.py refers to sys.prefix which has changed as python conda package got moved from host to build environment.

If there is a way to accomplish the same effect without using Python, this could solve the problem.

@beckermr
Copy link
Member

Yes you should be able to feed the build and host prefix in to adjust sys.prefix

Copy link
Contributor

@oleksandr-pavlyk oleksandr-pavlyk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Thanks for fixing this

@oleksandr-pavlyk oleksandr-pavlyk merged commit 4e272e2 into conda-forge:main Aug 30, 2024
4 checks passed
@h-vetinari h-vetinari deleted the py branch August 30, 2024 02:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants