Why you should not go to medical school - <AUTHOR> http://blogs.law.harvard.edu/abinazir/2005/05/23/why-you-should-not-go-to-medical-school-a-gleefully-biased-rant/ <comment><USER2> So, surprisingly, this rant is more or less accurate, imo. (I went to med school, residency, fellowship)

I mean some things stronger than others, but it hits on the major negatives as you go through training. I know a lot of these rants tend to romanticize how hard people's own professions are in a "no one else has it this hard" type stance. We see similar "how hard it is to be a programmer" type rants as well. But, I'll pull out the one aspect that I've always felt I lost.

"3) You will spend the best years of your life as a sleep-deprived, underpaid slave."

I do feel like I missed being young (20s) and just having a regular job, enjoying life with my friends. 4 years of medical school, and 3 years of residency pretty much wipe out age 22-29. So I do regret that.

<comment><USER3> I had a different experience. Medical school was easy, I was single and went out drinking / partying two or three nights a week. Not to be crass, but I did well with the ladies. Luckily I can get by on four hours of sleep or less. So, I don't feel like I missed out on much of the early twenties experience. Most of my non-medical friends had jobs and I didn't, but that was the only real difference.

Things got a little more serious my intern year, but I still managed to go out twice a week, and the nurses were much more responsive to my advances now that I was doctor.

At the start of my residency I got serious with a girl from my medical school. Her training was in Psychiatry and I was in Radiology. We worked a minimum of 80 hours a week, but we always had time for each other. We got married during third year.

Now I'm a partner in a successful practice, and she's taking a few years off to raise the kids. I make over 800k a year, and take 14 weeks of vacation. I don't deal with patients. I have the ultimate job security. And, I am a tremendous resource for my family. I'm sure you know how easy it is to get screwed by the medical system. That won't happen to me or mine.

I'm not a risk taker, so what else could I be doing with the security and benefits of my current job? Lawyer, maybe.

<comment><USER4> Thank you for your honesty.

May I ask, what exactly do you do that you feel justifies your 800k per year? It seems to me that your career is ripe for disruption.

<comment><USER5> Generally, rare goods - and skills - are valuable. So going to school for a long time to learn an unusual skill well means that your services are more valuable.

Also, providing a large amount of value in a small amount of time (like accurately interpreting the results of a scan) leads to providing huge amounts of value over the course of a year. Part of the explanation is the sheer volume of individuals he can give a reasonable amount of value to.

<comment><USER6> Wouldn't radiological and physician services, in general, be less "rare" if medical schools started to train more physicians (admit more students)? I have read studies that suggest that in certain markets and certain practice specialties we are and will face shortages of physicians in part because medical schools are training too few physicians. When I ask academic physicians they seem to think admitting more students would erode the quality of students. In other words, scarcity is a public good in this case as it helps to ensure that the "most talented" will ultimately become practitioners. I don't know how this view squares with the large number of foreign-trained residents in some residency programs.

<comment><USER7> The Planet Money podcast covered this topic once. In proper markets, increasing the supply of a good or service decreases its cost. However, in the US, the more doctors we train, the more we spend on healthcare.

A reason this is the case is because the average healthcare consumer is totally removed from the cost of healthcare and the doctor has a perverse incentive to make work for him or herself and other specialists.

</comment></comment></comment></comment></comment></comment><comment><USER8> The reason why it is so hard to become a doctor is because the AMA restricts the number of applicants and schools that can create doctors so wages can remain artificially high.

