jhuber6 wrote:

No, as far as I'm aware 99% of uses of this will be through this function
```
Error extractOffloadFiles(MemoryBufferRef Contents,
                          SmallVectorImpl<OffloadFile> &Binaries);
```

This is an owning binary of the memory, we are given the contents and just need 
to loop through everything. The main change here is that when we create the 
*reference* version we will share the header between multiple entries. This 
will require some way to index into them when creating them, probably just need 
some method to iterate through all the entires and create binaries for them. 
When we create an owning binary we will just copy it over with the shared 
header. The header is very small, so we do not waste an amount of memory worth 
caring about by duplicating it. That's how I'd imagine this works at least

https://github.com/llvm/llvm-project/pull/169425
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to