Skip to content

549836 Using a moved object in queue_impl.cpp #21915

@KornevNikita

Description

@KornevNikita

Describe the bug

CID 549836: (#1 of 1): Using a moved object (USE_AFTER_MOVE)
5. return_with_moved_parameter: Returning while reference parameter DepEvents is in a moved state.

ResultEvent->getPreparedDepsEvents() = std::move(DepEvents);

I guess we should not use move OR pass DepEvent by-value:

KernelData &KData, std::vector<detail::EventImplPtr> &DepEvents,

To reproduce

  1. Include a code snippet that is as short as possible
  2. Specify the command which should be used to compile the program
  3. Specify the command which should be used to launch the program
  4. Indicate what is wrong and what was expected

Environment

  • OS: [e.g Windows/Linux]
  • Target device and vendor: [e.g. Intel GPU]
  • DPC++ version: [e.g. commit hash or output of clang++ --version]
  • Dependencies version: [e.g. the output of sycl-ls --verbose]

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions