[PATCH] D15644: [asan] Use private aliases for global variables (compiler-rt part).
Yury Gribov via llvm-commits
llvm-commits at lists.llvm.org
Fri Dec 18 11:55:38 PST 2015
ygribov added inline comments.
================
Comment at: test/asan/TestCases/Linux/local_alias.cc:15
@@ +14,3 @@
+long foo(long *);
+long h = 12;
+long i = 13;
----------------
kcc wrote:
> m.ostapenko wrote:
> > kcc wrote:
> > > isn't this a real ODR which we now will fail to detect?
> > Yes, we can't detect ODR violation here, because libfoo.so is sanitized and libbar.so is not. But how could we do it with existing approach? And anyway, this particular testcase fails with CHECK on x86 and with false positive global buffer overflow on x86_64. I think it's better to miss ODR violation than just miserably die :).
> With the current approach we do die, even though miserably. So, the bug is in fact detected.
> Now we will miss it completely. Right?
Well, we'd really die accidentally. It could also lead to all sorts of misbehavior or even go undetected. So I'd rather not consider this a real existing feature.
On the contrary, we'll now detect errors in libraries dlopened with RTLD_DEEPBIND or linked with -Bsymbolic.
Repository:
rL LLVM
http://reviews.llvm.org/D15644
More information about the llvm-commits
mailing list