"David Nadlinger" wrote in message news:[email protected]...

By the way, this (just emitting an x86 idiv even if it the operands are known to trap) will likely be a pain to implement for LDC. There has been an (overly aggressive, on the side of two LLVM devs) discussion about this a year ago or so: http://lists.cs.uiuc.edu/pipermail/llvmdev/2013-April/060930.html.

Personally, I find their stance highly troublesome, as they have introduced undefined behavior that is hard to circumvent for practically no potential performance gain. I just hope we can somehow avoid emitting a branch on every integer division…

That's annoying, but I guess it makes sense given how much division varies across platforms.

Reply via email to