Skip to content

Unified API: Add a member to Array that indicates it's backend type #1068

@jramapuram

Description

@jramapuram

If I have an Array created using afcpu and one on say a cuda device using afcuda then I would expect the following to throw an exception (or err code in C):

af_mul(a, b); //where a is cpu & b is cuda

It currently just SEGFAULT's which I think is terrible behavior.

To do this there needs to be some sort of internal flag in the Array, eg: array.backend() & the library needs to handle this logic internally.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No 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