Displaying 2 results from an estimated 2 matches for "readunalignedle16".
2014 Mar 24
2
[LLVMdev] [RFC] Moving OnDiskHashTable from clang to LLVM
...functions to Endian.h itself.
A bit more detail on this.
For reading, simply changing the existing clients to use Endian.h is a
bit of work, as the read functions in clang::io actually move a cursor
over the read data, so simply switching would actually be something like
this:
- unsigned len = ReadUnalignedLE16(Items);
+ unsigned len = *reinterpret_cast<llvm::support::ulittle16_t *>(Items);
+ Items += 2;
Presumably, hiding the addition helps maintainability. I suppose we
could add functions functions that increment the buffer to Endian.h, and
maybe expose an API like so:
+ unsigned len = sup...
2014 Mar 22
3
[LLVMdev] [RFC] Moving OnDiskHashTable from clang to LLVM
Rafael Avila de Espindola <rafael.espindola at gmail.com> writes:
>> On Mar 22, 2014, at 1:31, Justin Bogner <mail at justinbogner.com> wrote:
>> Also, the header includes a "clang::io" namespace with some operations
>> for reading and writing little endian files. Should these be directly
>> renamed to "llvm::io", or would something like