Building gollvm fails on the latest commit

255 views
Skip to first unread message

Khanh TN

unread,
Apr 13, 2021, 6:09:29 PM4/13/21
to golang-nuts
Hi, I'm building gollvm with both gollvm and LLVM on the latest commit.
It fails and the error reads:
[..]/llvm-project/llvm/tools/gollvm/passes/GoNilChecks.cpp:363:23: error: ‘NoAlias’ was not declared in this scope
       if (AAResult != NoAlias)
                       ^~~~~~~
[..]/llvm-project/llvm/tools/gollvm/passes/GoNilChecks.cpp:363:23: note: suggested alternative: ‘AR_NoAlias’


Can you guys check? Sorry if I'm spamming about gollvm lately.
Thanks!
Khanh

Than McIntosh

unread,
Apr 13, 2021, 7:31:14 PM4/13/21
to Khanh TN, golang-nuts
Thanks for reporting. I'll look into sending a CL.

Cheers, Than


--
You received this message because you are subscribed to the Google Groups "golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/golang-nuts/de629758-4d44-4348-a506-1f2f6404b5b0n%40googlegroups.com.

Than McIntosh

unread,
Apr 14, 2021, 10:53:13 AM4/14/21
to Khanh TN, golang-nuts
OK, I checked in https://go-review.googlesource.com/c/gollvm/+/310069, should be resolved now. Thanks for reporting.

Khanh TN

unread,
Apr 14, 2021, 11:08:36 AM4/14/21
to golang-nuts
Thanks,
I see it's hard to keep syncing with LLVM. They have new commits every minute

Khanh

Khanh TN

unread,
Apr 14, 2021, 11:42:28 AM4/14/21
to golang-nuts
Hi Ian,
My project is currently running on LLVM10.
If I want to use gollvm, do I just have to upgrade to the latest commits?
Thanks
Khanh

Than McIntosh

unread,
Apr 14, 2021, 1:13:17 PM4/14/21
to Khanh TN, golang-nuts
Hi again,

Not quite sure what you are asking-- 

If you want to generated LLVM bitcode and then use that with your version 10 llvm tools, then you'll either need to build a version-10 compatible gollvm, or you'll need to upgrade the LLVM used by your tools/project.

You can try building a V10-compatible gollvm by checking out old versions of the various git repos in your work area. These sha's should give you a working V10 gollvm:

# This is the llvm 10.0.1 final git tag:
LLVM: ef32c611aa214dea855364efd7ba451ec5ec3f74

gollvm: ad0491f483d17893a2439bdb63d0f94124965549

gofrontend: 85641a0f26061f7c98db42a2adb3250c07ce504e

libffi: 737d4faa00d681b4c758057f67e1a02d813d01c2

libbacktrace: 5a99ff7fed66b8ea8f09c9805c138524a7035ece


Cheers, Than

Khanh TN

unread,
Apr 14, 2021, 1:31:03 PM4/14/21
to golang-nuts
Ah, thanks
This will help me a lot
Khanh

Reply all
Reply to author
Forward
0 new messages