[Bug gold/25975] --dynamic-list doesn't work correctly

2020-12-17 Thread mikhail.matrosov at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=25975

Mikhail Matrosov  changed:

   What|Removed |Added

 CC||mikhail.matrosov at gmail dot 
com

--- Comment #25 from Mikhail Matrosov  ---
Guys, could you please summarize the thread? Is this warning safe to ignore? Is
it going to be fixed?

-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug gold/25975] --dynamic-list doesn't work correctly

2020-07-25 Thread hjl.tools at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=25975

--- Comment #24 from H.J. Lu  ---
(In reply to dilyan.palau...@aegee.org from comment #23)
> Can I delete https://mail.aegee.org/dpa/pr25975/pr-gold-25975.tar.xz ?

Yes.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug gold/25975] --dynamic-list doesn't work correctly

2020-07-25 Thread dilyan.palauzov at aegee dot org
https://sourceware.org/bugzilla/show_bug.cgi?id=25975

--- Comment #23 from dilyan.palauzov at aegee dot org  ---
Can I delete https://mail.aegee.org/dpa/pr25975/pr-gold-25975.tar.xz ?

-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug gold/25975] --dynamic-list doesn't work correctly

2020-06-27 Thread i at maskray dot me
https://sourceware.org/bugzilla/show_bug.cgi?id=25975

