Hi, I'd like to ask you what's the best way of generating instruction identifiers which are consistent across independent invocations of the LLVM program. One way would be to use a counter and iterate over all the functions, then all the BBs. But are there any guarantees on the ordering of the functions and BBs in the iteration? In extremis, I can sort the functions after name, but what about the basic blocks? Thanks! Stefan Bucur
On Sep 8, 2010, at 5:12 AM, Stefan Bucur wrote:> Hi, > > I'd like to ask you what's the best way of generating instruction > identifiers which are consistent across independent invocations of the > LLVM program. One way would be to use a counter and iterate over all > the functions, then all the BBs. But are there any guarantees on the > ordering of the functions and BBs in the iteration? In extremis, I can > sort the functions after name, but what about the basic blocks? > > Thanks!How do you intend to use these IDs ? - Devang
On Wed, Sep 8, 2010 at 7:16 PM, Devang Patel <dpatel at apple.com> wrote:> > On Sep 8, 2010, at 5:12 AM, Stefan Bucur wrote: > >> Hi, >> >> I'd like to ask you what's the best way of generating instruction >> identifiers which are consistent across independent invocations of the >> LLVM program. One way would be to use a counter and iterate over all >> the functions, then all the BBs. But are there any guarantees on the >> ordering of the functions and BBs in the iteration? In extremis, I can >> sort the functions after name, but what about the basic blocks? >> >> Thanks! > > How do you intend to use these IDs ? > - > Devang >For tracking cumulative code coverage across multiple executions. Each ID would be an index into a bitfield, so I would need the same ID to refer to the same instruction from one execution to the other. Stefan
Maybe Matching Threads
- [LLVMdev] Generating Consistent Instruction IDs
- [LLVMdev] Generating Consistent Instruction IDs
- SYSLINUX Anatomy
- [vhost:linux-next 3/11] drivers/net/ethernet/freescale/dpaa/dpaa_eth.c:2622:20: error: initialization from incompatible pointer type
- Lack of consistent cross-platform behaviour of tools:::buildVignettes()