Fix IREE executable library version for branch_mul
IREE executable library version was bumped at https://github.com/openxla/iree/pull/16757/
Need to specify the prebuilt used in branch_mul since it is not built
with the latest IREE compiler.
Change-Id: I4d640be66c9dfdbb7891f6db875ea3a80faa9e96
diff --git a/samples/branch_mul/branch_mul.c b/samples/branch_mul/branch_mul.c
index 4a234e4..57fc6f9 100644
--- a/samples/branch_mul/branch_mul.c
+++ b/samples/branch_mul/branch_mul.c
@@ -28,6 +28,8 @@
#include "samples/branch_mul/branch_mul_c.h"
#include "samples/branch_mul/branch_mul_expected.h"
+#define IREE_HAL_EXECUTABLE_LIBRARY_VERSION_0_3 0x00000003u
+
static int8_t ret0[3][2][256] = { 0 };
static iree_status_t run_test() {
iree_hal_executable_environment_v0_t environment;
@@ -42,15 +44,14 @@
} library;
library.header =
(const iree_hal_executable_library_header_t**)iree_elf_call_p_ip(
- query_fn_ptr, IREE_HAL_EXECUTABLE_LIBRARY_VERSION_LATEST,
- &environment);
+ query_fn_ptr, IREE_HAL_EXECUTABLE_LIBRARY_VERSION_0_3, &environment);
if (library.header == NULL) {
return iree_make_status(IREE_STATUS_NOT_FOUND,
"library header is empty (version mismatch?)");
}
const iree_hal_executable_library_header_t* header = *library.header;
- if (header->version != IREE_HAL_EXECUTABLE_LIBRARY_VERSION_LATEST) {
+ if (header->version != IREE_HAL_EXECUTABLE_LIBRARY_VERSION_0_3) {
return iree_make_status(IREE_STATUS_INVALID_ARGUMENT,
"library version error");
}