HigherOrderCO / Bend

A massively parallel, high-level programming language
https://higherorderco.com
Apache License 2.0
17.44k stars 427 forks source link

(Request) Run in both the CPU and GPU at the same time #521

Open jaydeeppromact2024 opened 5 months ago

jaydeeppromact2024 commented 5 months ago

Why cant we use CPU and GPU all cores together ?

Please make it possible to use CPU and GPU all cores together

NO alternatives i found

developedby commented 5 months ago

It would be interesting, but orchestrating what should be sent to the gpu and what should be calculated in the CPU is not that simple. We considered doing it, offloading things to the gpu when we noticed that the threads were getting too full, but in the end we went for the simpler alternative for the initial release. Definitely possible

RobertBiehl commented 5 months ago

I second this! While it might be hard to automatically decide which part should run where, I would really like to be able to give hints to the code where it should run. Todays CPUs are really fast, so it's a pity if one has to go either GPU or CPU.

softyoda commented 3 months ago

I think some functions could have decorators to require or privilege the use of CPU &&|| GPU.