Skip to content

Conversation

@toshok
Copy link

@toshok toshok commented Jun 3, 2015

getattr throws an exception if the attribute is not present. getattrFunc already throws the same exception (if there isn't a default value passed in).

For some reason Terminal.app has decided to not let me select text, but the result of this change for django-template.py is:

  pyston django-template.py        : 8.0s baseline: 10.9 (-26.5%)

getattr throws an exception if the attribute is not present.  getattrFunc already throws the same exception (if there isn't a default value passed in).
@toshok
Copy link
Author

toshok commented Jun 3, 2015

more stats:

before change, __cxa_throw is called 142428 times
after change, __cxa_throw is called 46857 times

@toshok toshok mentioned this pull request Jun 3, 2015
kmod added a commit that referenced this pull request Jun 3, 2015
for getattrFunc use getattrInternal instead of getattr
@kmod kmod merged commit 412730c into pyston:master Jun 3, 2015
@kmod
Copy link
Collaborator

kmod commented Jun 3, 2015

cool, that's a pretty nice speedup :)

@toshok toshok deleted the getattr-default-exc branch June 3, 2015 07:39
@undingen
Copy link
Contributor

undingen commented Jun 3, 2015

wow amazing speedup!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants