char reserved_extended[]; /**< Reserved for future; zero-length array */
} __attribute__((packed, aligned)) npubin_meta;
+/**
+ * @brief Extended metadata for profiling (obtained from a compiler)
+ */
+typedef struct {
+ uint32_t total_size; /**< actual size of extended metadata, not 4K-multiplied one */
+ uint32_t entry_num; /**< total number of entries (i.e., number of vISA insts) */
+ /**
+ * The below shows each entry's data format (little endian).
+ * - [ vISA ID : 4Bytes ][ length : 4Bytes ][ data : 'length' Bytes ]
+ *
+ * If 'data' is string type, it should be null-terminated and its 'length' includes it.
+ * Note that when 'length' is zero, the following 'data' is empty.
+ */
+ char entry_data[];
+} __attribute__((packed, aligned)) npubin_meta_profile;
+
/* Compile-time assert. From http://www.pixelbeat.org/programming/gcc/static_assert.html */
#define ASSERT_CONCAT_(a, b) a##b
#define ASSERT_CONCAT(a, b) ASSERT_CONCAT_(a, b)