We already have noreturn attribute. I have identified two more attributes that might be useful. These are pure and unused.
[PATCH 1/2] kern/strings.c (strlen): mark with attribute pure Attribute pure means that a function doesn't have any effects except the return value, and the return value doesn't depend on return values from other functions. GCC optimizes functions marked with this attribute. [PATCH 2/2] ddb/db_command.c (db_help_cmd): mark with attribute unused Attribute unused means just that, that a function is unused. It might be useful to identify and mark these functions. They might be scheduled for removal in future versions.