cfbolz changed the topic of #pypy to: PyPy, the flexible snake (IRC logs: https://botbot.me/freenode/pypy/ ) | use cffi for calling C | the secret reason for us trying to get PyPy users: to test the JIT well enough that we're somewhat confident about it
asmeurer_ has quit [Quit: asmeurer_]
marr has quit [Ping timeout: 240 seconds]
dddddd has quit [Remote host closed the connection]
asmeurer_ has joined #pypy
Arfrever has joined #pypy
adamholmberg has joined #pypy
jcea has quit [Quit: jcea]
adamholmberg has quit [Ping timeout: 256 seconds]
LooCfur_ has joined #pypy
looCfur__ has quit [Read error: Connection reset by peer]
adamholmberg has joined #pypy
adamholmberg has quit [Ping timeout: 240 seconds]
Arfrever has quit [Ping timeout: 240 seconds]
<kenaan> mattip ioctl-arg-size 3e2c7c20e319 /pypy/module/fcntl/interp_fcntl.py: copy cpython approach to sizeof(arg) in ioctl - allocate at least IOCTL_BUFSZ
<kenaan> mattip default c20052c907ba /pypy/module/cpyext/slotdefs.py: decref, fixes issue #2781
<kenaan> mattip ioctl-arg-size 357e97475d38 /pypy/doc/whatsnew-head.rst: document, close branch to be merged
<kenaan> mattip default 03739fa3fc5c /pypy/: merge branch which fixes issue #2776
<bbot2_> Started: http://buildbot.pypy.org/builders/pypy-c-jit-linux-x86-64/builds/5381 [mattip: force build, default]
forgottenone has joined #pypy
inhahe_ has joined #pypy
inhahe__ has quit [Ping timeout: 240 seconds]
tbodt has joined #pypy
<bbot2_> Success: http://buildbot.pypy.org/builders/pypy-c-jit-linux-x86-64/builds/5381 [mattip: force build, default]
tbodt has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
tbodt has joined #pypy
tbodt has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
tbodt has joined #pypy
tbodt has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
tbodt has joined #pypy
tbodt has quit [Client Quit]
energizer has joined #pypy
tbodt has joined #pypy
tbodt has quit [Client Quit]
tbodt has joined #pypy
<arigato> mattip: re cpyext-subclass-setattr: I think it's wrong because it changes the "if w_type0.is_cpytype():" around, too
tbodt has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<arigato> a different hack would be to check if isinstance(space.type(self), W_PyCTypeObject)
tbodt has joined #pypy
<arigato> which is to say, maybe, simply write a method _cpyext_attach_pyobj() inside that class W_PyCTypeObject
<arigato> which would call create_link_pyobj()
<arigato> but otherwise always call create_link_pypy()
<cfbolz> morning
<arigato> hi
<arigato> we probably improved a few of the pypy3 benchmark results in the meantime (he's testing an old version), but otherwise, the comments are relevant
inhahe__ has joined #pypy
<cfbolz> Right
inhahe_ has quit [Ping timeout: 256 seconds]
illume has joined #pypy
<cfbolz> arigato: do we have a clue what the problem is with pypy2 re?
<arigato> not sure what you mean
<cfbolz> arigato: why are pypy2 regular expressions slower than pypy3?: https://usercontent.irccloud-cdn.com/file/ZUqifEb8/1_MzxIdFNg2t_C9HacAW64Vw.png
tayfun26 has joined #pypy
<arigato> after just making a virtualenv and "pip install performance", running "pyperformance run -b regex" fails with an obscure error message for me
<arigato> anyway, there are 4 "bm_regex_*.py", I have no clue which one he means...
asmeurer_ has quit [Quit: asmeurer_]
<arigato> maybe bm_regex_v8.py, that's the only one where pypy is slower
<cfbolz> doesn't sound confusing at all
tbodt has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
tbodt has joined #pypy
tbodt has quit [Client Quit]
<arigato> yes, bm_regex_v8 is much slower on pypy2 than on pypy3
<cfbolz> arigato: that's pretty strange. Should I file a bug so we don't forget?
<arigato> good idea, yes
<cfbolz> The sre engine is the same, maybe some detail in the byte code compiler in the stdlib changed?
<arigato> no clue, attempting valgrind for now (the problem is the same with --jit off)
<cfbolz> Or some unicode detail
<arigato> ok, no, sorry
<arigato> with --jit off, pypy2 doesn't change its speed but pypy3 is slower (still a bit faster than pypy2)
<cfbolz> Does pypy2 generate much code?
kushal has quit [Quit: ZNC 1.6.5 - http://znc.in]
marr has joined #pypy
<arigato> yes, pypy2 generates twice as much code than pypy3
<cfbolz> :-(
antocuni has joined #pypy
<arigato> pypy3 produces a number of loops "# Loop 81 (re UniCharsetSearch at "
<arigato> pypy2 instead only produces 2 loops "# Loop 94 (re StrCharsetSearch at 11"
mcyprian has joined #pypy
<arigato> ok found a hint: pypy2 calls sre_compile 1600 times, pypy3 only 238 times
<arigato> ah
<arigato> ah ha
<arigato> ok, I know what is going on
<arigato> in python 2.7, the re cache is of size 100; in python 3.x it is of size 512
<arigato> so regexp objects are created all the time in python 2.7 in this benchmark
<arigato> this is of course bad for the jit
dddddd has joined #pypy
kdas__ has joined #pypy
<arigato> yes, bumping that number makes pypy2 perform like pypy3
<arigato> how about we bump it even more on pypy (both 2 and 3)? it's a memory-performance tradeoff that in pypy is much more noticeable
kdas__ is now known as kushal
kushal has quit [Changing host]
kushal has joined #pypy
adamholmberg has joined #pypy
adamholmberg has quit [Ping timeout: 255 seconds]
<cfbolz> arigato: pffffffff
<cfbolz> arigato: yes please
kushal has quit [Quit: Leaving]
<kenaan> arigo default 1fe837dccd7b /lib-python/2.7/re.py: Issue #2784 Bump the value of re._MAXCACHE.
<Rotonen> for comparison how does google's re2 handle such tradeoffs? or is all of their performance gain from having taken opinionated limitations in what you can do in their regex engine?
<arigato> Rotonen: I have no clue about google's engine
<njs> Rotonen: this is a pretty silly trade-off, anyone who's serious about regexes compiles them manually instead of relying on caching
* marmoute smile at the "anyone who's serious about" statement
<njs> Rotonen: v8 might be a better thing to compare to, since JS JITs have to cope with people doing silly things
<cfbolz> anyone serious, like, eg, the benchmark?
<njs> cfbolz: I liked how the article described the benchmarks as real applications, and then on every single individual benchmark it talked about how it was not a real application at all :-)
<cfbolz> njs: oh well
energizer has quit [Ping timeout: 268 seconds]
<kenaan> arigo default fb6f7b8f2635 /pypy/module/signal/: Issue #2780 Ignore any non-keyword args in signal.default_int_handler()
* arigato finds it suspicious that rpython.rlib.buffer.Buffer has got a __getitem__()
<cfbolz> arigato: isn't getitem rpython now?
<arigato> yes, and that works, but algorithms that are type-specialized and iterate over characters are suddenly much, much, much slower if passed a Buffer
<arigato> I think that's the reason for issue #2782
<arigato> Buffer defines __getitem__, __setitem__ and __getslice__, but not __setslice__
<arigato> 'bytearray += str' is particularly bogus
<arigato> it special-cases the 'str' argument, but then it converts it to a Buffer, and then iterate with Buffer.__getitem__, which is a virtual method call every time
<arigato> ah no, it goes to a Buffer, and then back to a RPython string
<arigato> but then I don't understand why it's still horribly slow
antocuni has quit [Ping timeout: 240 seconds]
drolando has quit [Remote host closed the connection]
mcyprian has quit [Ping timeout: 240 seconds]
drolando has joined #pypy
pf_moore has joined #pypy
illume has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
lazka has joined #pypy
lazka has quit [Client Quit]
illume has joined #pypy
lesshaste has joined #pypy
adamholmberg has joined #pypy
adamholmberg has quit [Ping timeout: 240 seconds]
lazka has joined #pypy
marky1991 has joined #pypy
marky1991 has quit [Ping timeout: 256 seconds]
raynold has quit [Quit: Connection closed for inactivity]
lazka has quit [Read error: Connection timed out]
planrich has joined #pypy
adamholmberg has joined #pypy
adamholmberg has quit [Ping timeout: 256 seconds]
antocuni has joined #pypy
Rhy0lite has joined #pypy
altendky has quit [Quit: Connection closed for inactivity]
marky1991 has joined #pypy
marky1991 has quit [Remote host closed the connection]
marky1991 has joined #pypy
adamholmberg has joined #pypy
marky1991 has quit [Remote host closed the connection]
marky1991 has joined #pypy
tbodt has joined #pypy
<kenaan> antocuni gc-hooks a88536ae8554 /pypy/interpreter/executioncontext.py: turn AbstractActionFlag._fired_actions into a linked list, so that we can manipulate it freely without doing GC...
altendky has joined #pypy
antocuni has quit [Ping timeout: 240 seconds]
_whitelogger has joined #pypy
tbodt has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
tbodt has joined #pypy
tbodt has quit [Client Quit]
webmeister has joined #pypy
illume has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
tbodt has joined #pypy
tbodt has quit [Client Quit]
tbodt has joined #pypy
tbodt has quit [Client Quit]
tbodt has joined #pypy
tbodt has quit [Client Quit]
tbodt has joined #pypy
tbodt has quit [Client Quit]
tbodt has joined #pypy
tbodt has quit [Client Quit]
illume has joined #pypy
tbodt has joined #pypy
tbodt has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
tbodt has joined #pypy
tbodt has quit [Client Quit]
antocuni has joined #pypy
tbodt has joined #pypy
marky1991 has quit [Remote host closed the connection]
marky1991 has joined #pypy
tbodt has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
tbodt has joined #pypy
tayfun26 has quit [Remote host closed the connection]
tbodt has quit [Client Quit]
tbodt has joined #pypy
tbodt has quit [Client Quit]
tbodt has joined #pypy
mcyprian has joined #pypy
mcyprian has left #pypy [#pypy]
tbodt has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
raynold has joined #pypy
marky1991 has quit [Remote host closed the connection]
marky1991 has joined #pypy
tbodt has joined #pypy
illume has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
tbodt has quit [Client Quit]
<mattip> arigato: in dc1bf38e9aed I tried to test the places that use is_cpytype(), and the translated tests pass
<mattip> logically, should a user-defined subclass of a cpytype have is_cpytype() == True?
marky1991 has quit [Remote host closed the connection]
marky1991 has joined #pypy
tbodt has joined #pypy
drolando has quit [Ping timeout: 240 seconds]
tbodt has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
drolando has joined #pypy
tbodt has joined #pypy
energizer has joined #pypy
marky1991 has quit [Ping timeout: 260 seconds]
marky1991 has joined #pypy
adamholmberg has quit [Remote host closed the connection]
<mattip> arigato: also, I am not sure I follow the logic in https://paste.pound-python.org/show/t8PvUVpeDJcPdeVAh2ii
<mattip> the first part makes those calls slower, so W_BaseCPyObject, W_TypeObject, W_NoneObject, W_BoolObject become slower,
<mattip> and W_PyCTypeObject becomes faster
adamholmberg has joined #pypy
<fijal> I can't seem to be able to install virtualenv using pypy3
<fijal> ah maybe wrong binary
<fijal> no, same thing?
<mattip> why is it pulling things out of /Users/dev/Library/Python/2.7 ?
<mattip> are you running pip in python2 or pypy3 or ... ?
<fijal> I have no idea
antocuni has quit [Ping timeout: 248 seconds]
<fijal> I'm running virtualenv with system python I guess
<fijal> python2
<mattip> that's OK, but somehow your /Users/dev/Downloads/pypy3-510/bin/pypy3 is using the system Python/2.7 library
<mattip> do you have some PY** environment variable set that is screwing with sys.path?
<fijal> I don't think so
<ronan> fijal: old virtualenv can't make pypy3 virtualenvs
marky1991 has quit [Remote host closed the connection]
<ronan> try making a py2 env with everything (pip, setuptools, virtualenv) up to date and use that to make the pypy3 env
marky1991 has joined #pypy
<fijal> pfff
<fijal> ok
<fijal> ronan: well, I managed to set it up without a venv
<fijal> can someone try to reproduce that?
<ronan> yes, I'm getting the same behaviour (with nightly pypy3 and virtualenv)
<cfbolz> mattip: the attach methods aren't the important ones, though. It's fine, if they are a bit slow
adamholmberg has quit [Remote host closed the connection]
<fijal> ronan, cfbolz: any clue about the slowdown?
<cfbolz> Which of the many slowdowns
adamholmberg has joined #pypy
adamholmberg has quit [Read error: Connection reset by peer]
<fijal> cfbolz: the one where "pyc files disable JIT"
<cfbolz> Wat
<cfbolz> No idea, sorry
<cfbolz> The number of traces is really different?
<fijal> I did not look
<fijal> you would need to disable the irrelevant parts of the benchmark etc, sorry too tired :]
<ronan> the JIT is not disabled though, both cases are ~80% jitted
<ronan> (1st is fast, 2nd is slow)
<fijal> I suspect some fuckup with dict strategies?
<cfbolz> fijal: is this pypy3 only?
<cfbolz> Yes, good theory
<cfbolz> fijal: is there an issue yet?
<fijal> no
<fijal> should I create one?
<cfbolz> Please
adamholmberg has joined #pypy
<fijal> I can't seem to be able to log in or reset password
<fijal> so can anyone else do that?
<fijal> ok, maybe logged in?
<fijal> eh, bitbucket really sucks
<mattip> cfbolz: the issue is what is called during track_reference()
<mattip> w_obj._cpyext_attach_pyobj can be either rawrefcount.create_link_pyobj or rawrefcount.create_link_pypy
<cfbolz> And the difference between the two is that one of them is wrong and the other one slow?
<ronan> fijal, cfbolz: the slow version seems to use rbigint instead of machine ints
asmeurer_ has joined #pypy
<cfbolz> ronan: ah, that's regarding Maciej's issue, right? Not matti's
<ronan> yes
<cfbolz> Good, for a minute I was getting very confused
<cfbolz> That sounds like an marshalling isn't producing the right wrapped class?
<cfbolz> unmarshalling
<mattip> cfbolz: in my issue the difference is how the GC collects the w_obj, whether or not it checks the pyobj's refcount
<mattip> (I think, armin would know better)
jcea has joined #pypy
<cfbolz> mattip: OK, but what i am saying is that we should always use the correct version, even if it is slightly slower. Because the important speed is gains are not at all in a slightly faster attach implementation, but in the fact that _cpyext_as_pyobj is much faster
<cfbolz> Making attach faster would be a nice bonus, but that's much less important
<mattip> correct. So I somehow confused the issue. "those calls" I meant what you said
forgottenone has quit [Quit: Konversation terminated!]
tbodt has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<ronan> cfbolz: indeed, the issue seems to be that 0xffffffff turns into a W_LongObject when the .pyc is there
<cfbolz> ronan: 'cool'
<ronan> cfbolz: but smaller values like 0, 32, 0x01f are fine!?
<fijal> maybe pyc only uses 32bit?
<fijal> so you can move the pyc between 32 and 64bit?
nimaje1 has joined #pypy
nimaje1 is now known as nimaje
nimaje has quit [Killed (adams.freenode.net (Nickname regained by services))]
cadr_ has joined #pypy
oberstet has joined #pypy
mwhudson_ has joined #pypy
marky1991 has quit [Remote host closed the connection]
marky1991 has joined #pypy
agronholm_ has joined #pypy
bjs_ has joined #pypy
dddddd has quit [*.net *.split]
ceridwen has quit [*.net *.split]
flub has quit [*.net *.split]
cadr has quit [*.net *.split]
mwhudson has quit [*.net *.split]
agronholm has quit [*.net *.split]
bjs has quit [*.net *.split]
bjs_ is now known as bjs
cadr_ is now known as cadr
marr has quit [Ping timeout: 240 seconds]
flub has joined #pypy
dddddd has joined #pypy
ceridwen has joined #pypy
tbodt has joined #pypy
<ronan> fijal: yes, marshal basically uses a 32-bit format, so ints that don't fit in a signed int32 use a different logic
<fijal> ronan: right, so we should trim our longs if they're small enough on unmarshal?
<ronan> yes
Hasimir has quit [Ping timeout: 248 seconds]
TheAdversary has quit [Ping timeout: 268 seconds]
TheAdversary has joined #pypy
Hasimir has joined #pypy
forgottenone has joined #pypy
marky1991 has quit [Remote host closed the connection]
marky1991 has joined #pypy
mattip has left #pypy ["bye"]
Hasimir has quit [Quit: Vidi, vici, veni]
TheAdversary has quit [Remote host closed the connection]
jacob22_ has quit [Ping timeout: 240 seconds]
adamholmberg has quit [Remote host closed the connection]
adamholmberg has joined #pypy
Rhy0lite has quit [Quit: Leaving]
jacob22_ has joined #pypy
forgottenone has quit [Quit: Konversation terminated!]
marky1991 has quit [Remote host closed the connection]
marky1991 has joined #pypy
mcyprian has joined #pypy
mcyprian has left #pypy [#pypy]
tbodt has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
tbodt has joined #pypy
marr has joined #pypy
drolando has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
drolando has joined #pypy
asmeurer_ has quit [Quit: asmeurer_]
jamesaxl has quit [Quit: WeeChat 2.0.1]
drolando has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
drolando has joined #pypy
Garen has quit [Read error: Connection reset by peer]
Garen has joined #pypy
antocuni has joined #pypy
adamholmberg has quit [Remote host closed the connection]
marky1991 has quit [Ping timeout: 255 seconds]
lritter has joined #pypy
asmeurer_ has joined #pypy
<kenaan> antocuni gc-hooks b853aac49cd8 /: refactor to avoid the ugly 'gchooks' global prebuilt variable. Now we can simply use space.fromcache to get the...
antocuni has quit [Ping timeout: 256 seconds]