Issue 223 in address-sanitizer: No debug information on MacOS with gcc 4.8.1

148 views
Skip to first unread message

address-...@googlecode.com

unread,
Sep 17, 2013, 11:15:33 AM9/17/13
to address-...@googlegroups.com
Status: New
Owner: ----
Labels: Type-Defect Priority-Medium

New issue 223 by Lykov.Ki...@gmail.com: No debug information on MacOS with
gcc 4.8.1
http://code.google.com/p/address-sanitizer/issues/detail?id=223

I'm using MacOS 10.7.5 and gcc 4.8.1, I compiled application with debug
information and no optimizations: -O0 -g3 -fsanitize=address
-fno-omit-frame-pointer. When running application I receive a correct error
message (see output.txt) but without any debug information. It is probably
because on mac debug information is stored separately, thus in case of
valgrind one need to use dsymutil:
dsymutil <executable>
valgrind --dsymutil=yes
I could not find a similar option for AddressSanitizer.


Attachments:
checkNoDInfo.cpp 181 bytes
Makefile 567 bytes
output.txt 2.1 KB

--
You received this message because this project is configured to send all
issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings

address-...@googlecode.com

unread,
Sep 17, 2013, 11:17:13 AM9/17/13
to address-...@googlegroups.com

Comment #1 on issue 223 by gli...@chromium.org: No debug information on
Have you tried the asan_symbolize.py script or the ASAN_OPTIONS=symbolize=1
env var?

address-...@googlecode.com

unread,
Sep 18, 2013, 5:10:44 AM9/18/13
to address-...@googlegroups.com

Comment #2 on issue 223 by samso...@google.com: No debug information on
ASAN_OPTIONS=symbolize=1 is the default. It just wouldn't work w/o external
symbolizer, and there is none in gcc. So, I think the only option for now
is to use asan_symbolize.py script.

address-...@googlecode.com

unread,
Oct 3, 2013, 8:23:56 AM10/3/13
to address-...@googlegroups.com
Updates:
Status: WontFix

Comment #3 on issue 223 by konstant...@gmail.com: No debug information on
Please reopen if #2 doesn't help.
Also please note, that gcc-asan on Mac is not something we actively support.
(gcc-asan on Linux is, and clang-asan on Mac&Linux even much so)

address-...@googlecode.com

unread,
Oct 31, 2013, 12:01:51 PM10/31/13
to address-...@googlegroups.com

Comment #4 on issue 223 by dpi...@gmail.com: No debug information on MacOS
On my gcc 4.8 or 4.9 on linux I cannot find asan_symbolize.py.
However, if and only if I set "ASAN_OPTIONS=symbolize=1" and "export
ASAN_SYMBOLIZER_PATH=/usr/bin/llvm-symbolizer-3.4", then I get the
symbolized report.

If I do "mybin 2>&1 | /usr/bin/asan_symbolize --demangle" (which is also
from clang3.4), I can see the symbols, but without colours and missing some
info

address-...@googlecode.com

unread,
Oct 31, 2013, 12:09:15 PM10/31/13
to address-...@googlegroups.com

Comment #5 on issue 223 by ramosia...@gmail.com: No debug information
> but without colours
asan_symbolize.py doesn't preserve the colors printed by ASan.
Running "mybin 2>&1 | cat" will have the same effect.

> and missing some info
Perhaps it's using addr2line instead of llvm-symbolizer, try to set
LLVM_SYMBOLIZER_PATH.

address-...@googlecode.com

unread,
Oct 31, 2013, 12:13:19 PM10/31/13
to address-...@googlegroups.com

Comment #6 on issue 223 by ramosia...@gmail.com: No debug information
I made asan_symbolize.py accept ASAN_SYMBOLIZER_PATH as well as
LLVM_SYMBOLIZER_PATH in r193758.
Reply all
Reply to author
Forward
0 new messages