Allow DataLayout to support arbitrary pointer sizes
Currently, it is impossible to specify a DataLayout with pointer size and index size that is not a whole number of bytes. This patch modifies the DataLayout class to accept arbitrary pointer sizes and to store the size as a number of bits, rather than as a number of bytes. Generally speaking, the external interface of the class as used by in-tree architectures remains the same and shouldn't affect the behavior of architecures with pointer sizes equal to a whole number of bytes. Note the interface of setPointerAlignment has changed and takes a pointer and index size that is a number of bits, rather than a number of bytes. Patch originally by Ajit Kumar Agarwal Differential Revision: https://reviews.llvm.org/D114141
Loading
Please sign in to comment