intel / llvm

Intel staging area for llvm.org contribution. Home for Intel LLVM-based projects.
Other
1.23k stars 737 forks source link

Rename alloca... to something else in the SYCL runtime #1927

Open keryell opened 4 years ago

keryell commented 4 years ago

In Unix alloca() means something very precise for 40+ years and it is also used inside LLVM IR as a specific instruction https://llvm.org/docs/LangRef.html#alloca-instruction In this SYCL implementation it is used all over the place in the runtime as a shortcut for allocation. While alloca() is about allocation too, it is super misleading. Every time time I look at a PR here with "alloca" I get bitten. I mentioned this several times already in the past in some reviews but now I think it should be updated before it spreads too much or is vetoed during up-streaming. "alloc" could be a good trade-off, if "allocation" is too long. Just no "alloca" when it is not about alloca(). :-)

keryell commented 4 years ago

Example when I read https://github.com/intel/llvm/pull/1470 I think: oh, they have implemented C99 VLA as a SYCL/C++ extension? :-)

github-actions[bot] commented 1 month ago

This issue is stale because it has been open 180 days with no activity. Remove stale label or comment or this will be automatically closed in 30 days.