Check if an image is compatible with current system's environment. The system environment is given as a 'target-id' which has the form:
Declared in <llvm/Frontend/Offloading/Utility.h>
bool
isImageCompatibleWithEnv(
StringRef ImageArch,
uint32_t ImageFlags,
StringRef EnvTargetID);
<target-id> := <processor> ( ":" <target-feature> ( "+" | "-" ) )*
If a feature is not specific as '+' or '-' it is assumed to be in an 'any' and is compatible with either '+' or '-'. The HSA runtime returns this information using the target-id, while we use the ELF header to determine these features.
True if the image is compatible with the given environment.
| Name | Description |
|---|---|
| ImageArch | Processor architecture of the image. |
| ImageFlags | ELF feature flags of the image. |
| EnvTargetID | Target-id describing the system's environment. |