1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-21 03:53:04 +02:00

Update the AArch64ExternalSymbolizer to print literal strings as escaped strings

so it is the same as the MCExternalSymbolizer.

rdar://17349181

llvm-svn: 272588
This commit is contained in:
Kevin Enderby 2016-06-13 21:08:57 +00:00
parent 112fd20f70
commit 6b0a8a8cbd
2 changed files with 6 additions and 5 deletions

View File

@ -134,9 +134,11 @@ bool AArch64ExternalSymbolizer::tryAddingSymbolicOperand(
if (ReferenceType == LLVMDisassembler_ReferenceType_Out_LitPool_SymAddr)
CommentStream << "literal pool symbol address: " << ReferenceName;
else if (ReferenceType ==
LLVMDisassembler_ReferenceType_Out_LitPool_CstrAddr)
CommentStream << "literal pool for: \"" << ReferenceName << "\"";
else if (ReferenceType ==
LLVMDisassembler_ReferenceType_Out_LitPool_CstrAddr) {
CommentStream << "literal pool for: \"";
CommentStream.write_escaped(ReferenceName);
CommentStream << "\"";
} else if (ReferenceType ==
LLVMDisassembler_ReferenceType_Out_Objc_CFString_Ref)
CommentStream << "Objc cfstring ref: @\"" << ReferenceName << "\"";
else if (ReferenceType ==

View File

@ -7,8 +7,7 @@ OBJ: 000000000000001c adrp x0, L_.str@PAGE
OBJ: 0000000000000020 add x0, x0, L_.str@PAGEOFF
OBJ: 0000000000000024 bl _printf
EXE: 0000000100007f58 add x0, x0, #0xfa8 ; literal pool for: "Hello world
"
EXE: 0000000100007f58 add x0, x0, #0xfa8 ; literal pool for: "Hello world\n"
EXE: 0000000100007f5c bl 0x100007f78 ; symbol stub for: _printf
ObjC-OBJ: 000000000000000c adrp x8, L_OBJC_SELECTOR_REFERENCES_3@PAGE