8 ms·
Taking a sabbatical to work on Ruby profiling tools
- SOLAR_FIELDS 9y agoSabbaticals should be more condoned in the workforce. I suspect we may see less turnover in many areas of software engineering if this was an option after say a 3 or 4 year tenure at some company.
- kelnos 9y agoAbsolutely agree. And if they are unpaid, and the employee can schedule them around projects finishing (or at least in places where multiple people are responsible for them so that the loss of one person isn't a big deal), there's really minimal cost to the company, but a potentially large upside.
- cyberpunk0 9y ago"Breaks"? Thats not how capitalism works, how would you squeeze every ounce of productivity from your human wage slaves before discarding them?
- jrs95 9y agoLeninism or Feudalism work just fine too ;)
- repsilat 9y agoHiring people is expensive. Training people is expensive. Retaining good employees is good business sense. Encouraging employees to look after themselves can reduce costs. Helping employees be fulfilled and letting them use their judgement about what to work on (within reason) can pay dividends. Many companies recognise this, and the success of those companies and their freedom to succeed in this way are strong arguments for the capitalist system. Maybe that's what you meant. It's clear you intended some irony in your post, but I'm afraid it seems more likely that it was meant to convey distrust and aggression, not something more constructive.
- pageald 9y ago>I’ll be on sabbatical from my job. . . and working on building better profiling tools for Ruby (and maybe Python??). I can't comment on Ruby's profiling stack, but I think that cProfile is a great tool for finding bottlenecks in Python. Usually, I've found that sorting functions by cumulative execution time is sufficient. You can't do flame graphs out-of-the-box, however.
- masklinn 9y ago> I can't comment on Ruby's profiling stack, but I think that cProfile is a great tool for finding bottlenecks in Python. Whereas I don't. Between the performance impact (code with and without cprofile can have very different… profile), the lack of stack information and yet the lack of precise, actionable code-level information makes it not really useful/convenient for non-trivial codebases. Feeding the trace files to more visual systems (e.g. gprof2dot or runsnakerun) doesn't help much either. These days I tend to use python-flamegraph (or pyflame but that's linux-only, though it has the advantage of using ptrace and can be attached to a running process at any point), this gives a mile-high view of the entire software in an extremely readable format, and from there it's possible to dive into specific hotspots with limited-scope profiles (whether with cprofile, with line_profiler[0] or with dedicated benchmarks). [0] which has cprofile's issue of impacting the software it observes except significantly worse)
- barrkel 9y agoGeneral rule I have: sampling profilers for CPU performance, instrumenting profilers for memory and other uses, like analyzing control flow.
- mooreds 9y agoI think sabbaticals are great. If you can, save up and do them yourself. Or, if you are switching jobs and have savings, ask for a month or two between the end date of your current job and the start date of the new job. It's a heck of a lot easier to spend money when you know you have a new job coming up. What to do? Something technical is great. Non tech stuff is good too (travel, learning new skills, family time, volunteering, etc). OT: HN folks, I posted this a few days ago, not sure if there was an issue with dup checking: https://news.ycombinator.com/item?id=15832094 https://news.ycombinator.com/item?id=15832094
- dang 9y agoOn HN a story doesn't count as a dupe unless it has had significant attention. Until then, a small number of reposts is ok: https://news.ycombinator.com/newsfaq.html https://news.ycombinator.com/newsfaq.html. This is one way we try to mitigate the randomness of what gets noticed.
- stanislavb 9y agoGood luck, mate. Looking forward to see some decent and helpful tools in the foreseeable future.
- kindfellow92 9y agoThis “Sabbatical” trend in software companies is really toxic. It’s a justification that allows companies to burn people out without looking bad. A sustainable interesting career doesn’t need a break. It’s a subtle admission that you’re overworked and your work is monotonous, which are both signs of a poorly managed company. Sabbaticals are reserved for tenured professors who have been working for a lifetime so they can achieve something non-academic. It should not become a euphemism for breaks that burnt out programmers who lack time management skills take so they can get their life together.
- deleted 9y ago[deleted]
- viraptor 9y ago> Sabbaticals are reserved for tenured professors Why do you think so? Sabbatical means a break. It's common for professors, but why prevent other people from taking it? I took a sabbatical from my uni to do some real work (and ended up moving unis, countries as a result), then took a sabbatical from work for personal reasons and did other things I wanted to do. If that prevents a burn out for someone, great! Not every company has enough projects going on to reshuffle you to the place you enjoy. (Or may not want to for valid reasons) Not every sabbatical is about burnout either.
- dvt 9y ago> Why do you think so? Because... that's what they actually are. A sabbatical was a very specific thing that was hijacked by HR people in tech companies. What you did was take a break; that has very different connotations than what a sabbatical is supposed to be.
- viraptor 9y agoThis may be a cultural thing, but I've always understood sabbatical as a long break - nothing explicitly related to academia. Multiple definitions I see on the internet seem to agree.
- viraptor 9y agoSadly, Ruby has a great profiling tool already built in: dtrace integration. It's the Linux side that's lagging in this case.
- Thaxll 9y agodtrace is too low level to be really useful, have a look at Go and Java for powerful tools.
- viraptor 9y agoIt does provide high-level (function, exception, etc.) probes as well: https://ruby-doc.org/core-2.3.3/doc/dtrace_probes_rdoc.html https://ruby-doc.org/core-2.3.3/doc/dtrace_probes_rdoc.html Then you can either use existing scripts of build on top of that. It's quite powerful. What do you think is missing?
- masklinn 9y agoCompilers & runtimes can provide high-level static probes for dtrace or systemtap. In fact CPtython 3.6 includes such probes: https://docs.python.org/3/howto/instrumentation.html https://docs.python.org/3/howto/instrumentation.html
- frik 9y ago> https://jvns.ca/blog/2016/06/12/a-weird-system-call-process-vm-readv/ https://jvns.ca/blog/2016/06/12/a-weird-system-call-process-... > does this tool, that can spit out Ruby stack traces quickly for any Ruby program with debugging symbols enabled, actually exist somewhere and I just don’t know about it? To your question in your other post you linked in your post: Maybe you mean APM, it stands for application performance monitoring. Search for "Ruby APM". Maybe the can inspire you for your tool. Good luck
- jvns 9y agoI'm working on surveying existing Ruby & Python profiling tools so that I understand what's been tried already. If anyone has tools/techniques I've missed, I'd love additions to this list: https://gist.github.com/jvns/b81eb039f6373bc577d7dbdd978581b5 https://gist.github.com/jvns/b81eb039f6373bc577d7dbdd978581b...
- deleted 9y ago[deleted]
- masklinn 9y agohttps://github.com/evanhempel/python-flamegraph https://github.com/evanhempel/python-flamegraph is similar to pyflame but does its sampling at the Python level, that makes it somewhat costlier & less precise but it's not restricted to Linux.
- eric-hu 9y agoGood luck Julia! Hope to see some blog posts of your findings along the way.
- BlackjackCF 9y agoOh man. I'm so excited about this. I love all of Julia's work. Would love to see the fruit of this sabbatical.