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
marky1991 has joined #pypy
jcea has quit [Ping timeout: 245 seconds]
isuruf53 has joined #pypy
isuruf53 has left #pypy [#pypy]
isuruf has joined #pypy
marky1991 has quit [Remote host closed the connection]
<isuruf>
After building pypy, how do I tell it to generate `pyc` and `pickle` files for the standard library
marky1991 has joined #pypy
DRMacIver has quit [Read error: Connection reset by peer]
DRMacIver has joined #pypy
jcea has joined #pypy
CrazyPython has joined #pypy
CrazyPython has quit [Read error: Connection reset by peer]
<mattip>
About the pickles: you might want to ask somewhere where more people are awake. This is a general python packaging question, not pypy specific
<isuruf>
Agree
<mattip>
or you could clean out the file, touch it to create an empty one, chmod to a-w, and see what test fails
<mattip>
what *new* test fails
<isuruf>
Clean out which file?
<mattip>
lib2to3/Grammar3.7.3.final.0.pickle
[Arfrever] has quit [Quit: leaving]
<isuruf>
I ran the tests on a clean installation. I can run the tests again to see if new tests fail
<arigato>
in out-of-line mode, however, you move it to a separate script which you run once, and then it's done "more carefully" by invoking the real C compiler to check and fix your declarations (which can contain literally "...;" to mean "more stuff here")
<__imp__>
right.
<arigato>
(at least in the "out-of-line API mode"; there's also "out-of-line ABI mode" where the cdef() is in a separate script but still no C compiler is invoked, but that's rarely useful)
<__imp__>
arigato: not being a moron, in overview documentation, the Simple Example (ABI Level, Inline).
<__imp__>
it uses cdef to declare the function prototype
<arigato>
mattip: in bitbucket, "Branch permissions", I think we can add a permissions "can't write" to the branch pattern "*", which should then match all branches
<__imp__>
The same happens in Purely for performance (API Level, out-of-line)
<__imp__>
where cdef is used in same way.
<arigato>
yes
<__imp__>
I still do not understand.
<__imp__>
one says inline the other says outline.
<arigato>
the difference is that one example has everything in one script, and the other has it in two scripts
<__imp__>
hmm
<__imp__>
oook
<__imp__>
put in external file allows it to do more checks .
<arigato>
yes
<__imp__>
thanks.
<arigato>
in fact, the "purely for performance" example shows ffibuilder.set_source()
<arigato>
where you put real C code
<__imp__>
yes.
<__imp__>
my c code will be outside.
<arigato>
then set_source() contains just a #include
<__imp__>
in a full library that I want to make visible from python and write a simple wrapper to be available in python.
<arigato>
like the previous example
<__imp__>
thanks.
<__imp__>
It's related to boltzmann machines.
<arigato>
if you already have a compiled .so/.dll file, then it's the example "API Mode, calling the C standard library"
<arigato>
whose title is maybe a bit confusing...
<__imp__>
no. isn't a .so is a weirdo scientific C code
<arigato>
cfbolz: re list resizing: maybe related to the fact that we resize also on pop() if there are savings? In the C# List<T> type for example, it never resizes down and you have to be explicit about it
<cfbolz>
mattip: that's fine, most benchmarks cut off the first few iterations
<cfbolz>
arigato: yes, I think so
<cfbolz>
But anyway, in this case a linked list is perfectly reasonable
<arigato>
yes
<Dejan>
byebye bitbucket
<cfbolz>
arigato: sadly I discovered that 25% of traced (pre optimization) operations are manipulating the value stack
<cfbolz>
Of inlined frames
<arigato>
not too surprizing
<mattip>
arigato: if heptapod/pypy/cffi looks good, you may want to make it public
<cfbolz>
arigato: it's partly that we use nice abstractions. Eg binary ops write the valuestackdepth 3 times (two pops, one push)
<cfbolz>
Could be 1 instead
<arigato>
mattip: ah thanks
<cfbolz>
Will try to see whether doing it the ugly way helps
oberstet_ has quit [Remote host closed the connection]
<arigato>
note that "hg log -r default" only shows one, so maybe: hg log -r default --template="{rev}\n"
<mattip>
cool
oberstet has joined #pypy
<arigato>
or hg log -r "branch(default)" maybe
<arigato>
uh no
<mattip>
`hg log -r 'heads(public() and branch(default)` says gracinet on mattermost
<arigato>
ah yes, there should be only one public head
<arigato>
fwiw I'm using a custom log format which clearly says "draft", so that's clear for me
<mattip>
well, in theory that works. In practice it spits out closed branches
<arigato>
ah
<arigato>
I think "hg log -r default" should be reliable, because it should give the same rev as "hg up default" would
<arigato>
at least, it should be if evolve is installed
marky1991 has quit [Ping timeout: 265 seconds]
<arigato>
I'm kind of sure that at some point someone will mistakenly update to a draft of "default" and write changes to it and push the result
<arigato>
thus not realizing he's pushing a random pull request
oberstet_ has joined #pypy
<arigato>
the situation could be improved if "hg log" had a reasonable output by default, but it doesn't
oberstet has quit [Read error: Connection reset by peer]
<mattip>
hg up default can give a topic branch without evolve?
<arigato>
as far as I know, yes
<arigato>
in fact, without evolve, "hg push" will never work
<arigato>
I think?
<mattip>
heh, the buildbot master does not have evolve, and `hg heads default` behaves well
<mattip>
the problem is somewhere else for the buildbot hgpoller
<mattip>
I didn't change the source url to heptapod till today, so it was polling the bitbucket instance
<arigato>
well, "hg heads default" doesn't behave well: I bet the buildbot master just picks the first listed head
<marmoute>
hg up default can give a topic branch without topic.
<arigato>
so again if someone makes a PR then it's possible that the next nightly run will be on that PR, randomly
<mattip>
so then I changed the README on bitbucket/pypy/pypy, hgpoller pulled the repo and got a head, then I changed the URL, it pulled and got another head. Truly two heads
<arigato>
we need to carefully reconsider various things because this "all-PR-are-part-of-the-same-repo" is bound to create mistakes
<arigato>
...ah
<arigato>
right, makes sense. need to "hg strip" that extra pointless head
<marmoute>
We are planning to ship a "fix" for this shortly.
<mattip>
someone a few days ago told me I could close it instead :)
<mattip>
cd ../..
<mattip>
marmoute: fix for which part?
marky1991 has joined #pypy
CrazyPython has quit [Remote host closed the connection]
CrazyPython has joined #pypy
<marmoute>
mattip: things without topic enabled pulling changeset with topic (And getting confused by it)
CrazyPython has quit [Remote host closed the connection]
CrazyPython has joined #pypy
<mattip>
right. So we are caught: if we enable topics in the HgPoller, we need to change the buildbot code, and if we don't we could end up building the wrong commit
CrazyPython has quit [Remote host closed the connection]
<mattip>
no, sorry, brain fart. The buildbot only triggers a build, the buildslaves are the ones who pull, update, and build
CrazyPython has joined #pypy
CrazyPython has quit [Remote host closed the connection]
<mattip>
so we need all the slaves to install evolve :(
CrazyPython has joined #pypy
<marmoute>
mattip: What I am saying is that soon™, your hgpoller will simply not get the topic changesets, so you won't need to upgrade it.
<mattip>
cool
oberstet_ has quit [Remote host closed the connection]
marky1991 has quit [Remote host closed the connection]
marky1991 has joined #pypy
CrazyPython has quit [Ping timeout: 268 seconds]
<gracinet>
mattip: but do you give the buildslaves the exact changeset hash to build ?