Errors compiling LLVM on RPi3 at 330019
Dimitry Andric
dim at FreeBSD.org
Mon Feb 26 18:56:53 UTC 2018
On 26 Feb 2018, at 19:47, bob prohaska <fbsd at www.zefox.net> wrote:
>
> On Mon, Feb 26, 2018 at 07:16:18PM +0100, Dimitry Andric wrote:
>> On 26 Feb 2018, at 16:23, bob prohaska <fbsd at www.zefox.net> wrote:
>>>
>>> At revision 330019 -DNO_CLEAN buildworld stops with
>>>
>>> --- Target/X86/X86ISelDAGToDAG.o ---
>>> /usr/src/contrib/llvm/lib/Target/X86/X86ISelDAGToDAG.cpp:2463:7: error: use of undeclared identifier 'SelectCode'
>>> SelectCode(ZextTarget.getNode());
>>> ^
>>> /usr/src/contrib/llvm/lib/Target/X86/X86ISelDAGToDAG.cpp:2464:7: error: use of undeclared identifier 'SelectCode'
>>> SelectCode(Brind.getNode());
>>> ^
>>> /usr/src/contrib/llvm/lib/Target/X86/X86ISelDAGToDAG.cpp:2480:5: error: use of undeclared identifier 'SelectCode'
>>> SelectCode(VSelect.getNode());
>>> ^
>>> /usr/src/contrib/llvm/lib/Target/X86/X86ISelDAGToDAG.cpp:3072:3: error: use of undeclared identifier 'SelectCode'
>>> SelectCode(Node);
>>>
>>> Should I wait for an update, or run cleandir? This is on a Pi3.
>>
>> From which revision were you upgrading?
> Probably revision 329997
>
>> It looks like your .inc files
>> were not regenerated properly by llvm-tblgen,
>
> The system has been plagued by stoppages during clang build.
> Sometimes in llvm-tblgen, but not always. A frequent error
> is 137, from clang, but "out of swap" happens too. Been using
> the -DNO_CLEAN option to pick up where it left off.
Right, I suspect that is the root cause here. When llvm-tblgen or
clang-tblgen are writing a .inc file, and they are killed by OOM in the
middle of it, the file will have been partially written, and most likely
be incomplete. However, on the next NO_CLEAN run, make thinks the file
is up-to-date, so starts the build of the dependencies of those .inc
files, leading to errors like you report.
Ideally the table-generated files should be atomically replaced, but
we currently don't do that. Upstream also compares the output with any
previous file, if it exists, and does not update it if it has not
changed. I think I still have a diff laying around to do just that,
but I never finished it up...
In any case, my advice here would be to either add some swap space, or
lower your -j level, to minimize the chance of files corrupted by OOM
killing.
-Dimitry
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 223 bytes
Desc: Message signed with OpenPGP
URL: <http://lists.freebsd.org/pipermail/freebsd-arm/attachments/20180226/1e962cdb/attachment.sig>
More information about the freebsd-arm
mailing list