This is an archive of the discontinued LLVM Phabricator instance.

Make FastMathFlags bitcode serialization to match LLVM 5.0 layout
Needs ReviewPublic

Authored by mehdi_amini on Feb 15 2018, 12:10 PM.
This revision needs review, but there are no reviewers specified.

Details

Reviewers
None
Summary

This make it so that FMF are emitted with a fixed layout derived from the
bitcode emitted by LLVM 5.0.
It is intended to decouple the in-memory representation from the
serialization, to preserve bitcode stability and offer an auto-upgrade
path.

Event Timeline

mehdi_amini created this revision.Feb 15 2018, 12:10 PM
This comment was removed by mcberg2017.

Ok, that could work, however, we would need to change the name of FastMathFlags in bitc to something like FastMathMap so that nobody tries to make any assumptions that it replaces or is a representation of FastMathFlags which is bit map layed out in Value. Agree?

I'll also need to rev the same 6 .bc files for check testing, and there will need to be a note sent to llvm-dev for current .bc and lib users since last Nov that they need to recompile (this is true of my change and this one) that they also need to revise their collections to avoid mapping issues.

Is this something we need to get into the 6.0.0 release?

@tstellar YES.

Ok, that could work, however, we would need to change the name of FastMathFlags in bitc to something like FastMathMap so that nobody tries to make any assumptions that it replaces or is a representation of FastMathFlags which is bit map layed out in Value. Agree?

Sure, do you mind taking this over? I won't have time to finalize this before Sunday.