[MC] Requiring MCAsmInfo for MCExpr evaluation?

Ahmed Bougacha ahmed.bougacha at gmail.com
Mon Apr 27 16:58:22 PDT 2015


On Fri, Apr 24, 2015 at 11:01 AM, Jim Grosbach <grosbach at apple.com> wrote:
> SGTM.
>
> If we change this universally (x86 and ARM, too), do you have any thoughts on whether this would actually break anything?

Given this affects constant expressions in assembly (something clang
shouldn't generate), probably not, but I've been surprised before ;)
For starters, there's a test for precisely this in
test/MC/AsmParser/expr.s, though that's not saying much regarding
real-world code.

> And more importantly, anything that we couldn’t straightforwardly fix?

Fixing should be easy (mechanical, even).  I'm a bit more worried
about finding out this is the issue, but that shouldn't be too hard
either.  We can even emit a temporary warning when this would make a
difference, but that's probably overkill.

> I’d really prefer to just make this an across the board fix if possible.

Fair enough;  let's try to flip the switch on Darwin as a final step.

-Ahmed

> -Jim




More information about the llvm-commits mailing list