--- Comment #22 from Fangrui Song  ---
(In reply to H.J. Lu from comment #20)
>   // If the symbol was forced dynamic in a --dynamic-list file
>   // or an --export-dynamic-symbol option, add it.
>   if (!this->is_from_dynobj()
>   && (parameters->options().in_dynamic_list(this->name())
>   || parameters->options().is_export_dynamic_symbol(this->name(
> {
>   if (!this->is_forced_local())
> return true;
>   gold_warning(_("Cannot export local symbol '%s'"),
>this->demangled_name().c_str());
>   return false;
> }
> 
> I don't think the warning is necessary when it is a wild card match.

Agreed. clang -fsanitize=address uses --dynamic-list when
libclang_rt.asan-x86_64.a.syms exists. This behavior has been there for a long
time, since 3.3
(https://github.com/llvm/llvm-project/commit/f3e624ca73b007552554b31358f4abde9eb2d3b7
). So the gold warning may be there for a long time as well.

% readelf -Ws lib/clang/11.0.0/lib/linux/libclang_rt.asan-x86_64.a | grep
__asan_extra_spill_area
   251: 48 FUNCGLOBAL HIDDEN   162
__asan_extra_spill_area
 6:  0 NOTYPE  GLOBAL DEFAULT  UND
__asan_extra_spill_area

The spurious warning should just be deleted, along with msgid "Cannot export
local symbol '%s'" in various .po files.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug gold/25975] --dynamic-list doesn't work correctly

2020-06-27 Thread dilyan.palauzov at aegee dot org
https://sourceware.org/bugzilla/show_bug.cgi?id=25975

--- Comment #21 from dilyan.palauzov at aegee dot org  ---
> Do you have __asan_extra_spill_area in ./libclang_rt.asan-x86_64.a.syms?

If I do not have __asan_extra_spill_area in ./libclang_rt.asan-x86_64.a.syms
does this mean, that clang/rt was self-compiled anyhow wrong?

-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug gold/25975] --dynamic-list doesn't work correctly

2020-06-27 Thread hjl.tools at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=25975

--- Comment #20 from H.J. Lu  ---
  // If the symbol was forced dynamic in a --dynamic-list file
  // or an --export-dynamic-symbol option, add it.
  if (!this->is_from_dynobj()
  && (parameters->options().in_dynamic_list(this->name())
  || parameters->options().is_export_dynamic_symbol(this->name(
{
  if (!this->is_forced_local())
return true;
  gold_warning(_("Cannot export local symbol '%s'"),
   this->demangled_name().c_str());
  return false;
}

I don't think the warning is necessary when it is a wild card match.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug gold/25975] --dynamic-list doesn't work correctly

2020-06-27 Thread hjl.tools at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=25975

H.J. Lu  changed:

   What|Removed |Added

   Last reconfirmed||2020-06-27
 Status|UNCONFIRMED |NEW
 Ever confirmed|0   |1

--- Comment #19 from H.J. Lu  ---
(In reply to H.J. Lu from comment #18)
> (In reply to dilyan.palau...@aegee.org from comment #17)
> > libclang_rt.asan-x86_64.a.syms, included in
> > https://mail.aegee.org/dpa/pr25975/pr-gold-25975.tar.xz, does not contain
> > “spill".
> 
> I got
> 
> 
> [hjl@gnu-cfl-2 pr-gold-25975]$ ld.bfd -Llib64 --hash-style=both
> --eh-frame-hdr -m elf_x86_64 -dynamic-linker ./ld-linux-x86-64.so.2 -o a.out
> ./crt1.o ./crti.o ./crtbegin.o --whole-archive ./libclang_rt.asan-x86_64.a
> --no-whole-archive --dynamic-list=./libclang_rt.asan-x86_64.a.syms i.o
> --no-as-needed -lpthread -lrt -lm -ldl -lgcc --as-needed -lgcc_s
> --no-as-needed -lc -lgcc --as-needed  -lgcc_s --no-as-needed ./crtend.o
> ./crtn.o
> [hjl@gnu-cfl-2 pr-gold-25975]$ ld.gold -Llib64 --hash-style=both
> --eh-frame-hdr -m elf_x86_64 -dynamic-linker ./ld-linux-x86-64.so.2 -o a.out
> ./crt1.o ./crti.o ./crtbegin.o --whole-archive ./libclang_rt.asan-x86_64.a
> --no-whole-archive --dynamic-list=./libclang_rt.asan-x86_64.a.syms i.o
> --no-as-needed -lpthread -lrt -lm -ldl -lgcc --as-needed -lgcc_s
> --no-as-needed -lc -lgcc --as-needed  -lgcc_s --no-as-needed ./crtend.o
> ./crtn.o
> ld.gold: warning: Cannot export local symbol '__asan_extra_spill_area'
> [hjl@gnu-cfl-2 pr-gold-25975]$ 
> 
> It looks like a gold --dynamic-list bug.

The problem is

  _Unwind_RaiseException;
  __asan_*;
  ^ This matches __asan_extra_spill_area.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug gold/25975] --dynamic-list doesn't work correctly

2020-06-27 Thread hjl.tools at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=25975

H.J. Lu  changed:

   What|Removed |Added

 CC||i at maskray dot me
Summary|clang -fsanitze=address |--dynamic-list doesn't work
   |prints warning only with|correctly
   |gold|

--- Comment #18 from H.J. Lu  ---
(In reply to dilyan.palau...@aegee.org from comment #17)
> libclang_rt.asan-x86_64.a.syms, included in
> https://mail.aegee.org/dpa/pr25975/pr-gold-25975.tar.xz, does not contain
> “spill".

I got


[hjl@gnu-cfl-2 pr-gold-25975]$ ld.bfd -Llib64 --hash-style=both --eh-frame-hdr
-m elf_x86_64 -dynamic-linker ./ld-linux-x86-64.so.2 -o a.out ./crt1.o ./crti.o
./crtbegin.o --whole-archive ./libclang_rt.asan-x86_64.a --no-whole-archive
--dynamic-list=./libclang_rt.asan-x86_64.a.syms i.o --no-as-needed -lpthread
-lrt -lm -ldl -lgcc --as-needed -lgcc_s --no-as-needed -lc -lgcc --as-needed 
-lgcc_s --no-as-needed ./crtend.o ./crtn.o
[hjl@gnu-cfl-2 pr-gold-25975]$ ld.gold -Llib64 --hash-style=both --eh-frame-hdr
-m elf_x86_64 -dynamic-linker ./ld-linux-x86-64.so.2 -o a.out ./crt1.o ./crti.o
./crtbegin.o --whole-archive ./libclang_rt.asan-x86_64.a --no-whole-archive
--dynamic-list=./libclang_rt.asan-x86_64.a.syms i.o --no-as-needed -lpthread
-lrt -lm -ldl -lgcc --as-needed -lgcc_s --no-as-needed -lc -lgcc --as-needed 
-lgcc_s --no-as-needed ./crtend.o ./crtn.o
ld.gold: warning: Cannot export local symbol '__asan_extra_spill_area'
[hjl@gnu-cfl-2 pr-gold-25975]$ 

It looks like a gold --dynamic-list bug.

-- 
You are receiving this mail because:
You are on the CC list for the bug.