summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/SelectionDAG
diff options
context:
space:
mode:
authorKevin Enderby <enderby@apple.com>2013-03-12 18:12:17 +0000
committerKevin Enderby <enderby@apple.com>2013-03-12 18:12:17 +0000
commitf536c6af39e59acc68cda882cc97507b1face283 (patch)
tree87d8c0b89042cdf5f5615eec5cbaacd6dedd72ee /llvm/lib/CodeGen/SelectionDAG
parent787d1623b0e349b0bafc9048017a5b2c2cde3e59 (diff)
downloadbcm5719-llvm-f536c6af39e59acc68cda882cc97507b1face283.tar.gz
bcm5719-llvm-f536c6af39e59acc68cda882cc97507b1face283.zip
Remove the assert()'s from the LLVMCreateDisasmCPU() library API and just
return 0 to indicate failure to create the disassembler. A library routine should not assert and just let the caller handler the error. For example darwin's otool(1) will simply print an error if it ends up using a library that is not configured for a target it wants: % otool -tv ViewController.o ViewController.o: (__TEXT,__text) section can't create arm llvm disassembler This is much better than an abort which appears as a crash to the user or even the assert when using a Debug+Asserts built library: Assertion failed: (MAI && "Unable to create target asm info!"), function LLVMCreateDisasmCPU, file /Volumes/SandBox/llvm/lib/MC/MCDisassembler/Disassembler.cpp, line 47. radr://12539918 llvm-svn: 176880
Diffstat (limited to 'llvm/lib/CodeGen/SelectionDAG')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud