This is an archive of the discontinued LLVM Phabricator instance.

[aarch64][mc] Don't lookup symbols when there is no symbol lookup callback
ClosedPublic

Authored by dsanders on Aug 20 2018, 3:22 PM.

Details

Summary

When run under llvm-mc-disassemble-fuzzer, there is no symbol lookup callback so tryAddingSymbolicOperand() must fail gracefully instead of crashing

Diff Detail

Repository
rL LLVM

Event Timeline

dsanders created this revision.Aug 20 2018, 3:22 PM

This seems like an obvious fix but I don't know whether it was deliberately or accidentally mandatory.

@aemerson: Are you aware of any reasons it was mandatory?

aemerson accepted this revision.Aug 21 2018, 8:05 AM
aemerson added a subscriber: lhames.

Looks like Lang added the original code, but LGTM anyway. I even think we did this exact change downstream a few years ago at ARM...

This revision is now accepted and ready to land.Aug 21 2018, 8:05 AM
This revision was automatically updated to reflect the committed changes.