Introducing the OFFLOAD_CHECKSUM macro
It's value simply states whether the p4 source code contains an annotation or not. Each HAL could decide how to use/not use this information.
@@ -280,4 +280,10 @@ for enum in hlir16.declarations['Type_Enum']:
for error in hlir16.declarations['Type_Error']:
#[ enum ${error.c_name} { ${', '.join([m.c_name for m in error.members])} };
+#[
+#[ // HW optimization related infos
+#[ // --------------------
+#[ #define OFFLOAD_CHECKSUM ${1 if []!=[x for x in hlir16.sc_annotations if x.name=='Offload'] else 0}
+
+
#[ #endif // __HEADER_INFO_H__