[http://www.forbes.com/2009/08/25/american-medical- associatio...](http://www.forbes.com/2009/08/25/american-medical-association- opinions-columnists-shikha-dalmia_print.html)

[http://gregmankiw.blogspot.com/2009/06/physicians-incomes- an...](http://gregmankiw.blogspot.com/2009/06/physicians-incomes-and- healthcare-costs.html)

<comment><USER9> That post should go straight to the top.

This is also why residents have to suffer ridiculous hours. With the severe limitations on the number of people who can become doctors, the profession is characterized by an extreme workload.

It's seriously wrong. I, for one, would not want to be operated on by a surgeon who'd been working for 21 hours straight. Commercial pilots are limited to 40 flight hours per month, and what they do is a lot less complex than what doctors have to do.

<comment><USER10> So, effectively pilots are only working 1/4th of the time that I work? Or is there non-flight-time work that eats up 120 more hours a month?

<comment><USER9> There's a fair amount of non-flight work. It'd say that it averages 120 hours of work time total per month. Less than we work, but with worse hours.

If you fly international with the majors, you're in good shape. Those guys make $200k easily, but those jobs are essentially inaccessible because the people who get them never retire. The rest make very little, and work a lot harder.

<comment><USER10> What sort of non-flight work do they do? I'm honestly curious, and I don't know any professional pilots. I imagine there's paperwork to fill out before and after every flight, and maybe mandatory training...

<comment><USER11> Walking around airports, going through customs, switching planes, waiting for matinee, paperwork, hotels, etc.

</comment></comment></comment></comment></comment></comment><comment><USER12> I'm married to a resident and this article is a very accurate portrayal of a resident's life. Her work schedule is insane. It's not just the amount of hours but the fact that these hours are packed and spent with difficult people and life or death situations. After a day of work she often mentions she didn't have time to eat or pee during the day. She has had some call shifts that lasted 40h strait (more than 3 days) where she got only 3 to 4 hours sleep breaks per night plus a few eating breaks here and there because it was busy the whole time. That meant no time for a shower in those three days, only superficial cleanups and quick change of scrubs when things got too bloody/amniotic.

<comment><USER13> I'm dating a resident.

Also, anyone thinking about medicine should realize how little autonomy they have. When my girlfriend explained how residency works, I was shocked: it sounded like a circumstance ripe for an anti-trust lawsuit. Turns out it was the subject of a lawsuit: [http://www.nytimes.com/2004/08/14/us/antitrust- lawsuit-over-...](http://www.nytimes.com/2004/08/14/us/antitrust-lawsuit-over- medical-residency-system-is-dismissed.html) , but one that Congress and President Bush granted an anti-trust exemption. So residents can't even negotiate outside the match. The legal barriers to medicine help explain why it's so miserable.

</comment></comment><comment><USER14> Great article and on point.

A former flatmate of mine committed suicide about 1.5 years after I left the flat, which I did due to his erratic and hostile behavior toward me, which I think was due to a number of factors, but mainly his stress from an intense hospital residency while he also did further study simultaneously.

There's an article mentioning him here: <http://vitualis.files.wordpress.com/2006/09/action_vow.pdf>

The danger zone for med students is when they sacrifice themselves and tolerate all the reasons that the Harvard article states why not to go to med school, because of the idealistic notion that:

"You have only ever envisioned yourself as a doctor and can only derive professional fulfillment in life by taking care of sick people."

As such, these smart and ambitious med students shoot for the moon, and due to the reasons in the article, realize that they won't make the moon (ie earn that fellowship, obtain that degree, receive that certification, get that promotion) and then they feel that their life is a failure, or won't have any further meaning the way they wanted it to, and then they kill themselves, because they have no exit strategy (or plan B) and are ill themselves.

There's nothing noble about the suicide of med students and interns, but I've seen how it happens right up close. I have further thoughts on the matter but that's the core of my experience regarding the negatives of this career path.

</comment><comment><USER15> There is not a doubt in my mind that this schedule ensures that they learn less and perform their jobs in much worse ways than compared to when they would be able to get more sleep and less stress. There's zounds of experiments that back me up on this.

As far people saying it's cheap labor: when residents make mistakes and the hospital gets sued, the labor suddenly isn't so cheap anymore. Again, there is not a doubt in my mind that this practice leads to a lot of damage and death, with the associated financial fallout.

That hospital management doesn't try to change this shows how blind they are to the consequences of entrenched practices. I wonder whether the health care market could be disrupted merely by creating hospitals that actually try to get their employees to perform optimally.

</comment><comment><USER16> I personally have been very happy with my decision to go into medicine (specifically, interventional radiology). I have a few comments about this discussion:

1\. The average radiologist gets paid about $40 (after expenses) to read a CT scan. So you have to read a LOT of scans to make as much as roentgen. Many scans contain hundreds of images, and the diagnosis can depend on just a few pixels. Partly based on the radiologist's diagnosis, the patient may need to go to surgery (at least $25,000) or need another round of chemotherapy ($50,000), etc. When viewed in this context, I think $40 is a great value for getting an expert opinion. (As a side note, there is a lot of regional variation in salaries. They are probably lowest in New York City. Contrast that to law or finance, where the highest salaries are probably in New York City. I think the difference is due to the fact that medicine (even radiology) is practiced locally, and thus depends on local supply and demand, and does not have the kind of network effects that you see in law or finance.)

2\. In terms of disruptive technologies in radiology, I don't think that computers will be able to replace radiologists any time soon, but there are lots of ways that computers could help radiologists be more productive or accurate. Much of the advances in consumer technology from the past decade are not yet available in radiology. Images are usually transferred to another hospital by mailing a CD. Reports are transferred using a fax machine. We're lucky if we can get 10 frames per second when scrolling through a large study. Computer systems are not linked -- ie, we have to type the patient's name into both the radiology system and the medical records system. For various reasons, many of these problems will have to be solved by big companies and not startups. But there are other opportunities for startups. If you're interested, check out my startup <http://www.revisionrads.com>.

</comment><comment><USER17> Some of the comments on that page are even better than the main article/rant:

 _"Last note, what bullshit is it that your plumber can charge whatever he wants to unclog your drain, but if I replace both knees the insurance companies automatically take 50% off the second. What am I, fucking Payless?"_

<comment><USER18> That's not a great analogy. The insurance companies have _negotiated_ a fixed rate with the hospital, and so if you work for the hospital, of course you must honor it. Same as if you were a plumber working for a large plumbing corporation, which had a contract with its clients. In that case, if you unclogged the drains at BigCorp, you would not be able to charge whatever you want, but only the rate BigCorp had negotiated with your employer.

</comment></comment><comment><USER19> So I owe HN a blog post. Here is something of a stopgap.

I am (still) a medical student at Johns Hopkins, and I love the place very much. I have for the past 6+ years.

After my third year, essentially on a whim (my sponsor, I think, knows this) I pursued a research fellowship in cardiovascular genetics. I loved it a lot, and stayed on a second year (spontaneously; thank you, Stanley and Lola J. Sarnoff).

After my fifth year in medical school, my second year of CV genetics up at MGH and the Broad Institute, I got the opportunity to pursue the startup dream for a year. I'm midway through and absolutely loving it.

But yet, I miss medicine. And I think that the grass is always greener, so I think I will miss whatever I'm not doing. Next year, in medical school for the first time in three years, I will miss research. Or I will miss the startup life. Something. I know it, because right now, I miss the hospital.

I miss working 80 hours a week while paying $50,000 a year for the privilege. I miss having a best answer (and if you think there are better answers in software than there are in medicine, please email me so I can hire you).

But I know that soon, I will miss the freedom of working at a startup. There is no right answer for everyone. And for many of us who were drawn to medicine, I think there can be no possible right answer, ever.

</comment><comment><USER20> Married to a final year surgery resident and unfortunately this article rings very true. I'm not sure if the profession changed at some point, but if we were advising my kid now on future professions, doctor would not be on that list. I remember the idealism that my wife went into the profession with and that is completely gone now. I find that very sad.

</comment><comment><USER21> Well said.

After four years of gearing up to go to medical school, I dropped that goal and went into software engineering. I wrote about this choice pretty extensively, as it was not an excruciating decision [0]. In spite of how much I really wanted med school, I also wanted a life. I tried to maintain a life while applying to med school, full of all the hobbies that make my life fun, but balancing those two wasn't actually possible. So I chose to reclaim my life.

Reading this piece is refreshing--I haven't seen enough people talk about the trade-offs of a physician. A lot of people in software think "I would have a meaningful life if I were in medicine"--and they probably have the smarts to be in medicine--but I think we should combat the idea that moving in that direction makes for a life that's any more fulfilling than engineering.

[0]: [http://wit.io/posts/pivot-my-journey-from-medicine-into- tech...](http://wit.io/posts/pivot-my-journey-from-medicine-into-technology)

</comment><comment><USER22> They should be treated as Flight controllors. My friend is one and ,it being a high-risk job like being a doctor, they have 8hr workdays with 2 hours of working and 2 hours of resting, and their salaries are sky-high. So sad all those smart,kind and hard-working people are being so used.

(plus, so glad I didn't end up in med school, I almost did :)

<comment><USER23> Do you know how they settled on the 2 hours on/2 hours off deal? I'm interested in alternative working hours to improve productivity and would be interested in knowing more about their schedules.

</comment></comment><comment><USER24> I started the med school track late in life (27 when I started taking premed classes), and while I haven't finished, I have to say that all of the complaining I hear from fellow students and doctors is ridiculous. All careers take up lots of your life. All careers end up dominating your social circles. All careers leave you feeling underpaid, including the people I know in finance who makes tons of money and work 12 hours a day 7 days a week minimum. Life is hard. I'm glad I took a lot of my 20's to experience that in other ways, so now that I've come to the medicine path, it really feels great. I agree that the decision to do this is not one that an 18 year old starting undergrad should make. But nonetheless, medicine is no worse than anything else.

<comment><USER25> Did you read the article?

<comment><USER24> No of course not I'm studying to be a doctor.

<comment><USER26> Kinda explains.

</comment></comment></comment></comment><comment><USER27> Was it always this bad? Was the process of becoming a doctor more sane in the past?

</comment><comment><USER28> What would be the picture of perfect 22-29 span? Being born with a silver spoon in a mouth? Partying every day?

I'm a CS grad student, married to med student. While our schedules are different, there isn't much difference in time. I'm mostly occupied with reading papers, grading papers, doing homework, grading homework and generally providing very cheap labor in a form of research assistantship and teaching assistantship to university.

To me, the experience of every point the author mentions is the sole reason for existence between 20-30 years of age.

</comment><comment><USER29> The most telling part of this article is point #8 (which basically says you will end up blaming and then eventually disliking the patients for your sad lot as a modern day doctor). What I find amusing here (and so comically characteristic of a Doctor's absurd notion of self-importance) is that the author so completely lacks the capacity for self-introspection that he doesn't even realize the truth of who is to blame.

To all the doctors out there that feel the same way as this author does I have one message for you. The only person to fucking blame is YOU!!!

Guess what? You're the one who made the decision to go into medicine and so you're the person at fault for the sad state of affairs in the modern medical profession. It's your fault for failing to do your due diligence on the demands and rewards of the profession. Why didn't you do your due diligence? You probably had some romantic notion of what it would be like as a Doc. Or possibly you went into medicine to make your parents happy? Or you thought it was a respected profession, or you simply wanted to help folks in need because it's an altruistic pursuit.

Well, sorry buddy, but all those things aren't an excuse for not doing your due diligence. It get's worse though...

At the macro level it's a self-reinforcing cycle. The lack of due diligence happens so frequently and by so many aspiring docs, it has repercussions on the profession as a whole. At the aggregate level, it causes wages to fall and working conditions to get worse for docs and interns (since the demand for medical school entrance remains strong regardless of conditions or wages).

You think just because you got good grades and got into med school that makes you smart? Ummm...no. And that is why Doctors get paid less than - and have more difficult working conditions than - Investment bankers. The type of person who goes into I-banking is smart enough and introspective enough to do their due diligence. The type of person who goes into medicine isn't.

</comment><comment><USER30> As a complete aside, the _Piecework_ article by Atul Gawande linked from the story has now been archived, and they broke the original URL.

Working version at <http://www.newyorker.com/archive/2005/04/04/050404fa_fact>

</comment><comment><USER31> wait, so, in the US a programmer earns double what a doctor earns?

<comment><USER32> No, not at all the average doctor's salary is more than twice the average programmers salary.

<comment><USER31> The article lists $45,000 per year for doctors. Programmer polls on HN showed that $100,000 is little.

What am I missing? :-)

<comment><USER33> $45/year for residents. At that point you're still basically an apprentice doctor.

<comment><USER31> Right. Turns out I completely misunderstood every sentence that contains "resident" in that article, then :-)

Thanks for pointing it all out. Does make his argument about the bad money bogus though. Nearly every other job is worse money than being a doctor (which is why he compared to investment bankers and the likes)

<comment><USER34> _Does make his argument about the bad money bogus though. Nearly every other job is worse money than being a doctor_

If you worked those other jobs for 80 hours a week, I think you'd start catching up pretty quickly ;-)

<comment><USER35> Yeah, but in medicine, by the time you're making the big money you're working much less. Or on whatever schedule you like.

At the age of 29: $45,000 for eighty hours a week.

At the age of 49: $600,000 for forty hours a week.

</comment></comment></comment></comment></comment></comment></comment><comment><USER36> I practice, but most of this article rings true for me as well, and I think most of my colleagues would consider me pretty idealistic.

Residency training is mostly cheap labor for hospitals. Working 36 hours straight every third or fourth night (common when I was a resident) saves teaching hospitals from hiring night floats or other coverage. Trying to make any kind of important decision for another human's medical care after you've been up for 24 hours is like trying to do so after several shots of alcohol. Such a schedule does not teach efficiently, endangers patients, and stresses the mental and physical health of physicians. There have been new work rules supposedly limiting residents to 80 hour work weeks, but they are routinely ignored.

Physicians spend most of their time trying to bring order to chaos. Regardless of a physician's specialty, I daresay each was shocked to learn how much time he/she spends basically just trying to simply coax new behaviors in patients - as such, performing at some level as psychiatrists (who I respect greatly - tough work). That's the challenge; everything else is pretty much plumbing. Either you find that work interesting (and it can be) or you soon get pretty burned out dealing with humans as they are, and they are obviously at their (usually temporary) worst much of the time when they need medical care.

My own colleagues are the best people I know - I still see the driving compassion there on a daily basis, and I think that's true for the great majority of docs. On the other hand, I've met a few physicians who would be happiest in concentration camps performing medical experiments on the inmates.

<comment><USER11> It's ironic that it doesn't have to be this way at all. It's counter productive other than it makes someone richer. Doctors want to keep their high prices with artificial barriers such as these and the glamor keeps the supply relatively high.

<comment><USER37> The long hours and over working is more a factor of a hospital trying to save money than having anything to do with supposed 'price controls' being purposefully set up by doctors. The price comes mostly as a factor of the extremely expensive education (both in cost and time) that is necessary. If you want talented people in any field, especially one with such a laboring path of entry, you have to pay them well.

<comment><USER11> If the kids had choices, they would not choose hospitals where shifts are 40 hours long and only sleep of 6 hours out of those 40 every thing else being equal. They don't, because of the power that the hospitals have over residents in granting their licence and the cultural ubiquity in practice.

Similarly, there are very limited spaces to enter medical school and it's extremely difficult to enter. How many new orthodontists are trained in a year? Under a 100? In a country of 300 million people? On top of that, medical school is very expensive. On top of that, you have to go to university for 3-4 years before you can even enter med school.

Imagine if engineering degrees were like that, because they could of been. Similarly with accounting or finance. Maybe they're not because the math heavy nature is enough of a barrier, even the simple math of accounting. American medical schools (and doctor associations) could choose to structure their curriculums to be similar to an engineering degree, admit high school students and make the education be 5-6 years long, teach in the summer, whatever. I'm fairly sure the UK does that, and I'm not sure if they haze their residents too with 40 hour shifts. They can also release the spigot, hire more teachers and teach more students to increase the supply of doctors. The increased supply of doctors will lead in a decrease of overall doctor wages and decrease health care costs. That along with an FDA drug approval process that doesn't cost 200 million and more clearly defined and easy to avoid malpractice rules (as in it's not easy to commit malpractice by mistake) would lead to huge systemic decreases in US health care costs alone.

Don't tell me it's about wanting the best, because treating people with sleep deprived residents is negligent. That is no where near the best care for any sort of patient. The best will just walk away once they know that they can make more money doing less work in i-banking, tech, petroleum, engineering, or business in far nicer environments, and they do by droves.

<comment><USER38> Medical degrees are first degrees in the UK:

[http://en.wikipedia.org/wiki/Medical_school_in_the_United_Ki...](http://en.wikipedia.org/wiki/Medical_school_in_the_United_Kingdom)

I believe traditionally junior doctors in the UK were also made to work extremely long hours - there have been efforts to change this recently.

</comment></comment></comment></comment></comment><comment><USER39> > You should become a doc because you always wanted to work for Medecins Sans > Frontières and your life will be half-lived without that.

Everything else was just whiny bullshit.

</comment><comment><USER40> We all hate people. It's because people have no common sense anymore. People don't respect the Earth anymore. It's all about greed... and greed is and has always been the seed of all Evil. Combine greed with a constant influx of media and interruption, you get zombies.

It's never going to change. We are left here on this lonely planet to our own devices - we were warned about greed, but greed has in fact taken over.

The 90's saw the most productive and the most lucrative period in the history of mankind. We take it for granted. The truth is - to live in the USA during the 90's was the pinnacle of human civilization and it will never be that way again. It was unsustainable.

We are in a death spiral, there will be casualties. Those that cannot adapt will be sacrificed. Gasoline has been replaced by the Internet and global marketing. Gasoline is obsolete.

Gasoline is obsolete. Because it's cheaper to hire foreign workers via the Internet than it is to make cubicles in the USA.

</comment><comment><USER41> One could say the same for any given field from sports to programming to business to pet-sitting. It's a hard knock life for us all. None of these reasons should have stopped any decent doctor from taking the path. The single reason would be: Don't go into medical school if you care more about money and an easy-going life than the actual field and people involved. And the same applies to every single field.

<comment><USER42> > One could say the same goes for any given field

Please name a sport, business, or other profession that involves staying up 40 hours straight unshowered, unfed, on a routine basis, for years, trying to not die or get anyone killed.

I can think of only two: medicine and the military. I do both. They're roughly equal. Given the choice between residency and deployment, I would need more information.

edit: Actually, I'm facing that choice now: do I apply for residency or orders which will probably involve going to Afghanistan. I'm leaning toward Afghanistan.

<comment><USER43> _"... Please name a sport, business, or other profession that involves staying up 40 hours straight unshowered, unfed, on a routine basis, for years, trying to not die or get anyone killed. ..."_

<http://en.wikipedia.org/wiki/Infantry>

<comment><USER44> So... the military, just as the commenter you replied to already noted?</comment></comment></comment></comment>


Identifying Autism from Neural Representations of Social Interactions - <AUTHOR> http://www.plosone.org/article/info%3Adoi%2F10.1371%2Fjournal.pone.0113879 <comment><USER3> There's a saying among those who become familiar with Autism.

"If you've met one kid with Autism, you've met one kid with Autism"

There are certainly clear cases... but the trouble is identifying the non- traditional and less severe cases. These methods are great, but with early intervention being so critical it's doesn't help with diagnosing younger children (from what I read... seems patient would need more cognitive ability).

As a parent who has recently run the gauntlet of diagnosis the most frustrating part of the lack of awareness for younger children. Based on all my reading early intervention can have a tremendous impact of future outcome (before 3y/o is really the sweet spot).

There's so much stigma on classifying young children early that parents are often reluctant to seek out diagnosis and treatment. My daughter was diagnosed at 15 months and has since made amazing strides.

If there was one thing I wish I could pass on to every parent it's that there is absolutely no harm or shame in doing diligence if you feel something isn't right. Therapies are play based and are great for even nuerotypical kids. If you suspect a delay or risk... talk to a specialist ASAP.

<comment><USER4> This is very good advice.

My wife is an Early Years Speech and Language therapist, so she is regularly exposed to children with autism.

Your daughter is lucky to have a proactive parent. Even when cases are identified within the system, by nursery staff for example, it seems to be more common than not that parents become very defensive about the idea of seeking further help. And actually, as a parent, I can understand it - <USER2> having seen first hand the difference professional help can make, especially in those early years, I would do everything in my power to get expert advice.

In the UK we have the NHS, and even though the waiting lists can be long (because these are the areas that tend to be the first to go during budget cuts), help is freely available. And it's not just autism we're talking about. There could be all manner of things that can contribute to a delay in those early years. There are people who can literally make the world of difference to the rest of child's future, and they really want to help.

<comment><USER5> Lacking comprehension of the problem and the causes, it seems reasonably carefull not to blindly admit your child into care based solely on the authoritive argument. Possibly, doctors cannot explain it propperly either and I'm under the impression that the causes aren't really known. Now, if the parent's lack of proficiency in childcare was responsible, that would be embareassing indeed, and if the percentage of autism

<comment><USER3> As my parents said when they saw the therapy my daughter was receiving (and took part actively): "I wish we had this type of training when raising our kids".

If we have another child and they are neurotypical... we'll raise them using the same techniques we've learned in supporting my daughter. I encourage any parent who wants to build a stronger bond and more thoughtful kid to read up on play therapies (floor time, speech therapy, OT, PT)... it's been some of the most rewarding and fun time I have had as a parent.

</comment></comment></comment></comment><comment><USER6> Sensitivity and specificity! That title is a bit misleading :)

I too could write a test that identifies autism 97% of the time:

return Random.Get(0, 100) < 97;

<comment><USER7> What they did is take a control group that's the same size of the autism group. Then they did what's called leave-one-out cross-validation (which is exactly what it says, train on the entire set leaving one out, then use that one for validation and do so all ways). The measure they chose (Accuracy) is not without its flaws, but it would not be susceptible to the one you mention.

For instance, if you took 100 negative and 100 positive and then ran your test, you'd expect an accuracy of something a little more than 50%.

<comment><USER8> Under this methodology, how meaningful would having more data points be with respect to statistical meaningfulness? The study only appears to use 17 people in each group (for a total of 34 people).

</comment></comment></comment><comment><USER9> I would be careful reading too much into one study. If you read their Methods section, you can see that they only picked adults with "high-functioning autism" which is so loosely defined as to be meaningless. Is it supposed to represent Vineland scores, or ADOS scores, or IQ, or "doesn't live in Mom's basement", or what?

But if you see that they also cut anyone from the study that has a family history of autism (even though autism is highly heritable), cut anyone with developmental delays (and almost all people with autism have or had delays in some realm, from speech to fine motor), cut anyone with anxiety disorder (extremely common in autistic people), then really you're left with probably a bunch of almost-entirely-guys with what used to be called Asperger's and is today (well, as of DSM-5) lumped back in with autism the broader category, for better or for worse.

Point being, be careful not to think this is a representative sample of a big, big category.

All that being said, I would love to see how these results stack up against another recent project based in San Francisco at UCSF that is doing fMRI scans of kids (not adults) with sensory processing disorder (SPD) but who do NOT have autism.

The project's lead, Dr. Elsya Marco at UCSF, is studying something similar: biological evidence of SPD and how it can be distinguished on scans from autism. The two disorders often go together, but she's trying to tease apart why some people are hypersensitive to sensory stimuli and yet DON'T have autism.

Study info: [http://www.ucsf.edu/news/2013/07/107316/breakthrough- study-r...](http://www.ucsf.edu/news/2013/07/107316/breakthrough-study- reveals-biological-basis-sensory-processing-disorders-kidsi)

And they're crowdfunding right now to raise money to do a bigger sample size for the fMRI scans: [https://crowdfund.ucsf.edu/project/53f230b014bdf718b0b2608d](https://crowdfund.ucsf.edu/project/53f230b014bdf718b0b2608d)

(Each brain scan they do costs $550.)

</comment><comment><USER10> As if autism is a "thing" that you "have". HIV is a thing that you can have. We check your blood and say "yup, you got HIV in there" or "nope, you're clean". Autism, like many terms, isn't a thing. It isn't even a state. It's a description of a state. But it's not a complete description of that state. It's really just a loose description of part of a state. Every case is different. Every autistic person is unique.

<comment><USER11> Autism is a catch all just like Cancer is a catch all. It works to get you into the ball park.

Yes you are 100% right BUT also 100% wrong (just semantics I don't know if we really disagree) there are subsets of Autism and Autism is a thing scientifically and medically. Just like depression is a thing that you can't get a specific test for doesn't mean it isn't a thing. Having adopted two boys with a very mild form of Autism called Aspergers, most doctors use to use the term High Functioning Autism. You can also have sever Autism, AKA low functioning Autism. When working with children or parenting I can specifically look at where they are. So while every person is unique you can be categorized as high functioning or low functioning autism and given many other sub- categories. The only reason why I say this is that many people dismiss early diagnosis and then their child doesn't get early intervention. The earlier the interventions start the better the outcomes.

Interesting note is Korea was saying they have almost no cases of Autism. Then the medical and scientific research conducted in Korea showed they had just as many children with Autism they just went undiagnosed medically.

<comment><USER10> I agree with all the things you've said.

Gonna throw a similar but slightly inverted anecdote out there as well. My sister is a PhD psychologist who works with children. She had to significantly reduce the number of children she forwards for ADHD testing because 100% of the time the result was "positive" and they were medicated. And she was sending in really borderline cases "just to be sure". Thinking she was being safe and responsible for the child's well being. Now she has to act as a blocker and only forward children who she is really, truly confident need it.

<comment><USER12> > ADHD testing because 100% of the time the result was "positive" and they > were medicated.

They actually have a qEEG test that does a very good job highlighting differences between the ADD brain and a neurotypical brain. This is at least 10 year old research, so i have no idea where it is today.

</comment></comment></comment></comment><comment><USER13> Is autism hard to diagnose? It seems that if anything the important thing about this study is the factors it discovered that allowed the populations to be separable.

<comment><USER14> The purpose of this study would seem to be more to validate the utility and/or robustness of fMRI than a novel diagnosis scheme for Autism.

<comment><USER15> I've not read the paper fully but it does look an interesting piece of work. I did notice that the controls were aged and IQ matched which doesn't suggest they we looking to differentially diagnose Autism from other disorders which is likely to be the more useful clinical technique. Also, the subjects were adult and I would expect most diagnosis to be performed in a much younger age group. This isn't the first attempt to apply fMRI techniques to the understanding of autism, plenty of prior work here ([http://goo.gl/oW41Vm](http://goo.gl/oW41Vm)).

Earlier in my career I did some fMRI and, whilst an interesting technique, I've never been convinced that it quite delivers on the claims. Firstly, you aren't looking at an electrical signal but rather changes in blood flow which are (reasonably) assumed to be coupled with areas of increased neural activity. This felt to me a bit like trying to debug a computer program by pointing a heat sensitive camera at your motherboard.

Also all fMRI experiments are characterised by a block design - periods of activation and inactivation - and the response is expected to correlate with these in some way. However, the brain is pretty busy and thus how does one select a baseline; what about the parts of the brain that just stay on?

<comment><USER16> >Earlier in my career I did some fMRI and, whilst an interesting technique, I've never been convinced that it quite delivers on the claims. Firstly, you aren't looking at an electrical signal but rather changes in blood flow which are (reasonably) assumed to be coupled with areas of increased neural activity. This felt to me a bit like trying to debug a computer program by pointing a heat sensitive camera at your motherboard.

It's pretty crude but it works. fMRI has been useful for a ton of things, it's even possible to read people's minds with it (from seeing what words they are thinking to an entire video reconstruction.)</comment></comment></comment></comment>


Ask HN: How do you usually deal with toxic co-workers? - <AUTHOR> - in the case where you have little or no choice to make them (or yourself) leave the job <comment><USER2> My answer is: Unsuccessfully.

A different, more useful question is: How should you deal with toxic co- workers?

It depends. Here's a guideline:

1\. If you can, talk with the coworker about what's making them toxic.

2\. If that doesn't work, or if you can't talk with them, then talk with HR or the lowest-level boss that you have in common.

3\. If that doesn't work, then do what you can to not work with that person.

Good luck.

</comment><comment><USER3> It would probably help if you spelled out what you mean by toxic in this circumstance. There are some grades of toxicity that go from mildly annoying to police involvement.

<comment><AUTHOR> i also agree, and apologize for not narrowing it down. the reason is probably that the circumstance overarch the various degrees this term may entail.

but it generally involves throwing blames for mistakes or delays, inconsiderate/provocative language, disorganisation and lack of focus ...

<comment><USER3> If you cannot leave (which is a lot harder than some folks believe), then documentation is basically your main answer. E-mail eventually hangs a lot of people. Sadly, a lot of this stuff is solved by the exit interviews with HR, but then its generally too late.

</comment></comment></comment><comment><USER4> Usually anyone referring to someone as 'toxic' is the one unwilling to meet halfway. Start bu realizing you are both terrified little humans, bridge the gap, and move on with life. No person is 'toxic', only or reactions to them.

Tldr; You can only fix you, so start on it.

</comment><comment><USER5> I leave. Any workplace that tolerates (and often even elevates) such people is beyond salvage.</comment>


GCubiks - the new 3D Glasses  - <AUTHOR> http://dev.emcelettronica.com/gcubiks-new-3d-glasses <comment><AUTHOR> GCubiks, the new 3D Glasses, was shown in Los Angeles during the "Special Interest Group on GRAPHics and Interactive Techniques" convention. A device is being developed that could allow people to see three-dimensional images, including moving and speaking people, as a method of communication in a palm- sized machine.</comment>


The Black-White Wage Gap Is as Big as It Was in 1950 - <AUTHOR> https://www.nytimes.com/2020/06/25/opinion/sunday/race-wage-gap.html <comment><USER2> Are the visualizations in the _Who's not Working?_ section... not working? I've tried requesting the desktop site and turning off content blockers to no avail, they're just empty graphs of axes and labels with no data.

And for anyone wondering whether they should read the article, it's a rare, pop look at a wage gap _that actually factors in non earners_!

</comment><comment><USER3> I wanted to post something snide about how you Americans might have concentrated more on the pay gap and less on relabelling dark skin once per decade. But I'm not sure whether that's correct, and not quite snide enough today to ignore the factual world.

Fighting denigrating wording might be a harmful diversion from substantive issues such as the pay gap. Or it might be a helpful symbol, and symbols do matter. Do real studies of this exist?

<comment><USER4> Pristina, Kosovo is closer to Oslo than Cedar Rapids, IA is to San Francisco. And so thinking about Norway in the way one has to think about the US would mean Norwegians taking national responsibility for the 1990's ethnic cleansing in the Balkans...and Berlin, yes, Berlin is closer to Oslo than Selma is to Cedar Rapids and so thinking about Norway in the way one needs to think about the US probably also means taking adult responsibility for the Holocaust. It was only 1200 km from Oslo to the gas chambers Auschwitz. And of course, Norway participated in and benefited from the trans-Atlantic slave trade. Because the trans-Atlantic slave trade was a European enterprise on a global scale.

If you want a study, study history and geography.</comment></comment>


A very easy way to send public Google+ posts to Twitter - <AUTHOR> http://manageflitter.com/plus

<comment><AUTHOR> We just released this. I've wanted it ever since I started using Plus, so hopefully some of you will find it useful too :)

I spent quite a bit of time getting the sharing correct - sharing Google+'s various data types is surprisingly hard to get right and make sure links go where you would expect them to.

Feedback welcome.

<comment><USER2> This is perfect. I was looking for something exactly like this. How are you reading the posts? How often?

<comment><AUTHOR> Thanks! We've got a fairly mature spidering architecture, so we're just using that to scrape the posts at scale. It's possible Google will block us, but we're pretty careful to rate limit and load balance across IPs. Plus, you know Google's business is built on scraping :) They don't seem to mind other apps that do it, so I figure we're moderately safe. Once there's an API, we'll use that.

We check every 5 mins if you post frequently, progressively slowing out at around once every 20 mins currently. If traffic builds up we'll slow it down to max at around 1 hour.

<comment><USER3> Nice job. Looking forward to the API-enabled version.

</comment></comment></comment></comment><comment><USER4> It tweets my past public posts too!!! That should be fixed else for people who share too much in public ( on google plus ) would flood their timeline when this app kicks in.

But great tool, API-enabled version should be awesome.

</comment><comment><USER5> Thank you :)</comment>


Ask HN: Becoming a Python Master. - <AUTHOR>

I want to get into Web Applications using Python and also Master Python. Has anyone used http://python.org/ to learn the language completely? and how hard is it? I have knowledge with Java and PHP can any recommend the Python documentation for learning Python?.<p>If you know a book that teaches Python fully and also Web development with the language that would be great thanks. <comment><USER2> I'm the co-founder of Real Python @ [http://www.realpython.com](http://www.realpython.com)

We teach Python programming and web development from the bottom up: Start with the syntax, move on the web fundamentals, then on into the frameworks - flask, web2py, and django.

Along the way, you'll build a number of applications, including a framework for building out your own MVP.

I can't guarantee you'll become a Python Master, but you will be well on your way. Good luck! There's a lot of great resources out there. Feel free to reach out to me if you have any questions - michael @ gmail.com

</comment><comment><USER3> Disclaimer: I am the creator of [http://www.learnpython.org](http://www.learnpython.org)

I suggest you start with [http://www.learnpython.org](http://www.learnpython.org)

I would also suggest looking at the Flask framework.

Good luck :)

<comment><USER4> awesome website. I also recommend [http://www.learnpython.org](http://www.learnpython.org)</comment></comment>


Ask HN: How did you find product-market fit? - <AUTHOR> <comment><USER2> Humbly listen to users. Courageously question your assumptions. Iterate as fast as possible.

</comment><comment><USER3> A lot of people just throw shit at the wall and see what sticks.

<comment><USER4> I was about to say this but in a more polite way :) And I say this as someone who built something with product market fit.</comment></comment>


Show HN: The best of your search results in one post - <AUTHOR> http://popsnip.com/topic/434/Coffee-Healthy-or-Not <comment><AUTHOR> Hi this is Matt, cofounder of popsnip, we have made popsnip so that you can put the best of your search results in one place for creating highly informative articles. Popsnip allows you to collect the best content you find in the form of text snippets and images and organize them into a wiki like UI.

Here is a quick intro on how to use it: [https://www.youtube.com/watch?v=6YhHWVMLpGU](https://www.youtube.com/watch?v=6YhHWVMLpGU) If you want to start using it, you will need to use the chrome, because it requires an extension.

Please let me know what you think. Any feedback is welcome.

</comment><comment><USER2> That select and clip UI is super nice.

The concept reminds me of Google Notebook ([https://en.wikipedia.org/wiki/Google_Notebook](https://en.wikipedia.org/wiki/Google_Notebook)).

<comment><AUTHOR> Yeah its a similar concept. We hope to make it more consumable and validate the content by others, so that people can see a popsnip post and trust the content instead of having to scour the internet to ensure they have the right answer.

<comment><USER2> The validation piece is really interesting. Is it possible to make a private popsnip?

<comment><AUTHOR> yeah, you click on the cog to right of the main title and select private.

</comment></comment></comment></comment><comment><USER3> Very cool. I always find myself wishing for something like this when I'm researching new startup ideas

</comment><comment><USER4> nice! this would be super helpful for sending around all my research and notes from different articles in one place instead of sending around a google doc

</comment><comment><USER5> Awesome research tool. Did you build chrome extension?

</comment><comment><USER6> very cool idea. best of both worlds of web clipping and a wiki!</comment>


Review our startup: Shoply.com - the easiest way to sell online - <AUTHOR>

http://shoply.com
Opening a shop and selling online is a monumental pain in the ass - it's complicated, time-consuming and expensive. We wanted to tear down these barriers and make opening a shop quick, free and easy.
We've developed simple shopping software which anyone can use to be up and running selling physical and digital products online in minutes. The software is completely decentralised and customisable so sellers can theme their shops as they please and have them on their own domains. The software is also socially integrated so you can push your shop to a tab on Facebook/easily leverage twitter to get the word out about it.
During the customer development stage it was made clear to us that apart from the tech side of things, driving traffic and generating sellers was an equally important problem which first time/small sellers had to deal with - to solve this we've networked all the shops together creating a centralised marketplace.
Buyers can quickly and easily search across all shops in our network. The marketplace helps buyers find products and helps sellers generate traffic.
To make buying from a shoply seller even easier we've networked buyers shopping carts together across all shops. Buyers can hop from shop to shop across different domains adding products as they go - when they're ready then can checkout in one quick transaction. All the sellers then get their share of the sale in real-time directly to their paypal account.
Our software is built using django and we've utilised Paypal's new Adaptive payment API to facilitate one-to-many real-time transactions.
For sellers we are software providers and traffic generators. For buyers we are a discovery engine and marketplace curator.
We're not looking to compete with the advanced self-hosted shopping cart companies. We are looking to help first time sellers, individuals and small businesses, get started. Think Tumblr for ecommerce. In terms of disruptive innovation we want to be a new market and low-end disruption.
Would love to know what you think.
If you have something to sell - why not open your own shop!
http://shoply.com <comment><USER2> Using the term "kick-ass service" once is probably too much, but you use it several times and it sounds very immature and unprofessional to me. Here are some other phrases I have a problem with:

"It's super simple"

"We look after you big-time don't we!"

"Servers are yucky"

"Things couldn't be easier!"

It all sounds very childish, but that's just the tip of the iceberg ...

Where do you address the issues of discounts based on time or quantity or shipping or percent of the price, local and state taxes, shipping, and all the other issues REAL online store owners have to deal with and decide upon?

On the one hand you keep repeating the mantra "Things couldn't be easier!" because apparently you want people to think you've taken care of all these issues, but then you're apparently leaving all the difficult issues in selling online -- but in reality you're leaving it all up to the sellers themselves -- which makes your platform anything but "simple".

Personally I would not want to sign up before learning how you handle these issues if I actually had something to sell, yet I cannot find any facts or substance to show me how (or if) you're going to do anything to help me with these issues.

Perhaps the most important issue is that you seem to be dictating the "rules" by which the shop owners must run their online stores ("In accordance with the Shop Owners Agreement you agree to ship all orders within 7 days of receipt") ... but if you stick your nose into your store owner's businesses too much the regulators and tax authorities are going to determine that YOU are the merchant -- not the suppliers that you're referring to as store owners. Then you'll not only be paying all the taxes that your suppliers are not paying, but you will also inherit liability for things you probably didn't want or expect.

I think you have a lot to re-think and reconsider before getting into this business the way you've described it here. I've been in eCommerce for nearly two decades and it disturbs me the way you're going about this, because I'm concerned about the legal and technical issues you don't seem to be addressing.

</comment><comment><USER3> "impressive, isn't it!", what? You haven't shown me anything, why would I be impressed? I'm not sold on why I would want to open a shop on shoply. What do your shops even offer, e.g. can I customize? You should add a quick tour or bullet point list of important features on the front page.

<comment><USER4> Ouch. Should definitely think more about "showing it" than "telling it".

</comment></comment><comment><USER5> My first reaction from just looking at the site for 30 seconds:

Make the 'Tour' page the home page, instead of the 'Register' page. Seeing that huge form first (without knowing what it does) makes me want to leave.

<comment><USER6> I didn't feel that way. I thought, "just a couple fields to fill out and I'm done!" - the creation of my store took just a few seconds and didn't require e-mail verification. It couldn't have been easier.

</comment></comment><comment><USER7> It's interesting. First thing I wanted to see was the tour, not the signup page. Tour has screenshots of stores.

<comment><AUTHOR> as a seller thats right - the tour page is a great landing page, but we also need to appeal to buyers so are caught in a place where the homepage needs to talk to 2 different markets at the same time

<comment><USER7> seems like other HNers are saying the same thing as me. You could try an A/B test, see if you get more signups if you show tour or signup first.

Or you could make the tour much shorter, 600px high, then have the signup form right below that.

</comment></comment></comment><comment><USER8> I agree with @mrbird - make the /tour page your landing page, and add a few bullets as well. Maybe even a comparison chart showing you vs Shopify?

</comment><comment><USER9> What's your advantage against shopify - <http://www.shopify.com/> ?

<comment><AUTHOR> much simpler to use and quicker to setup. free plans with no monthly fees, socially integrated (sell on facebook etc) and we help with traffic and sales through our marketplace and networked checkout.

Shopify is a great solution - but we want to help more casual/hobby sellers - and they find shopify a little complicated

</comment></comment><comment><USER10> Something I never understood about some online shops, the drop-down with only one option, usually "standard". What is "standard" doing there? What does this field mean?

Example: <http://alexstore.shoply.com/product/lava-lamp/>

</comment><comment><USER11> Looks awesome! Any plan on integrating plugins or add-ons? Would love to chat..</comment>


Sex-selective abortion: Gendercide in the Caucasus - <AUTHOR> http://www.economist.com/news/europe/21586617-son-preference-once-suppressed-reviving-alarmingly-gendercide-caucasus <comment><USER2> If people are aghast at this happening, just wait till when/if they can determine genetically whether or not a child might be gay. There are already people in the West who favor abortion for certain non life threatening birth defects, it won't be long before children will be screened for even possible other traits

</comment><comment><USER3> To my biased cultural sensitivities, this is some fucked-up bullshit.

But beyond that: it feels like this gender unbalance simply can't be stable in the long term. At some point, women become a scarce resource and thus more valuable.

Maybe there are some hints of that happening already. For example, this episode of Vice shows that dating in China has started to become more and more difficult for men. [http://hbo.vice.com/episode- four](http://hbo.vice.com/episode-four)

I can't imagine what these countries will look like if this gender disparity persists for 100 years or more.

<comment><AUTHOR> Ironically, the women who did not get aborted become more valuable over time.</comment></comment>


GCC null pointer check removed - <AUTHOR> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90949 <comment><USER2> Wow, I am in awe of Jeff Law at the moment :-). I am glad they found the issue and are fixing it.

I was helping a high school student learn how compilers work and we started by opening up GCC and I was astonished at just how mindbogglingly complex it had become. We closed that down and opened up the delightful Bellard "Tiny C"[1] which was comprehensible at the level where this student was working. We created a new 'bool' type for that compiler.

[1] [https://bellard.org/tcc/](https://bellard.org/tcc/)

<comment><USER3> >we started by opening up GCC and I was astonished at just how mindbogglingly complex it had become

It's the price of being good ;)

<comment><USER4> Well, and just being ancient. LLVM is good too, but a lot cleaner. For instance (from GCC's docs):

> Reload is the GCC equivalent of Satan. See [gccsource:reload.c], > [gccsource:reload1.c], and [gccsource:reload.h] if you have a brave soul.

[https://gcc.gnu.org/wiki/reload](https://gcc.gnu.org/wiki/reload)

<comment><USER3> AFAIK, gcc still circles around clang.

<comment><USER5> g++ drove me insane with its baroque error messages, but clang++ did not. However, I hear that g++ has improved.

<comment><USER6> I avoid C++ and stay in straight C as much as I can. GCC's C error messages have definitely improved in response to clang (especially around deep preprocessor stuff). I had assumed that the C++ messages had likewise improved, and thought that I had heard that as well.

Then I actually had to test that working on Envoy proxy. I was disappointed to get utterly incomprehensible error messages. I'm "GCC-by-default", so a coworker suggested I try switching to clang++... and sure enough, clang++ gave me decent error messages.

</comment></comment></comment></comment></comment></comment><comment><USER7> As the other commenters have pointed out, this is a bug in GCC and not an aggressive optimization typical of compilers exploiting undefined behavior. Perhaps the title can reflect this somehow? "Bug in GCC removes null pointer check", etc.?

<comment><USER8> > aggressive ["]optimization[" ...] exploiting undefined behavior

That's still a compiler bug.

But yes, this is a bug in GCC and the title should show that.

<comment><USER7> Exploiting undefined behavior is something compilers can and will do; that's not a bug. (Specifically, if a compiler can choose to omit code where it can prove that going down that branch would lead to undefined behavior. That's not what happened here.)

</comment></comment></comment><comment><USER9> I think I am already not alone in saying this on this thread, but that was a _very_ fast investigation and bug fix. I am impressed.

Not at all the expectation I would have for facing a compiler bug. I guess it also helps that the report seemed clear and high quality. (Even had a revision where it was introduced.)

<comment><USER10> "Silently incorrectly compiles code in a very bad way" is a fairly unusual bug, particularly for a well known platform (also a credit to gcc).

<comment><USER9> Yes, but humans have natural limits in time and attention. This is fast turnaround.

</comment></comment></comment><comment><USER11> This one is interesting... it looks like sibling call optimization was a bit too aggressive, or non-nullness is propagating incorrectly.

For those who understand UB, the problem is not that 'node' is NULL. The compiler can "prove" that 'node' is non-NULL, but the results are propagated to 'module' from main, which is not correct because 'main' is not the only call site of 'walk'.

<comment><USER12> But the proof that it's non null is the deref in main?

I'm not sure I understand why people say this has nothing to do with the UB already derefed therefore not null optimization. How else is the compiler inferring the pointer could be not null?

<comment><USER11> > But the proof that it's non null is the deref in main?

This is an incorrect interpretation, it only proves that 'node' is non-null. Recall that 'walk' is called twice—once for 'node', and once for 'node->child'. The compiler bug (and this IS a compiler bug, make no mistake) is that the the proof that 'node != NULL' is incorrectly treated as a proof that 'module != NULL', which is not sound, and the bug manifests as incorrect program behavior during the recursive call 'walk(module->child, ...)'.

<comment><USER12> Yeah. The bug is that the compiler propagated not null from main.node to walk.module.

But how did the compiler determine main.node is not null?

<comment><USER11> > But how did the compiler determine main.node is not null?

The test case in the bug happens to use UB to generate the constraint, but this is just an example of how to trigger the bug. The bug itself is not related to UB, and there are other ways to generate the same constraint.

Here is an example on godbolt showing what I mean: [https://godbolt.org/z/pRW97L](https://godbolt.org/z/pRW97L)

You'll notice that I removed the UB, but the bug is still there. You can see that the 'return;' statement is not emitted because it is colored with a white background. So the bug is not related to UB at all.

<comment><USER7> > You can see that the 'return;' statement is not emitted

Uh, what? The code looks correct to me:

      func:
        test rdi, rdi
        je .L7
        mov esi, 1
        jmp walk
      .L7:
        ret

There's a conditional branch on $rdi that jumps to .L7 (which returns) when node is NULL.

<comment><USER11> You're looking at 'func', the error is in 'walk'. Here is the top of 'walk':

      walk:
        push rbx
        mov rbx, rdi
        test esi, esi
        je .L3
        mov rdi, QWORD PTR [rdi]
        call walk

Note that esi = cleanup = 1 so the branch to .L3 is not taken, and the recursive call to 'walk' is taken. The crash will occur on the instruction before the call,

        mov rdi, QWORD PTR [rdi]

Because rdi = 0 on the second call to 'walk'.

<comment><USER7> Oh, yes, walk is still broken. I was focusing on func because you had added that and it coincidentally also had a white return statement.

</comment></comment></comment></comment></comment></comment></comment></comment><comment><USER13> Ouch, this is annoying. But it's a bug. Sometimes those happen, and they get fixed.

This is totally unlike the user hostility that results from playing gotcha with UB which has also resulted in removing null pointer checks. Those aren't bugs and don't get fixed.

<comment><USER8> Those _are_ bugs and the compiler developers' refusal to fix them is precisely the user hostility you are complaining about.

<comment><USER14> No they are not. When your program invoke UB, it is a bug in your program, and not in the compiler.

The compiler author are helping you with things like -fsanitize=undefined. Or even lets you define some behavior which is normaly undefined with things like -fwrapv, -fno-strict-aliasing, -fno-delete-null-pointer-checks

But you are asking the compiler to optimize your program, if you give an invalid program to optimize, you get an invalid result. There is no bug there.

</comment></comment></comment><comment><USER15> I couldn't reproduce with 9.1.0 on Arch Linux since it's patched: [https://git.archlinux.org/svntogit/packages.git/commit/trunk...](https://git.archlinux.org/svntogit/packages.git/commit/trunk/bz90949.patch?h=packages/gcc&id=7c2f84ac385521ffeb9ce7f34cc919031e717392)

However the gcc 9.1.0 in nix/nixos is still affected (but not the default gcc, which is still gcc7).

EDIT: nix just updated to gcc 9.2.0. I was using a slightly outdated release: [https://github.com/NixOS/nixpkgs/pull/66836](https://github.com/NixOS/nixpkgs/pull/66836)

<comment><USER7> If anyone wants to try this themselves: [https://godbolt.org/z/j4YJ0c](https://godbolt.org/z/j4YJ0c)

</comment></comment><comment><USER16> Reading that thread, I'm really impressed by the knowledge shown by the people that worked on it.

<comment><USER7> Compiler engineers are a smart bunch :)

<comment><USER17> I wish I am a compiler engineer...

<comment><USER18> Stop wishing, go building. It is hard but doable.

If you want an easy start re-implement an interpreted language first, then write a compiler for it.

</comment></comment></comment></comment><comment><USER4> Stuff like this is why I really like sel4's approach to verification. They take the compiler out of the TCB by parsing and verifying the underlying binary.

<comment><USER19> I believe NaCl and PNaCl analyzes machine instructions (NaCl) or 'bitcode' (PNaCl) to sandbox binaries.

<comment><USER4> They do but it's a little different. (P)NaCL still allows memory safety and data verification bugs that don't compromise the integrity of the sandbox. sel4 goes a lot further by verifying that the total behavior of the application matches the machine readable formal specification. So (P)NaCL probably would have allowed the bug in question to get into production, whereas it would have been caught as a build error by sel4.

</comment></comment></comment><comment><USER20> Scary, does this have a chance of introducing security issues in (mis)compiled code?

</comment><comment><USER21> Obligatory Dan Bernstein presentation: [https://cr.yp.to/talks/2015.04.16/slides- djb-20150416-a4.pdf](https://cr.yp.to/talks/2015.04.16/slides- djb-20150416-a4.pdf)

(note: portrait slides!)

<comment><USER22> > Wikipedia: "An optimizing compiler is a compiler that tries to minimize or > maximize some attributes of an executable computer program."

> So the algorithm designer (viewed as a machine) is an optimizing compiler?

> Nonsense. Compiler designers have narrower focus. Example: "A compiler will > not change an implementation of bubble sort to use mergesort." — Why not?

(No answer is given.)

An optimising compiler is _permitted_ to replace your bubble-sort by a merge- sort, provided apparent program-behaviour is unchanged.

The only reason real compilers aren't likely to do this, is that the transformation is too sophisticated/too specific, for current compiler technology.

> compiler designers take responsibility only for "machine-specific > optimization". Outside this bailiwick they freely blame algorithm designers

This is wrong.

It's wrong in the shallow sense: in a typical modern compiler, most optimisations are performed at the level of an IR, not at the level of the particular target machine language. Common subexpression elimination, for instance.

It's also wrong in a deeper sense: compilers may apply optimisations which improve time complexity. That is to say, they may transform the algorithm itself. The target machine has no bearing there.

Consider the following unoptimised loop:

        int found = 0;
        for (size_t i = 0; i != n; ++i) {
            if (arr[i]) {
              found = 1;
              // break;
            }
        }

An optimising compiler may be capable of essentially uncommenting the commented-out 'break'. This changes the time-complexity of the scan in an obvious way.

This optimisation could even be applied by a source-to-source optimiser, with no awareness of the the target machine.

(We can nitpick about possible tradeoffs regarding branch-prediction when adding the 'break', but I think my point is clear.)

</comment></comment><comment><USER23> I wonder if they'll get around to fixing this miscompliation bug: [https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90348](https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90348)

<comment><USER23> It isn't particularly helpful to downvote a comment to -3 without actually expressing what you found to be incorrect about it.

I linked to an issue where all current GCC versions emits incorrect memory corrupting output from a pretty boring correct input which has been sitting idle for almost 4 months. The issue-- a morally similar issue of applying a constraint to the wrong scope-- was found in production code, in the wild-- it's not like its some machine generated test case. Currently the finders are working around it with -fno-stack-reuse but it's unclear how much other software is impacted... Should I be lobbying Linux distros to recompile everything with -fno-stack-reuse ? ... hard to say: there isn't an easy way to instrument the compiler to detect when the bug is being triggered.

A rapid and highly knowledgeable response to miscompilation is what I've historically experienced from GCC and thats what's exhibited on the headline issue, but seemingly not in the case I linked to.

<comment><USER24> That's definitely an interesting issue - I don't think it's too similar to the one in the original post, though. It's not about applying a constraint to the wrong scope, it's a case where the liveness analysis has correctly deduced that a block-scope variable in a loop is not live from one iteration of the loop to the next but then the address of that block-scope variable has been incorrectly kept live across the loop iterations.

</comment></comment></comment><comment><USER25> There is a reason people are still staying with gcc-4.8. This pass in question (ssa-tree-copy) is just horrible, esp. in the latest versions. I had to blacklist gcc-9 because of similar issues with that. I didn't know that it did start with gcc-7 already.

</comment><comment><USER26> Again: There really needs to be a warning (elevate-able to an error like usual) for all removed / "optimized out" code. A programmer added it for a reason, and either that reason is invalid and it can be removed OR the compiler's doing something the programmer did not intend and is thus exhibiting undesired behavior.

<comment><USER14> This is not possible.

       void foo(int x) {
           if (x)  do_something();
           else do_something_else();
       }

       void fn1() { foo(0); }
       void fn2() { foo(1); }

When the code is inlined, the compiler can propagate constant and optimize the `if`. Do you really expect two warnings there?

These warning would happen all the time.

And anyway, this does not apply to this particular bug which is just a compiler bug (which has been fixed). The warning was there all along:

        This is free software; see the source for copying conditions.  There is NO
        warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.</comment></comment>


Google Cloud Shell – Free until end of 2016 - <AUTHOR> https://cloud.google.com/cloud-shell/docs/ <comment><USER2> [https://news.ycombinator.com/item?id=10327485](https://news.ycombinator.com/item?id=10327485)

</comment><comment><USER3> Google has been making so many cloud (platform) related announcements lately!

I love their service & it makes me happy to see them ramp up their efforts to provide an even better experience & product line.

<comment><USER4> Only to take it away after a couple years. I'm avoiding Google services for a while or indef.

<comment><USER5> Would you mind listing the Google Cloud Platform services that have been "taken away"? I'm honestly curious to know if the decision of shutting down services such as Reader impacts your perception towards Google's Cloud offerings.

Disclaimer: I work at Google.

<comment><USER6> Just because one hasn't been taken away yet doesn't mean it won't happen. Obviously Google has a bad track record regarding product lifetime and it's going to take some extra special care to win many people back.

</comment></comment></comment></comment><comment><USER7> I was just explaining to a colleague the best ways to get acces to shell utilities like awk/sed, as a Windows user. In the balance of ease of setup vs functionality I had recommended the git bash application. This looks even better (for 2016).

<comment><USER8> I'm a big fan of Babun; [http://babun.github.io/](http://babun.github.io/)

<comment><USER9> If all one wants out of Zsh are the smart tab completions then msys2 is lighter weight alternative. I have found babun a bit laggy.

</comment></comment></comment><comment><USER10> Can someone clear up two questions for those of us more familiar with EC2:

Does "temporary" instance imply volatility or limited uptime?

Web preview sounds like I might be able to run cron jobs or small web apps just for myself with SSL included. Does this seem plausible?

<comment><USER11> It says: "The virtual machine instance that backs your Cloud Shell session is not permanently allocated to a Cloud Shell session and terminates if the session is inactive for an hour. After the instance is terminated, any modifications that you made to it outside your $HOME are lost."

</comment></comment><comment><USER12> Where is that visual google graveyard to remind us about adopting google products...

[http://www.slate.com/articles/technology/map_of_the_week/201...](http://www.slate.com/articles/technology/map_of_the_week/2013/03/google_reader_joins_graveyard_of_dead_google_products.html)

[http://www.wordstream.com/articles/retired-google- projects](http://www.wordstream.com/articles/retired-google-projects)

[http://www.networkworld.com/article/2990958/software/google-...](http://www.networkworld.com/article/2990958/software/google- graveyard-what-google-has-killed-off-in-2015.html)

</comment><comment><AUTHOR> Does anyone known if the docker image for Cloud Shell is open source (or parts of it?)

<comment><USER13> I don't see docker mentioned. What makes you ask?

<comment><AUTHOR> Edit: Sorry for causing some confusion about if this is using docker or not. There is no reference to docker in the docs.

<comment><USER14> Would you be so nice to share the information you got?</comment></comment></comment></comment>


Django Security Releases Issued - <AUTHOR> http://www.djangoproject.com/weblog/2010/dec/22/security/

<comment><USER2> Thanks for posting this - fortunately, neither of these issues is serious enough that I feel the need to upgrade tonight vs. tomorrow. The first one doesn't affect me at all (you need to have given an untrusted user limited admin access to be affected) and the second one will eat server resources but won't compromise anything permanently. Phew.

</comment><comment><USER3> To take advantage of the admin issue prior this security release, a user would need to 1) have access to the admin 2) have limited admin privileges 3) be smart enough to manipulate the querystring in the URL.

I got a good chuckle out of this fix because I'm assuming that in practice 2) and 3) are mutually exclusive.

<comment><USER4> I agree that it's probably a minor issue. But consider that 2) could be hacked by someone that's not 3).

<comment><USER5> Why would you hack in and limit your own admin privileges?

<comment><USER6> If you can compromise someone's account -- someone who doesn't have superuser privileges -- you could then exploit the querystring trick to try to get access to additional information. And potentially compromise the account of someone who does have superuser privileges.

<comment><USER5> Ahh yes, I misunderstood what he was trying to say.

</comment></comment></comment></comment></comment><comment><USER7> And I just updated my older stable installs to 1.2.3. Garph!</comment>


Surging Countries - <AUTHOR> http://www.businessinsider.com/the-next-10-brics-2010-1?utm_source=feedburner&utm_medium=email&utm_campaign=Feed:+EtfdeskTopNewsAndInvestmentIdeas+(ETFDesk+Top+News+and+Investment+Ideas)

<comment><USER2> Man, every article on businessinsider lately has the maximal-linkbait title format,

        <number><adjective><actual-title> you must <verb>

When submitting articles of this type (if you must submit them at all), please whittle the title down to actual-title.

<comment><AUTHOR> I agree that most of that title is linkbait, but when you whittle it down to just "Surging Countries", I think it gets to be too vague and non-descriptive. Truth is that the article is speculative in nature, so shouldn't the title indicate that. How about "Countries to pay attention to this decade"? That at least provides an indication that it is speculative and provides a timeline for that outlook, and it spares the reader the "you must" and the <number>.

</comment></comment><comment><AUTHOR> After the six surging countries list there is "10 Looming Geopolitical Disasters" and then finally "12 Places To Go If The World Goes To Hell". Fun reading!!</comment>


Ask HN: Your predictions for 2012? - <AUTHOR>

This year we saw interesting things in technology and considerable improvement in the Web related tech.<p>What are your predictions for 2012? Not limited only to the startup world, but any prediction worth mentioning. <comment><USER2> * More solar energy startups go bankrupt or shutdown: [http://blogs.telegraph.co.uk/news/jamesdelingpole/100125720/...](http://blogs.telegraph.co.uk/news/jamesdelingpole/100125720/more-bad-news-for-the-anti-energy-green-greed-brigade/)

* Bubble in American farmland continues growing: <http://blog.mises.org/19970/farmland-is-bubbleland/>

* More civil unrest in China as economic landing is closer to a crash: [http://www.google.com/hostednews/afp/article/ALeqM5iWObIptHU...](http://www.google.com/hostednews/afp/article/ALeqM5iWObIptHU6RYQSwGSY49xn9IA_xg?docId=CNG.9fba8c14e4ed9e891c8b1c23225a7daf.921)

* Ancestral/Paleo/Primal Lifestyle more popular, but still not mainstream.

* Gold at $2,500/oz.

* New season of Doctor Who is repetitive, derivative, but still just as popular and exciting.

* csomar builds a website to keep track of predictions, but his homepage will still say, "coming soon".

<comment><USER3> * _Gold at $2,500/oz._

Are you taking bets on this one?

</comment></comment><comment><USER4> Oakland's continuing trend as an up-and-coming alternative to the SF start-up scene will gain some recognition and tractable returns, exponentially fueling its viability.

Start-ups ending in .ly will reach critical mass and those further hoping to capitalize on this will be viewed as "old-hat" (if even only in name/branding). This will be revisited in late 2012 by a smashing.ly successful start-up that uses it for "ironic" purposes (if even only in name/branding).

Some sort of hybrid between Bitcoin and MMORPG will emerge. If you think people are jumping ship on Bitcoin in droves and that it will soon be "dead", consider that people still play Project Entropia (and even _begin playing_ as new players) to this day, and then consider why.

20 to 30 new programming languages will be released, giving birth to the meta- polyglot, or a language whose purpose is to form a polyglot translation bridge.

Hundreds of articles will be written with titles like "n ways to foo your bars in 2012".

Thousands like me will make public their predictions for 2012 based on the biases and misinformation that have been brewing in their vacuous heads for more than just the past year.

</comment><comment><USER5> <http://predictionbook.com/> is handy for keeping track of predictions, and getting feedback about your overconfidence/underconfidence. (It generates a graph of your your confidence vs. accuracy - '90% sure' should happen 90% of the time.) Outside of specialist sites, you generally see no confidence values attached to predictions, and vagueness that makes judging them difficult or impossible.

Of possible interest:

<http://lesswrong.com/lw/7z9/1001_predictionbook_nights/>

[http://lesswrong.com/r/discussion/lw/8dx/predictionbook_a_sh...](http://lesswrong.com/r/discussion/lw/8dx/predictionbook_a_short_note/)

<comment><USER6> Don't forget InTrade.

<http://www.intrade.com/v4/home/>

<comment><USER7> You have to get money into Intrade, the fees are bad for small sums like a hundred bucks or so, you can't do long-term predictions profitably (foregone interest/investment return eats you alive), and you can only bet on the preselected set of markets - assuming they're even liquid enough to bet on.

So for predictions like we're discussing here, PredictionBook is _way_ better. (Sometimes using real-money doesn't make things better.)

</comment></comment></comment><comment><USER8> The world won't end on Dec. 21, 2012.

<comment><USER9> Only the beginning of the end of Closed Institutions.

For the last 5000 years the closed institution has ruled humanity. 12.12.12 that will change. And a new collaborative framework will marginalize the 1% and their money.

It all started with the the closed family of the strongest tribal leader... future generations became chiefs by enslaving and killing rivals. Fearful of others killing them they sought mystics to aid them and in turn these anointed them into Kings with divine right of rule; and the "closed" religion casts were born. And these leaders become great and powerful tyrants. Innovation brought about a new class "the merchants" and these eventually usurped the tyrants in great rebellions Magna Carta and the French Revolution and over time more innovation made these expand into global territories and giving them eventually more power and control than the leaders. Such power in fact they decided and controlled all matters -- spinning everything out of control: Climate, Fishery's, Forests, etc... Until that day that the bearer of the gift arrived and that gift was the Open !ncubator Framework (O!F) makes a good story :) <http://mtrout.com>

</comment></comment><comment><USER10> * iPhone 5 will add NFC, which will have advertisers foaming at the mouth as Apple will link to ATV

* RIMM will be brought by a network operator for their operator friendly tech

* Existing iOS and Android publishers will be looking to other markets to get a ROI on their current outlay

* Stephen Elop will jump ship from Nokia

* Nintendo will release something on one of the existing mobile platform (probably more hoping, they should just do a high priced accessory game combo branded for Zelda/Mario for iOS)

* HTML 5 will provide "cross platform apps"

</comment><comment><USER11> Groupon will trade less than 25% of its current share price and may restructure / fold

<comment><USER7> <http://predictionbook.com/predictions/5004>

</comment></comment><comment><USER12> * No economy bubble burst in europe

* G+ doesn't go anywhere, but doesn't shut down just yet

* More failed IPOs will make mass media call it "a different 2k bubble"

* Incubator/accelerator bubble burst (specially outside USA)

* Facebook phone

* Facebook credits for physical stuff will face-off with Paypal

* Obvious Facebook IPO

* Groupon files for bankruptcy

* Nintendo declares yet another year of losses, doesn't die (yet)

* The year of Linux on the Desktop (just kidding)

</comment><comment><USER13> 1) RIM will be bought.

2) Google will fold ChromeOS and roll up everything into variations of Android.

<comment><USER14> On the other side of the trade ... some RIM related commentary on seeking alpha by one of the people I pay attention to, Rocco Pendola: "don't expect anybody, particularly Amazon, to buy RIM anytime soon.". [http://seekingalpha.com/article/315331-amazon-making- blackbe...](http://seekingalpha.com/article/315331-amazon-making-blackberry- cool-again)

</comment></comment><comment><USER14> Our latest project will give you lots of financial predictions, many for 2012 (though you can't filter by that explicitly yet): <http://backrecord.com> Early days, but if you're into this sort of thing worth checking out..

</comment><comment><USER15> \- The year of the startup.

\- Massive government policy changes.

\- Revolution in conscious dream and mind (self) control.

\- Apple TV sucks.

\- Facebook gets lucky.

And of course...

\- My startup is the most viral web app of the year!

</comment><comment><USER16> Native Client (NaCL) will power the next wave of social games.

Adobe Creative Suite will support an NaCL target and Flash will be superceded whilst Adobe get a new boost of adoption on the tools front

<comment><USER17> I hope NaCl doesn't gain any traction. It really is a step backwards.

</comment></comment><comment><USER18> Facebook continues work on their own fork of Android towards releasing a phone and Facebook mobile app platform. Perhaps an IPO to coincide with it.

</comment><comment><USER19> 10x-100x growth in enrollment into online classes from top universities (like Stanford classes)

Non-TED lecture to get 5M views on Youtube

</comment><comment><USER20> Android will gain more market and still struggles to make more money than iOS.

I'll start my startup and still continue reading HN :D

</comment><comment><USER21> Steak-in-a-can!

</comment><comment><USER22> The year of the linux desktop

</comment><comment><USER23> iPhone 5 I guess. New MacBooks.

</comment><comment><USER9> I am a disgruntled entrepreneur who for nearly 2 years have been developing an enterprise 2.0 solution for the "closed" startup. I predict this will be the year of the Open Startup and it's foundup®. We running a closed alpha development trial and launching public beta on 12.12.12. What's so great about the open startup? It doesn't need the 1% to succeed and they launch as Open Corp and new selfless framework in which 20-80% of net profits are invested into lannching more open corps. My prediction is this...

1) Closed incubators such as this one and other clones will be displaced by a highly scaleable open free solution that offers a solution where 1% are not needed. 2) Closed crowdfunding funding platforms like profounder, KS, IGG, etc will be disrupted by our free version that offers TWO new ways to raise funds, 1) has raised over $1.6bn for npo strategic initiatives and another is my creation that I call passive crowdfunding. 3) Developers will be marginalized to becoming construction workers. As I have invented a new way to validate ideas.

There is a lot more but I will leave some things to be suprises :) Here are my talks... <http://j.mp/OSiplaylist>. If you want to see the solution that lies outside your paradigm to fully comprehend and you are willing to sign an NDA then I would be happy to show you it. After all I don't want this BS happening to us <http://j.mp/modista>. Open Startups is really Stupid simple... it combines 10 years of me beta testing experience, throws in fundraising lessons learned and 2 years of picking apart the Valley Startup. Just as Wikipedia disrupted MS Encarta. The Open Startup will change the world. I am here telling you but it should so absurd none of you will take heed... that OK. FOUNDUPS® Vision statement is "Be Good." because let's face it "Don't Be Evil" just doesn't cut it any more. We are a blue ocean strategy just letting now the red ocean we are here and would LOVE you to own some of use to hedge against our disrupting your business model. Jimmy Wales never did that... I think that was wrong. Paul, there you have my prediction... Love to show you our Open Startup !ncubator (OS!)

FOUNDUPS® Michael Trout, CEO Sorry for the edits, like Shakespeare I am highly dislexic</comment>


Bike lanes need physical protection from car traffic, study shows - <AUTHOR> https://arstechnica.com/cars/2019/05/bike-lanes-need-physical-protection-from-car-traffic-study-shows/ <comment><USER2> People near me always use the bike lane as an extra lane to drive, turn, pass or park. I doubt I would risk using it myself, and I often see people just riding on the sidewalk instead.

</comment><comment><USER3> That was pretty obvious to me. When I studied in Sevilla, Spain, there were bike lanes everywhere, but they are segregated from traffic, at the sidewalk level. I felt quite safe, I can't say the same for London for example.

</comment><comment><USER4> This would also make electric personal transportation like e-scooters and e-bikes a lot more usable. I would love to see Bird and Lime scooters have a place to ride aside from sidewalks with formalized traffic control devices.</comment>


Bees Added to U.S. Endangered Species List for First Time - <AUTHOR> http://www.npr.org/sections/thetwo-way/2016/10/03/496402620/bee-species-added-to-u-s-endangered-species-list-for-1st-time <comment><AUTHOR> As a software engineer watching bees is pretty fascinating. FWIW right now I am studying to have my own meloponine [1] hive at the backyard, to help with local pollination. I believe there are some decent softwares for bee hives and apiaries management out there so we can help a bit regarding their endangered status, hopefully.

[1] [https://en.wikipedia.org/wiki/Stingless_bee](https://en.wikipedia.org/wiki/Stingless_bee)</comment>