Message286775
| Author |
serhiy.storchaka |
| Recipients |
larry, martin.panter, methane, python-dev, serhiy.storchaka, vstinner |
| Date |
2017年02月02日.12:43:13 |
| SpamBayes Score |
-1.0 |
| Marked as misclassified |
Yes |
| Message-id |
<1665105.2yPUgnUkr1@raxxla> |
| In-reply-to |
<1486035435.1.0.158630955714.issue29300@psf.upfronthosting.co.za> |
| Content |
> So yeah, the "side effect" is that struct.pack("i", 1) becomes 1.56x faster
> (-36%). Ok, maybe it was my main goal ;-) I also mentioned the "new" (?)
> contiguous requirement on buffers.
struct.pack() always was faster than int.to_bytes(). I wanted to speed up
int.to_bytes(), and after converting to Argument Clinic in issue20185 it have
became faster than struct.pack(). But after converting the struct module to
Argument Clinic struct.pack() is faster than int.to_bytes() again! Now I need
to find other ways to make int.to_bytes() even faster to win this chase. |
|