[LLVMdev] LLVM Language Reference Strictness
clattner at apple.com
Fri Oct 21 15:04:13 PDT 2011
On Oct 21, 2011, at 1:14 PM, reed kotler wrote:
> On 10/21/2011 09:28 AM, Owen Anderson wrote:
>> On Oct 20, 2011, at 9:47 AM, Reed Kotler wrote:
>>> I would like to see the many adhoc parsers in LLVM get replaced by ones
>>> generated from grammars.
>> FYI, this is very unlikely to happen. The parsers in LLVM were historically generated from grammars (bison, as I recall), and those implementations were removed in favor of hand-written implementations both because the latter were significantly easier to maintain, and because they were much better suited to offer reasonable diagnostics. Any plan to reverse that decisions is likely to meet a lot of resistance.
> Right now it's pretty easy to crash tablegen if you have table errors, for example. That is not exactly giving reasonable diagnostics.
Reed, as I'm sure you know and can appreciate… the cause of most of these problems is not the parser itself, it's the semantic analysis and other actions that are fired by the parser. I don't see how a machine generated parser helps solve the important problems here.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the llvm-dev