Skip to content

Make native (CPU) runQ parametric on target machine #108

@michael-swan

Description

@michael-swan

Is your feature request related to a problem? Please describe.
Currently, native CPU code compilation passes -march=native to the compiler which will cause issues if the target-machine != the machine on which we compile our Haskell program. This causes illegal instructions to be inserted.

Describe the solution you'd like
I see three possibilities:

  1. Make a variant of runQ that is parametric on target information
  2. Build multiple executable binaries for multiple performance-affecting feature flag variants (i.e. build plain ARM64 binary and also ARM64+SVE binary and also ARM64+SVE+SME, etc.) and gate choice of binary at run-time with target information
  3. Simply compile runQ code with exactly the same level of target-specificity as GHC was provided when the program was itself built. If GHC was compiled with -march=native then it should be safe to use -march=native on our Accelerate code too.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions