[lld] r250297 - [ELF2][mips] Support both big and little endian MIPS 32-bit targets

Rui Ueyama via llvm-commits llvm-commits at lists.llvm.org
Wed Oct 14 13:39:28 PDT 2015


On Wed, Oct 14, 2015 at 1:25 PM, Rafael EspĂ­ndola <
llvm-commits at lists.llvm.org> wrote:

> > One solution would be to define:
> >
> > template <endianness endian>
> > inline uint32_t read32(const void *p) { return *(const
> detail::packed_endian_specific_integral<uint32_t, endian, unaligned> *) p; }
> >
> > and similar for write32, and implement Endian-independent things in
> terms of those.
>
> LGTM :-)


It doesn't look good to me. It looks more intricate than necessary. I
really prefer the current code over the suggested one.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20151014/054a77ad/attachment.html>


More information about the llvm-commits mailing list