[LLVMdev] Metadata for Argument, BasicBlock

Richard Osborne richard at xmos.com
Wed May 9 02:29:34 PDT 2012


On 07/05/12 22:58, Dan Gohman wrote:
> What kind of things might basic block metadata be used for?
>
> Dan
I'd be really keen for this to go in. In order to support worse case 
execution time analysis on compiled binaries we (XMOS) need a way to 
mark paths that should be excluded when checking timing constraints. A 
typical query is "Check the worse case execution time from A to B 
excluding paths which pass through location C is no more than x 
nanoseconds". Here C would be a location marked in the source code. A 
natural way to implement this would be to have the frontend attach 
metadata to the basic block containing C associating the block with the 
label "C". Trying to attach the information to an individual instruction 
is problematic since that specific instruction might be removed / 
hoisted. Other solutions I can think of might prevent optimizations from 
happening (which is something we want to avoid).

Regards,

Richard

-- 
Richard Osborne | XMOS
http://www.xmos.com




More information about the llvm-dev mailing list