[llvm-dev] BoF: Shipping Software as LLVM IR (@Upcoming Dev Mtg)
Will Dietz via llvm-dev
llvm-dev at lists.llvm.org
Thu Oct 27 14:54:33 PDT 2016
Hi Mehdi, all!
Apologies for the delay, thanks for getting the conversation started!
(There was a death in my family last week, unfortunately)
I'm gathering these responses and ideas and will be replying in more
ideally we can converge on a candidate set of discussion points before
the BoF :).
On Mon, Oct 17, 2016 at 3:20 PM, Mehdi Amini <mehdi.amini at apple.com> wrote:
> Hi Vikram,
> It is a bit more that just “efficient (de)serialization” as there is some
> amount of tradeoff to make between “size” vs “speed” vs “flexibility” (which
> are all some sort of “efficient”).
Absolutely! Getting a handle on the design space here would be great,
and I'm excited
to look at your flatbuffers prototype and results more carefully.
As you say, the way in which we store (and represent!) bitcode is an essential
part of a system like ALLVM or anything else with a persistent
representation of software as IR.
We have a prototype file format implementation and specification but
it's more of
a placeholder than a serious design yet. Your experiments with bitcode
formats are extremely relevant to our interests :).
> For instance what if we get a faster deserialization but got larger size?
> That might be an issue for some people who’d like to ship bitcode.
> Another thing is that we may get better speed/size by optimizing for the
> “streaming” case but losing the flexibility of loading only a subpart of the
> This is where I’d be interested (and I’ll pay attention) during the BoF to
> hear about all the use cases folks are envisioning.
Additional thoughts I've had on the subject, offhand:
* Hierarchical data-structures beyond modules
* Design of bitcode-based data-structures for multiple "similar"
versions of software
* Taking advantage of 'structure' of programs when viewed at a system scale
In ALLVM all software is described as a composition of bitcode /fragments/
where fragments are intentionally vague for now but could be modules, functions,
Identifying the best abstraction(s) to use here, and designing the
and data-structures for their construction/storage/analysis/transformation is
something we're hoping to address in the ALLVM project-- at the very least
to provide the means to evaluate candidate answers for real systems.
.. Anyway, I'm very interested in your ideas and would like to subscribe
to your newsletter. O:).
> On Oct 17, 2016, at 6:55 AM, Adve, Vikram Sadanand <vadve at illinois.edu>
> Hi Mehdi,
> Yes, we did see your earlier post. Efficient (de)serialization is
> definitely important for both exporting (a la LTO and ThinLTO) and for
> shipping code as IR. I expect most use cases of the latter would benefit.
> // Vikram S. Adve
> // Professor, Department of Computer Science
> // University of Illinois at Urbana-Champaign
> // vadve at illinois.edu
> // http://llvm.org
> On Oct 14, 2016, at 2:41 PM, Mehdi Amini <mehdi.amini at apple.com> wrote:
> I think as soon as you want to have long-lived IR, the bitcode serialization
> is a corner stone piece of the system.
> Somehow related, I posted this recently to llvm-dev:
> http://lists.llvm.org/pipermail/llvm-dev/2016-September/105273.html ; I’d be
> interested how we could leverage a better serialization for various
> On Oct 14, 2016, at 11:32 AM, Will Dietz via llvm-dev
> <llvm-dev at lists.llvm.org> wrote:
> Hi LLVM’ers!
> We are hosting a BoF at this year's Dev Meeting on a subject we hope will be
> of interest to some (many?) of you:
> shipping software (entirely) as LLVM IR.
> You can find our proposal in the meeting schedule online:
> The BoF is scheduled to last 45 minutes, which will go by very quickly!
> To make the best use of the time, we'd like to get a head-start on some of
> the discussions,
> and get a feel for what topics people are most interested in discussing.
> To start things off, here are a few suggestions for things to discuss.
> Thoughts -- and suggestions for additional topics -- welcome.
> * Do you ship software as IR today? What lessons have you learned?
> * Challenges of shipping software as IR
> * Representing software: Beyond a single module
> * From build systems to LLVM IR: toolchains and more
> * What would you do with a platform where everything was available as LLVM
> * What tools or infrastructure would help make that happen?
> (Some background to explain why we’re interested in this topic.)
> ALLVM: We have a project in our group exploring the benefits of shipping
> *all* software on a system as IR. We are building a prototype ALLVM system
> that makes it relatively easy to package and ship software in this way.
> We are researching the benefits this could provide for performance and
> for general software development. We aim to make the ALLVM prototype
> available in open source form to enable other groups to explore these goals.
> Contact us off-list if you’d like to learn more about the ALLVM project.
> ~Will (and Vikram)
> LLVM Developers mailing list
> llvm-dev at lists.llvm.org
More information about the llvm-dev