[PATCH] [CodeGen] prevent abort on invalid attributes

Saleem Abdulrasool compnerd at compnerd.org
Mon Aug 5 19:40:50 PDT 2013


Hi dblaikie,

Currently, when an invalid attribute is encountered on processing a .s file, clang will abort() due to an assertion.  Invalid user input should not cause an abnormal termination of the compiler.  This is a merely a first step at attempting to improve handling of malformed user input to clang.

http://llvm-reviews.chandlerc.com/D1293

Files:
  include/llvm/MC/MCELFStreamer.h
  include/llvm/MC/MCStreamer.h
  lib/MC/MCAsmStreamer.cpp
  lib/MC/MCELFStreamer.cpp
  lib/MC/MCMachOStreamer.cpp
  lib/MC/MCNullStreamer.cpp
  lib/MC/MCParser/AsmParser.cpp
  lib/MC/MCPureStreamer.cpp
  lib/MC/WinCOFFStreamer.cpp
  tools/lto/LTOModule.cpp
  test/CodeGen/2013-08-01-invalid-attributes.s
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D1293.1.patch
Type: text/x-patch
Size: 10530 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20130805/5a12be99/attachment.bin>


More information about the cfe-commits mailing list