[llvm-dev] lld: sigbus error handling

Ed Maste via llvm-dev llvm-dev at lists.llvm.org
Mon Oct 30 16:32:43 PDT 2017


On 23 October 2017 at 18:49, Rui Ueyama via llvm-dev
<llvm-dev at lists.llvm.org> wrote:
>>
>> BTW, posix_fallocate() might provide better portability and decrease the
>> likelihood of falling back on ftruncate().
>
> Yes, but we want to avoid that function because when it falls back, it is
> very slow. What it does when fallocate(2) is not available is to actually
> write 0 to every block to make sure that all disk blocks are allocated.

Note that posix_fallocate may return EINVAL if the underlying
filesystem does not support the operation.


More information about the llvm-dev mailing list