[llvm-commits] [PATCH] Non 8-bit bytes

Philipp Brüschweiler blei42 at gmail.com
Sun Jul 8 01:57:13 PDT 2012


Hi Patrik,

Thanks for looking at the patches. After sending this mail, I
discovered your mail 15min prior, quite the coincidence!

The hardcoded 8s we introduced are only in the target specific code
where we know that BitsPerByte is 8. This should be slightly faster and
maybe a bit more readable. But if you think that we should use
BitsPerByte there as well, I can of course upload a new patch set.

Cheers
Philipp

On Sun, 8 Jul 2012 08:55:17 +0200
Patrik Hägglund H <patrik.h.hagglund at ericsson.com> wrote:
> We also maintain a backend using non-8-bit bytes (16 bits).
> 
> I havn't been able to look deeper into your patches, but on a
> superficial level they looks good! Unfortunately, due to vacation
> plans and other duties, I may not be able to take a second look
> before September.
> 
> Your set of patches is better than ours, at least becuase of the
> second patch "Register sizes are now in bits instead of bytes", which
> we first didn't thought of, but later realized was neccesary (but
> still havn't implemented).
> 
> One quick comment though: You introduce a BitsPerByte, but sometimes
> you still use hardcoded bit-widths (in your added changes). Wouldn't
> it be nicer to use BitsPerByte more often?
> 
> /Patrik Hägglund  
> 
> -----Original Message-----
> From: llvm-commits-bounces at cs.uiuc.edu
> [mailto:llvm-commits-bounces at cs.uiuc.edu] On Behalf Of Philipp
> Brüschweiler Sent: den 6 juli 2012 15:58 To:
> <llvm-commits at cs.uiuc.edu> Subject: [llvm-commits] [PATCH] Non 8-bit
> bytes
> 
> Hi,
> 
> Attached is a series of patches that add (limited) support for non 8
> bit bytes to LLVM.
> 
> The backend that uses this will not be included in the main repo ever,
> so I'm not sure if the attached patches will be welcome. But I thought
> let's try anyway, maybe someone else could find them useful.
> 
> Builtins (like memset) and related optimizations don't work yet. Clang
> needs some additional patches to make use of non 8 bit bytes. Besides
> that everything (that we tested) should work.
> 
> I'm not sure how to do tests for this, as there is obviously no target
> that uses this feature in the repo. The target we are developing has
> 16 bit bytes and seems to work pretty well. All existing tests still
> pass.
> 
> Cheers
> Philipp




More information about the llvm-commits mailing list