Giter VIP home page Giter VIP logo

Comments (12)

mochizk avatar mochizk commented on June 18, 2024 2

I faced a similar issue in other extensions and make install with_llvm=no worked.

from plgo.

microo8 avatar microo8 commented on June 18, 2024

Can I see your code? It builds? sample.so is in the build dir?

from plgo.

biter777 avatar biter777 commented on June 18, 2024

Of course. See below...
On pg10 no problem, but on pg11 it swears at the absence of a .bc file.
And if I install the extension myself on pg11, it works.

On the 'build' dir I have:
Makefile
sample.control
sample.h
sample.so
sample--0.1.sql

Code:

package main

import (
	"github.com/microo8/plgo"
)

func MakeTsVectorTrigger(td *plgo.TriggerData) *plgo.TriggerRow {
	return td.NewRow
}

from plgo.

AoAnima avatar AoAnima commented on June 18, 2024

same problem

from plgo.

chet0xhenry avatar chet0xhenry commented on June 18, 2024

It looks like it is related to the new JIT in postgresql:
https://www.postgresql.org/docs/current/jit-extensibility.html

from plgo.

howesteve avatar howesteve commented on June 18, 2024

Same problem here.

from plgo.

bartek5186 avatar bartek5186 commented on June 18, 2024

I faced a similar issue in other extensions and make install with_llvm=no worked.

It works. But... There should be a llvm .bc producer also.

from plgo.

microo8 avatar microo8 commented on June 18, 2024

Can someone please take a look at it? I don't know even where to start and also I can't reproduce it.

from plgo.

mochizk avatar mochizk commented on June 18, 2024

I think you can reproduce this by configuring postgresql with ./configure --with-llvm to enable JIT. In that case Makefile try to generate llvm bit code files(.bc), but cannot generate it from Go code.

In src/makefiles/pgxs.mk, with_llvm variable is used to control this behavior.
So I use make install with_llvm=no, but I'm not sure this is correct solution.

from plgo.

bartek5186 avatar bartek5186 commented on June 18, 2024

install simple:
postgresql-11-postgis-2.5, postgresql-server-dev-11. under ubuntu 18.04.

Yesterday i found some sources, but it's too hard for me at this moment.

https://github.com/SRI-CSL/gllvm 
https://blog.gopheracademy.com/advent-2018/llvm-ir-and-go/

from plgo.

biter777 avatar biter777 commented on June 18, 2024

Any news on the subject?
p.s. Maybe it's easy to make a copy of the compiled extension without the bc file?

from plgo.

microo8 avatar microo8 commented on June 18, 2024

Just use make install with_llvm=no

from plgo.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.