cfbolz changed the topic of #pypy to: PyPy, the flexible snake (IRC logs: https://quodlibet.duckdns.org/irc/pypy/latest.log.html#irc-end ) | use cffi for calling C | if a pep adds a mere 25-30 [C-API] functions or so, it's a drop in the ocean (cough) - Armin
CrazyPython has quit [Read error: Connection reset by peer]
jcea has quit [Quit: jcea]
igitoor has quit [Remote host closed the connection]
jvesely has quit [Quit: jvesely]
_whitelogger has joined #pypy
_whitelogger has joined #pypy
dddddd has quit [Remote host closed the connection]
forgottenone has joined #pypy
lritter has joined #pypy
infinite has quit [Ping timeout: 276 seconds]
infinite has joined #pypy
Taggnostr has quit [Remote host closed the connection]
Taggnostr has joined #pypy
<kenaan> arigo cffi/cffi 7d1496495e25 /cffi/_embedding.h: Issue #427 Fix: it's invalid according the API to call PyGILState_Release(PyGILState_UNLOCKED) manually at start...
antocuni has joined #pypy
alexge50- has joined #pypy
alexge50 has quit [Read error: Connection reset by peer]
altendky has quit [Quit: Connection closed for inactivity]
antocuni has quit [Ping timeout: 240 seconds]
brown85 has joined #pypy
<brown85> I saw attrs packages (https://github.com/python-attrs/attrs), as i remembers pypy classes have similar behaviour to cpython __slots__ so i assume the memory usage wont be less. anyone have experience with attrs on pypy to tell whether the memory\timing usage of this package will be dramatically higher than "normal" classes?
BPL has joined #pypy
jvesely has joined #pypy
oberstet has joined #pypy
antocuni has joined #pypy
dddddd has joined #pypy
_whitelogger has joined #pypy
<tos9> brown85: It won't be no (and presumably you know that unless you've got obscenely large numbers of objects you're creating that this won't matter much anyhow)
<tos9> (neither on CPython nor PyPy)
<arigato> brown85: you are probably making incorrect assumptions
<arigato> pypy behaves like CPython as much as possible, with __slots__ and the other even more messy things, but they won't make your instances smaller---the instances are small to start with, on pypy
<arigato> (sorry, maybe I misread your sentence. another way to read it would be "I assume using attrs won't make instances smaller on pypy", in which case you're correct)
<tos9> arigato: ok, back at diagnosing that macos library thing and.. maybe my brain is a bit clearer now but just noticed a funny thing
<tos9> arigato: which is first of all that venv/bin/pypy3 is just a symlink to the actual global binary -- and that global binary has the library path in it
<tos9> i.e. e.g. /usr/local/Cellar/pypy3/7.1.1_1/libexec/lib/libpypy3-c.dylib by default
<tos9> but if I literally replace that path in the global pypy binary with a nonsense one that doesn't exist, everything still appears to work
<tos9> though otool shows me the nonexisting path that I put in there
jcea has joined #pypy
<tos9> I think last time you were explaining to me what the contents of that binary are exactly -- you said it's just a compiled version of the main function for pypy?
<tos9> (ok, and at least now I think I see where those OperationErrors come from, they're directly in targetpypystandalone.py)
<arigato> yes, the binary itself is as small as possible
<arigato> we wouldn't need a binary at all if there was a portable way to make the dynamic library executable
<tos9> ah interesting, I didn't know libaries were executable anywhere
<tos9> but it doesn't look like the path that's in the binary does anything? Or anything I can tell so far
<arigato> it's a little known feature at least on linux. but it's not as simple as putting a main() in a library
* tos9 nods
<arigato> maybe the path in the binary is used as a first try, but some fallback logic finds the library anyway in this case?
<tos9> I think it'd need to be the reverse if anything to explain the behavior I see no
<tos9> er no sorry you're right
<tos9> but yeah I was also assuming that there has to be some logic somewhere that's trying another path
<tos9> so now I guess time to hunt that down
<brown85> @tos9 arigato, as i understand your answers referred the the memory issue only? any idea about the timing?
<tos9> brown85: Both
<arigato> the performance? you can even less compare in the abstract performance than you can memory
<tos9> brown85: You are fine :), use attrs.
<arigato> use attrs if you feel that it's giving you something or if you really measured a benefit. If not, don't
<arigato> use it if you're used to it and don't want to change your habits, too.
<brown85> @arigato ofc i mean to get answer on specific input dataset, just want to get any answer to start with because i could not find any compare on google
<arigato> OK, sorry to be vague about it, the truth is far more complicated than just a simple number
<brown85> I agree, that why i;ve searched for benchmark
<arigato> if the benchmark gives you a simple number, it's too simple
<brown85> They might give different answers for different input data
<arigato> yes. but yes, I don't know attrs in detail but I would expect whatever it does to have no real memory or performance impact on pypy, unless it does too magical things that help on CPython but screw up PyPy's logic
CrazyPython has joined #pypy
<fijal> I think attrs put effort into not doing anything too magical
<arigato> good
<tos9> I have never once seen attrs related things show up on profiles for reasonable code.
altendky has joined #pypy
<kenaan> JulianB license-update dc6e2204f014 /LICENSE: Mention the newer directories as well under MIT in the license.
<tos9> ^ is that commit correct?
<tos9> (ctype_configure doesn't look like it exists anymore, but I left it in for whatever branch or time it did)
antocuni has quit [Ping timeout: 265 seconds]
<kenaan> JulianB https-readme 35efaa242484 /README.rst: HTTP -> HTTPS the readme.
CrazyPython has quit []
xcm has quit [Remote host closed the connection]
xcm has joined #pypy
igitoor has joined #pypy
igitoor has quit [Changing host]
igitoor has joined #pypy
<mattip> tos9: are you looking for how pypy finds its stdlib?
<tos9> mattip: yes, though probably for the process that occurs just before that
<tos9> (actually first I went to look for lunch, but at some point I'll come back to that)
<mattip> pypy/interpreter/app_main.py has a setup_bootstrap_path()
<tos9> mattip: but pointer to that would probably be super helpful!
<tos9> a ha, interesting, that function has a comment specifically about the encodings module
<tos9> mattip: thanks, that'll help
brown85 has quit [Remote host closed the connection]
ekaologik has joined #pypy
<mattip> I think pytest uses attrs, so we are by proxy using it in the venv that runs extra_tests
CrazyPython has joined #pypy
lritter has quit [Ping timeout: 240 seconds]
antocuni has joined #pypy
fryguybob has quit [Quit: leaving]
antocuni has quit [Ping timeout: 246 seconds]
xcm has quit [Remote host closed the connection]
jvesely has quit [Quit: jvesely]
xcm has joined #pypy
marky1991 has joined #pypy
antocuni has joined #pypy
CrazyPython has quit [Read error: Connection reset by peer]
antocuni has quit [Ping timeout: 268 seconds]
fryguybob has joined #pypy
ekaologik has quit [Quit: https://quassel-irc.org - Komfortabler Chat. Überall.]
jacob22_ has quit [Read error: No route to host]
jacob22 has joined #pypy
forgottenone has quit [Quit: Konversation terminated!]
YannickJadoul has joined #pypy
<YannickJadoul> I believe I've got the `_abc` module for Python 3.7 working, but I've got 2 problems
<YannickJadoul> 1) Should '_abc' be part of `working_modules`, `default_modules`, or `essential_modules`?
jvesely has joined #pypy
<YannickJadoul> 2) After a full translation and build, and then packaging, I still get `AssertionError: Filename /home/yannick/pypy/lib-python/3/_weakrefset.py does not start with any of these prefixes: ['/home/yannick/pypy-tmp', '/home/yannick/pypy-tmp']` when running `virtualenv`. Is this a familiar error?
<YannickJadoul> (`/home/yannick/pypy/lib-python/3/` is nót part of `sys.path` when I run the newly-built PyPy executable)
<YannickJadoul> OK, I think I know what's wrong for 2). I'm importing that `_weakrefset` to implement `_abc` but it's not a built-in module.
xcm has quit [Remote host closed the connection]
xcm has joined #pypy
<ronan> YannickJadoul: I'd say it should be in essential_modules, but I'm not really sure what the different categories are for
<ronan> about 2), importing a stdlib module from a builtin one doesn't really work
<YannickJadoul> ronan: I found these descriptions in the code:
<YannickJadoul> if p in pypyoption.essential_modules: text.append("This module is essential, included by default and should not be removed.")
<YannickJadoul> elif p in pypyoption.default_modules: text.append("This module is expected to be working and is included by default.")
<YannickJadoul> elif p in pypyoption.working_modules: text.append("This module is expected to be fully working.")
<YannickJadoul> And yes, I've just realized the CPython implementation also uses sets of weakrefs (which are built-in), instead of _weakrefset.WeakSet :-(
antocuni has joined #pypy
antocuni has quit [Ping timeout: 240 seconds]
raekye has joined #pypy
<raekye> Hello
<raekye> I ran vmprof like pypy -m vmprof --web --jitlog sudoku.py ../input-64.txt to upload the trace
<raekye> but the CPU profile spins indefinitely and the jit log gives 500 internal server error
<raekye> It seems the other JIT profiles on vmprof.com give 500 internal server error too...
<ronan> raekye: I guess the server is borked again, someone (fijal?) needs to restart it
<raekye> I see, thanks
<raekye> I got the jitlog querier to work on a local log
<raekye> Although it doesn't display what I want - is there a way to dump the assembly for a function that pypy's jit generates?
BPL has quit [Quit: Leaving]
<raekye> For example, for openjdk/java there's -XX:+PrintAssembly
<tos9> it can show the assembly IIRC
<tos9> I *think* it probably still works even though it tells you to use vmprof, but I'm not sure
<tos9> (if not, the vmprof server is something you can get running locally somewhat OK last time I tried)
<raekye> I did find it, which is why I headed over to vmprof, since I assumed development moved over there
<raekye> I'll take a closer look to see if I can get it running