cfbolz changed the topic of #pypy to: PyPy, the flexible snake (IRC logs: https://botbot.me/freenode/pypy/ ) | use cffi for calling C | "nothing compares to the timeshifter, my personal polar expedition in software" - pedronis
drolando has joined #pypy
yuyichao_ has quit [Ping timeout: 248 seconds]
asmeurer has quit [Quit: asmeurer]
yuyichao_ has joined #pypy
amaury has quit [Ping timeout: 248 seconds]
drolando has quit [Remote host closed the connection]
drolando has joined #pypy
drolando has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
_whitelogger has joined #pypy
Garen has quit [Read error: Connection reset by peer]
Garen has joined #pypy
adamholm_ has quit [Remote host closed the connection]
adamholmberg has joined #pypy
adamholmberg has quit [Remote host closed the connection]
adamholmberg has joined #pypy
adamholmberg has quit [Remote host closed the connection]
adamholmberg has joined #pypy
adamholmberg has quit [Ping timeout: 240 seconds]
adamholmberg has joined #pypy
adamholmberg has quit [Remote host closed the connection]
adamholmberg has joined #pypy
adamholmberg has quit [Ping timeout: 248 seconds]
adamholmberg has joined #pypy
adamholmberg has quit [Remote host closed the connection]
adamholmberg has joined #pypy
adamholm_ has joined #pypy
adamholm_ has quit [Remote host closed the connection]
adamholm_ has joined #pypy
adamholmberg has quit [Ping timeout: 258 seconds]
adamholm_ has quit [Ping timeout: 240 seconds]
ArneBab_ has joined #pypy
ArneBab has quit [Ping timeout: 258 seconds]
asmeurer has joined #pypy
adamholmberg has joined #pypy
adamholmberg has quit [Ping timeout: 240 seconds]
asmeurer has quit [Quit: asmeurer]
pilne has joined #pypy
adamholmberg has joined #pypy
adamholmberg has quit [Remote host closed the connection]
adamholmberg has joined #pypy
traverseda has quit [Ping timeout: 248 seconds]
traverseda has joined #pypy
adamholmberg has quit [Ping timeout: 246 seconds]
forgottenone has joined #pypy
_whitelogger has joined #pypy
pilne has quit [Quit: Quitting!]
asmeurer has quit [Quit: asmeurer]
asmeurer_ has joined #pypy
forgottenone has quit [Quit: Konversation terminated!]
asmeurer_ has quit [Quit: asmeurer_]
adamholmberg has joined #pypy
adamholmberg has quit [Ping timeout: 258 seconds]
amaury has joined #pypy
jacob22_ has quit [Remote host closed the connection]
jacob22_ has joined #pypy
oberstet has joined #pypy
arigato has joined #pypy
adamholmberg has joined #pypy
realitix has joined #pypy
adamholmberg has quit [Ping timeout: 240 seconds]
arigato has quit [Ping timeout: 258 seconds]
oberstet has quit [Quit: Leaving]
Garen has quit [Read error: Connection reset by peer]
Garen has joined #pypy
realitix has quit [Ping timeout: 246 seconds]
amaury has quit [Ping timeout: 248 seconds]
lritter has joined #pypy
ronan has joined #pypy
and1 has joined #pypy
<and1> Hi. Is iteritems() slower in pypy than items() for small dicts?
<ronan> and1: Probably. Benchmark it?
<and1> Generally, do generators slow down iterations noticeably compared to iterating raw lists?
<and1> It's hard to benchmark it since there are a lot of calls for small dicts
<and1> an artificial benchmark is usually menaningless for a JIT
marr has joined #pypy
tnorth has joined #pypy
<tnorth> hi there
cstratak has joined #pypy
<tnorth> CFFI noob question: I have a function void foo(size_t * bar); which writes into bar. Why doesn't this work with cffi: bar = ffi.cast("size_t", 0); bar_ptr = ffi.new("size_t *", bar); foo(bar_ptr)?
<tnorth> I guess that I'm not using ffi.cast() correctly. Why
<tnorth> The following works: bar = ffi.new("size_t []", 0); foo(ffi.addressof(bar, 0))
antocuni has joined #pypy
marvin_ has quit [Remote host closed the connection]
marvin has joined #pypy
marvin is now known as Guest28073
mattip_ has joined #pypy
<mattip_> tnorth: ffi.cast is a cast, not an allocation, so ffi.cast("size_t", 0) is not writeable
adamholmberg has joined #pypy
<tnorth> mattip_: makes sense, thanks
<tnorth> how do I allocate a single int then, do i need to make an array of one item?
adamholmberg has quit [Ping timeout: 240 seconds]
antocuni has quit [Quit: Leaving]
oberstet has joined #pypy
agronholm has joined #pypy
and1 has quit [Quit: Leaving]
<mattip_> tnorth: yes, there really is no other way bar=ffi.new('size_t[1]'), then foo(bar) (assuming foo writes into bar[0])
<tnorth> mattip_: ok, thanks!
oberstet has quit [Ping timeout: 248 seconds]
<kenaan_> rlamy py3.5 f9ce0cdc4b97 /pypy/objspace/std/typeobject.py: Don't segfault in test_typeobject.py::test_incomplete_extend_3()
oberstet has joined #pypy
adamholmberg has joined #pypy
adamholmberg has quit [Ping timeout: 246 seconds]
realitix has joined #pypy
<kenaan_> mattip default 03d614975835 /pypy/doc/: move branch documentation to release, restart whatsnew-head
<kenaan_> mattip release-pypy2.7-5.x 84a2f3e6a7f8 /pypy/: merge default into release
<kenaan_> mattip release-pypy3.5-5.x d72f9800a42b /: merge py3.5 into release
<bbot2> Started: http://buildbot.pypy.org/builders/own-linux-x86-32/builds/5481 [mattip: force build, release-pypy2.7-5.x]
<bbot2> Started: http://buildbot.pypy.org/builders/own-linux-x86-64/builds/6269 [mattip: force build, release-pypy2.7-5.x]
<bbot2> Started: http://buildbot.pypy.org/builders/own-win-x86-32/builds/1557 [mattip: force build, release-pypy2.7-5.x]
<bbot2> Started: http://buildbot.pypy.org/builders/own-linux-s390x/builds/722 [mattip: force build, release-pypy2.7-5.x]
<bbot2> Started: http://buildbot.pypy.org/builders/pypy-c-jit-linux-x86-32/builds/4241 [mattip: force build, release-pypy2.7-5.x]
<bbot2> Started: http://buildbot.pypy.org/builders/pypy-c-jit-linux-x86-64/builds/4967 [mattip: force build, release-pypy2.7-5.x]
<bbot2> Started: http://buildbot.pypy.org/builders/pypy-c-jit-linux-s390x/builds/687 [mattip: force build, release-pypy2.7-5.x]
<bbot2> Started: http://buildbot.pypy.org/builders/build-pypy-c-jit-linux-armhf-raring/builds/1678 [mattip: force build, release-pypy2.7-5.x]
<bbot2> Started: http://buildbot.pypy.org/builders/build-pypy-c-jit-linux-armhf-raspbian/builds/1683 [mattip: force build, release-pypy2.7-5.x]
<bbot2> Started: http://buildbot.pypy.org/builders/build-pypy-c-jit-linux-armel/builds/1927 [mattip: force build, release-pypy2.7-5.x]
<mitsuhiko> fijal: you there? can i bother you about cffi?
<fijal> mitsuhiko: sure
<mitsuhiko> right now cffi always invokes the build script
<mitsuhiko> so even if you invoke `setup.py --version`
<mitsuhiko> which is okay if the header is a static file shipped
<mitsuhiko> but i would like to generate the header on the file
<mitsuhiko> *fly
<mitsuhiko> so trying to figure out if i can trick it to defer the cdef call
<mitsuhiko> to when it actually starts building
<fijal> mitsuhiko: were out for lunch can I answer in 30 min?
<mitsuhiko> sure. no pressure
squeaky_pl has joined #pypy
<squeaky_pl> mattip_, how far are we from putting the new release tag on release-pypy3.5-5.x?
<squeaky_pl> is a cython release the only thing the new release is waiting for?
arigato has joined #pypy
<arigato> mitsuhiko: I'm not sure I follow. does your cffi build script try to open some file explicitly?
<kenaan_> rlamy py3.5 011a075b1e24 /lib-python/3/ctypes/test/test_values.py: Skip tests using pythonapi
antocuni has joined #pypy
<ronan> squeaky_pl: cython 0.27.1 has been released
<mitsuhiko> @arigato: it’s invoking a subprocess to generate the header
<mitsuhiko> Which is very slow
<mattip_> squeaky_pl: actually cpython released, there were some last-minute fixes for pandas+cython and I just now started the builds
<squeaky_pl> mattip_, thanks, gonna warm up my engines
<mattip_> so if all is OK, d72f9800a42b should be pypy3.5-v5.9.0
<mattip_> and 84a2f3e6a7f8 will be pypy2.7-v5.9.0
<mattip_> unless the builds fail or the people at the sprint discover more issues
<kenaan_> fijal memory-accounting 4038d01ba9e9 /rpython/translator/backendopt/writeanalyze.py: fix the problem of lazy setfield
amaury has joined #pypy
<tnorth> hmm why is that invalid: #define FOOBAR ... (in cdef), where in the h file included in set_source() contains #define FOOBAR "foo" ? (work with integer/float types only?)
<fijal> tnorth: yes, int/float only
<tnorth> fijal: ok, thanks. How do I access these macros directly then?
<fijal> tnorth: one "easy" way is to declare a function returning them in set_source
<tnorth> fijal: yep, that works, many thanks
<fijal> of course maybe cffi should do that for you, dunno
<arigato> you can write more directly "static char *const FOOBAR;"
<arigato> mitsuhiko: trying to unwind the thread here. is it a problem that the build script (run with setup.py) is slow?
traverseda has quit [Ping timeout: 240 seconds]
<mitsuhiko> arigato: that and that i do not want to run it yet
<mitsuhiko> effectively i am generating headers as a side effect of compiling my dylib
<mitsuhiko> since setup.py howver also runs for egg-info and --version etc. it means i compile my project even though someone only asks for the version
<mitsuhiko> etc.
<mitsuhiko> and additionally it's something like 5 minute slow :)
<mitsuhiko> well. worst case
<kenaan_> antocuni cpyext-nowrapper 5286504e4045 /pypy/module/cpyext/: (antocuni, ronan): rename nowrapper into no_gc: this new flag imply @rgc.no_collect now
<kenaan_> antocuni cpyext-nowrapper 1fd69c872733 /pypy/module/cpyext/object.py: merge heads
<arigato> you can probably hack around like override the compile() method in a subclass of FFI
<arigato> ...no, it's not even called by setuptools_ext.py
<mitsuhiko> arigato: so compile is the earliest you need the defs?
traverseda has joined #pypy
mattip_ has left #pypy ["bye"]
aboudreault_ has quit [Quit: Ex-Chat]
the_drow has quit [Ping timeout: 260 seconds]
<kenaan_> arigo default 1a1441967500 /pypy/module/cpyext/: (ronan, antocuni, arigo) Small change to prepare the subtype_dealloc() attack
<kenaan_> arigo default 3e50a1272650 /rpython/rtyper/lltypesystem/: (antocuni, arigo) Aaaaah. Found that this simple new test in test_ll2ctypes doesn't actually pass. Fix.
<kenaan_> arigo default ace97c304a30 /rpython/rtyper/lltypesystem/: (antocuni, arigo) More.
<arigato> mitsuhiko: basically, I don't know how to do that cleanly
<arigato> I think you're left with hacking cffi/setuptools_ext.py and change the time when various things occur
<arigato> and then make a PR to cffi
<mitsuhiko> hmm
<mitsuhiko> going to try if i can make this work somehow
<bbot2> Success: http://buildbot.pypy.org/builders/pypy-c-jit-linux-x86-64/builds/4967 [mattip: force build, release-pypy2.7-5.x]
<bbot2> Failure: http://buildbot.pypy.org/builders/own-linux-x86-64/builds/6269 [mattip: force build, release-pypy2.7-5.x]
adamholmberg has joined #pypy
<mitsuhiko> kk. i have a hack that might work
<bbot2> Success: http://buildbot.pypy.org/builders/build-pypy-c-jit-linux-armhf-raring/builds/1678 [mattip: force build, release-pypy2.7-5.x]
amaury has quit [Ping timeout: 258 seconds]
arigato has quit [Ping timeout: 258 seconds]
iblis17_ has joined #pypy
oberstet has quit [Read error: Connection reset by peer]
<kenaan_> rlamy cpyext-nowrapper e99ce0672a27 /pypy/module/cpyext/api.py: (antocuni, ronan) Remove the 'unwrapper' wrapper for no_gc functions
traverseda has quit [Ping timeout: 240 seconds]
realitix has quit [Ping timeout: 240 seconds]
traverseda has joined #pypy
marr has quit [Ping timeout: 248 seconds]
Rhy0lite has joined #pypy
inhahe_ has quit [Ping timeout: 246 seconds]
jacob22 has joined #pypy
jacob22_ has quit [Ping timeout: 258 seconds]
inhahe_ has joined #pypy
yuyichao_ has quit [Ping timeout: 240 seconds]
<squeaky_pl> 5 years ago: running one PyPy translation on my laptop resulted in kernel OOM killing proceses, today: running 4 translations in parallel and working at the same time on my laptop
<marmoute_> squeaky_pl: you got a new laptop ?
yuyichao_ has joined #pypy
<kenaan_> rlamy cpyext-nowrapper cdc783955b0e /pypy/module/cpyext/: (antocuni, ronan, arigo around) Make _Py_Dealloc no_gc and fix its calling from RPython
marr has joined #pypy
<bbot2> Failure: http://buildbot.pypy.org/builders/own-linux-x86-32/builds/5481 [mattip: force build, release-pypy2.7-5.x]
<bbot2> Success: http://buildbot.pypy.org/builders/pypy-c-jit-linux-x86-32/builds/4241 [mattip: force build, release-pypy2.7-5.x]
<jantje> Hm. Can I upload vmprof results to the web server afterwards?
tnorth has quit [Remote host closed the connection]
tnorth has joined #pypy
<jantje> could not load libunwind at runtime. error: libunwind.so: cannot open shared object file: No such file or directory
<bbot2> Success: http://buildbot.pypy.org/builders/build-pypy-c-jit-linux-armel/builds/1927 [mattip: force build, release-pypy2.7-5.x]
<jantje> hmhmm
<bbot2> Success: http://buildbot.pypy.org/builders/build-pypy-c-jit-linux-armhf-raspbian/builds/1683 [mattip: force build, release-pypy2.7-5.x]
tnorth has quit [Ping timeout: 258 seconds]
tnorth has joined #pypy
<bbot2> Success: http://buildbot.pypy.org/builders/pypy-c-jit-linux-s390x/builds/687 [mattip: force build, release-pypy2.7-5.x]
cstratak has quit [Quit: Leaving]
<squeaky_pl> is 5.9 gonna be beta release initially?
<squeaky_pl> (it says it is beta on the branch)
realitix has joined #pypy
amaury has joined #pypy
arigato has joined #pypy
arigato has quit [Quit: Leaving]
ronan has quit [Ping timeout: 258 seconds]
antocuni has quit [Ping timeout: 248 seconds]
TheAdversary has quit [Disconnected by services]
TheAdversary has joined #pypy
mattip_away has joined #pypy
<mattip_away> squeaky_pl: pypy3.5 is still beta quality
<mattip_away> slow in urf8 processing and not fully complient
<mattip_away> pypy2.7 should not be marked beta
mattip_away has quit [Remote host closed the connection]
drolando has joined #pypy
forgottenone has joined #pypy
asmeurer_ has joined #pypy
exarkun has quit [Read error: Connection reset by peer]
amaury has quit [Ping timeout: 240 seconds]
asmeurer_ has quit [Quit: asmeurer_]
exarkun has joined #pypy
jamesaxl has quit [Read error: Connection reset by peer]
jamesaxl has joined #pypy
<squeaky_pl> mattip, right, 2.7 says final
and1 has joined #pypy
<and1> Hi, is using iteritems() instead of iteraring over items() slower for small dicts?
<and1> Another question: did something change in GC in the last half-a-year/year that makes processes use more memory on average?
<nanonyme> Good that the former question disappears with Python3, huh?
drolando has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<and1> I would expect a construct list(<genexpr>) to be optimized anyway
drolando has joined #pypy
jacob22 has quit [Remote host closed the connection]
<nanonyme> IOW Python3 does not have iteritems
jacob22 has joined #pypy
<and1> yes, but you can use list(d.items())
<nanonyme> Why would you want to do that?
<and1> maybe it's faster to construct one list than retrieve generators from a frozen stack - hence my question
<and1> and pypy values simplicity of code and has poor performance for itertools, which uses generators extensively
<simpson> and1: Can you share your benchmark?
<and1> simpson: I don't have one.
<and1> my tests for production code indicated there's no noticeable difference
<and1> but I would like to be sure there's no point in avoiding using generators
<simpson> It's probably fine.
<bbot2> Started: http://buildbot.pypy.org/builders/pypy-c-jit-macosx-x86-64/builds/3321 [mattip: force build, release-pypy2.7-5.x]
realitix has quit [Quit: Leaving]
marky1991_2 has joined #pypy
marky1991_2 has quit [Remote host closed the connection]
marky1991_2 has joined #pypy
marky1991 has quit [Ping timeout: 240 seconds]
Rhy0lite has quit [Quit: Leaving]
drolando has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
marky1991_2 has quit [Ping timeout: 240 seconds]
<bbot2> Failure: http://buildbot.pypy.org/builders/own-linux-s390x/builds/722 [mattip: force build, release-pypy2.7-5.x]
marky1991 has joined #pypy
marky1991 has quit [Remote host closed the connection]
marky1991 has joined #pypy
yuyichao_ has quit [Ping timeout: 240 seconds]
lritter has quit [Ping timeout: 240 seconds]
marky1991 has quit [Ping timeout: 240 seconds]
marky1991 has joined #pypy
marr has quit [Ping timeout: 240 seconds]
marky1991 has quit [Remote host closed the connection]
marky1991 has joined #pypy
tnorth has quit [Ping timeout: 258 seconds]
marky1991 has quit [Read error: Connection reset by peer]
marky1991 has joined #pypy
yuyichao_ has joined #pypy
drolando has joined #pypy
<bbot2> Failure: http://buildbot.pypy.org/builders/own-win-x86-32/builds/1557 [mattip: force build, release-pypy2.7-5.x]
and1 has quit [Quit: Leaving]
amaury has joined #pypy
jamesaxl has quit [Read error: Connection reset by peer]
jamesaxl has joined #pypy
forgottenone has quit [Quit: Konversation terminated!]
jcea has joined #pypy
oberstet has joined #pypy
yuyichao_ has quit [Ping timeout: 240 seconds]
jcea has quit [Remote host closed the connection]
jcea has joined #pypy
adamholmberg has quit [Remote host closed the connection]
marky1991 has quit [Ping timeout: 248 seconds]
marr has joined #pypy
pilne has joined #pypy
marky1991 has joined #pypy
bjs has quit [Ping timeout: 264 seconds]
bjs has joined #pypy
arnsholt has quit [Ping timeout: 260 seconds]
arnsholt has joined #pypy
marky1991 has quit [Ping timeout: 248 seconds]
oberstet has quit [Ping timeout: 240 seconds]
Treelife has joined #pypy
bjs has quit [Ping timeout: 264 seconds]
bjs has joined #pypy
kipras is now known as kipras`away
asmeurer__ has joined #pypy
asmeurer__ has quit [Quit: asmeurer__]
bjs has quit [Ping timeout: 248 seconds]
bjs has joined #pypy
amaury has quit [Ping timeout: 248 seconds]
exarkun has quit [Read error: Connection reset by peer]
exarkun has joined #pypy