Rust-GPU / Rust-GPU/rust-gpu

Warn (or error) on a non-pub entrypoint

Open
#155 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement help wanted
Dominant language
Rust
Stars
3.4k
Forks
125
PR merge metrics
No merged PRs in 30d

Description

(originally filed at https://github.com/EmbarkStudios/rust-gpu/issues/1140)

When setting #[spirv(fragment)] on a non-pub function, rust-gpu errors with an obtuse error:

error: error:0:0 - No OpEntryPoint instruction was found. This is only allowed if the Linkage capability is being used.

This case should be detected and warned or even made an error if it is not supported. Further, the error message should be fixed as suggested in https://github.com/EmbarkStudios/rust-gpu/issues/1139.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the reported case by applying #[spirv(fragment)] to a non-pub function and observe the current No OpEntryPoint error. Trace the entrypoint validation and diagnostic path, then make this case produce the intended warning or error with a clearer message, as described in the linked issue.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
compilers
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.